Created
May 9, 2025 23:18
-
-
Save Pierre-Terdiman/9dfd924840eca5c97b67b637289e5360 to your computer and use it in GitHub Desktop.
Box-on-plane jumps instead of sliding smoothly (MuJoCo 3.2.2)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!-- | |
| Simple box-on-plane test. I expected the box sliding smoothly on the plane | |
| (both have low friction, etc) but instead the box starts jumping (at 60 Hz). | |
| I have to decrease the timestep significantly for this to start working. | |
| Any idea how to make this work at 60 Hz ? | |
| --> | |
| <mujoco model="SlidingBox"> | |
| <statistic meansize="1"/> | |
| <option timestep="0.016666"/> | |
| <!--<option timestep="0.002"/> <!-- even at 500Hz the cube eventually starts jumping --> | |
| <worldbody> | |
| <light directional="true" pos="-50 -20 10" dir="5 2 -1" diffuse="1 1 1"/> | |
| <!--<geom type="plane" size="40 30 .1" rgba="0 1 0 1" friction="0.25"/>--> | |
| <geom type="plane" pos="39 0 5" size="300 10 .1" euler="0 -45 0" rgba="0 .8 0 1" friction="0.2"/> | |
| <body name="sliding box" pos="45 0 12.5" euler="0 -45 0"> | |
| <freejoint/> | |
| <geom type="box" size="1 1 1" friction="0.2"/> | |
| </body> | |
| </worldbody> | |
| </mujoco> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment