ModelicaStandardLibrary
ModelicaStandardLibrary copied to clipboard
Fix assertions
This PR especially
-
fixes senseless assertions like
assert( body.r_0[2] - body.r_0[2] < tol ...);(so comparing the variable
body.r_0[2]to itself).Fixing this, the assertion is triggered for tol=1e-4. So I additionally changed the intialization
prismatic1.a(..., start=9-world.g)to have more precise value.Note: for
ModelicaTest.MultiBody.Forces.Spring, this PR changes values of reference signalsprismatic1.sandprismatic1.vover time. So regression check could be broken => reference signals shall be recalculated/re-generated.No such behaviour expected for
ModelicaTest.MultiBody.Forces.Spring2. -
Fixes missing absolute differences like
abs(x - y)for assertions. -
Separate tolerances to different physical quantities
-
SI units for tolerances
Refs #4193