You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
unlib::newton<double> force = 1._kg * 9.81_m_per_s2;
In the above example, the right-hand side of the assignment operator calculates the force of earth's gravitational pull in kN which is used to initialize a quantity of the unit N. The conversion of the scale (kilo ==> unscaled) necessary for this is done implicitly during the assignment.
Did you intent to use tons instead of kilograms here? Right now the right-hand side already has the unit N and no conversion should be performed.
The text was updated successfully, but these errors were encountered:
Thanks, you're right, of course, this doesn't make much sense.
Given that force is still a contentious unit (right now, a newton has the scale 1000/1, which will cause surprising results if you, e.g., get a number scaled to kilo_scaling from a force quantity), I should pick some other unit as an example.
(Since you seem to have just read this for the first time, what unit would you have found helpful for this?)
gives the expected result. I have been playing around with your library a little while right now. And everything has worked just fine so far - without any surprises. Very nice and easy to use library! Thanks!
The example in the readme states
Did you intent to use tons instead of kilograms here? Right now the right-hand side already has the unit
N
and no conversion should be performed.The text was updated successfully, but these errors were encountered: