google-deepmind / mujoco

Multi-Joint dynamics with Contact. A general purpose physics simulator.
https://mujoco.org
Apache License 2.0
7.84k stars 781 forks source link

"WARNING: Nan, Inf or huge value in QPOS/QACC at DOF 0." when create "flexcomp" from a STL file with elasticity plugins #1173

Closed DFREANDY closed 10 months ago

DFREANDY commented 10 months ago

Hi,

I'm a student and I'm trying to use MuJoCo for simulating deformable object.

I'm looking for some help with using elasticity plugins in a flexcomp created from a STL file.

Here is a model which explains my question:

minimal XML ```XML ```

Here is a screenshot / video, illustrating my question: image image image

Here is the STL file: cube.zip

quagla commented 10 months ago

Can you decrease the timestep and/or the young modulus? Try also with equality="true" in the edge section, that should be more stable if you need a very stiff material. Feel free to reopen if this doesn't solve the issue.

DFREANDY commented 10 months ago

Thanks for your advice! I've tried to set the young modulus from "0.01" to "1000". However, the same problem still exists. I also decrease the timestep to "0.0001", and set equality="true". It doesn't help. As long as I try to use the mujoco.elasticity.solid plugin, the warning will appear. "WARNING: Nan, Inf or huge value in QPOS/QACC at DOF 0."