ArgumentOutOfRangeException: x Parameter name: Negative value passed to Sqrt #18
Unanswered
TalhaEjaz03
asked this question in
Q&A
Replies: 1 comment 2 replies
-
That shouldn't be possible in the sliding friction solve step- the only square root taken is guarded to be positive. It's possible that something odd is happening in the fixed point math and producing a NaN-equivalent, which is then interpreted as negative for the purposes of that error (don't know if that's true- I'm not familiar with FixedMath.Net). I'd recommend either trying to reproduce it in the normal demos, or examining the state of the constraint at the exception and trace invalid state backwards until you find the cause. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi Norbo.
We are getting this strange fatal error of the Fix64 class.
This is produced when the colliders are small and a lot.
Also when they are smashing together.
Error Details are below
ArgumentOutOfRangeException: x
Parameter name: Negative value passed to Sqrt
FixMath.NET.Fix64.Sqrt (FixMath.NET.Fix64 x) (at Assets/!BEPU/bepuphysics1int-master/FixedMath.Net/src/Fix64.cs:609)
BEPUphysics.Constraints.Collision.SlidingFrictionTwoAxis.SolveIteration () (at Assets/!BEPU/bepuphysics1int-master/BEPUphysics/Constraints/Collision/SlidingFrictionTwoAxis.cs:180)
BEPUphysics.Constraints.SolverGroups.SolverGroup.SolveUpdateable (BEPUphysics.Constraints.SolverUpdateable item, System.Int32& activeConstraints) (at Assets/!BEPU/bepuphysics1int-master/BEPUphysics/Constraints/SolverGroups/SolverGroup.cs:129)
BEPUphysics.Constraints.Collision.ConvexContactManifoldConstraint.SolveIteration () (at Assets/!BEPU/bepuphysics1int-master/BEPUphysics/Constraints/Collision/ConvexContactManifoldConstraint.cs:207)
BEPUphysics.Constraints.SolverGroups.SolverGroup.SolveUpdateable (BEPUphysics.Constraints.SolverUpdateable item, System.Int32& activeConstraints) (at Assets/!BEPU/bepuphysics1int-master/BEPUphysics/Constraints/SolverGroups/SolverGroup.cs:129)
BEPUphysics.Constraints.SolverGroups.SolverGroup.SolveIteration () (at Assets/!BEPU/bepuphysics1int-master/BEPUphysics/Constraints/SolverGroups/SolverGroup.cs:163)
BEPUphysics.Constraints.Solver.UnsafeSolveIteration (BEPUphysics.Constraints.SolverUpdateable updateable) (at Assets/!BEPU/bepuphysics1int-master/BEPUphysics/Constraints/Solver.cs:296)
BEPUphysics.Constraints.Solver.UpdateSingleThreaded () (at Assets/!BEPU/bepuphysics1int-master/BEPUphysics/Constraints/Solver.cs:259)
BEPUphysics.MultithreadedProcessingStage.Update () (at Assets/!BEPU/bepuphysics1int-master/BEPUphysics/MultithreadedProcessingStage.cs:86)
BEPUphysics.Space.DoTimeStep () (at Assets/!BEPU/bepuphysics1int-master/BEPUphysics/Space.cs:512)
BEPUphysics.Space.Update () (at Assets/!BEPU/bepuphysics1int-master/BEPUphysics/Space.cs:530)
PhysicsManager.Update () (at Assets/!BEPU/_BEPU_Scripts/BepuScps/PhysicsManager.cs:76)
CustomCompoundBody.txt
PhysicsManager.txt
SphereAndBoxColl.txt
Beta Was this translation helpful? Give feedback.
All reactions