Good morning,
I'm hoping to run a few simulations that don't involve contact with any particular ground surface as I don't have forces available, such as riding a bike and a baseball pitch. I tried to step through the demo format to get to a forward dynamics simulation, but the model starts "falling" when the RRA analysis begins. I took a look through some of the XML files but couldn't find something that looked like gravity; how can I disable it so my model stays stationary in space without ground reaction forces?
Thanks,
Dan
Disabling gravity
- Ayman Habib
- Posts: 2248
- Joined: Fri Apr 01, 2005 12:24 pm
RE: Disabling gravity
Hi Daniel,
Gravity is specified in the model's osim file under the xml tag <gravity>:
<gravity> 0.00000 -9.80665000 0.00000</gravity>
You can use a text editor to modify it or you can open the file using
Edit->File (.osim)
Browse for the model file (.osim)
Expand the tree in the left column of the "Property Editor" dialog down to:
Model
DynamicsEngine
gravity
and modify the values in the column labeled Value. Then hit "Save".
Next time you open the model it will have no gravity.
Hope this helps,
-Ayman
Gravity is specified in the model's osim file under the xml tag <gravity>:
<gravity> 0.00000 -9.80665000 0.00000</gravity>
You can use a text editor to modify it or you can open the file using
Edit->File (.osim)
Browse for the model file (.osim)
Expand the tree in the left column of the "Property Editor" dialog down to:
Model
DynamicsEngine
gravity
and modify the values in the column labeled Value. Then hit "Save".
Next time you open the model it will have no gravity.
Hope this helps,
-Ayman
- Daniel Leib
- Posts: 75
- Joined: Mon Sep 11, 2006 6:44 am
RE: Disabling gravity
Ah, thanks, I was looking in the setup files.
Have a good one,
Dan
Have a good one,
Dan
- Daniel Leib
- Posts: 75
- Joined: Mon Sep 11, 2006 6:44 am
RE: Disabling gravity
Thanks again for the tip on editing the .osim file, that worked like a charm. Unfortunately, it seems as though the forward dynamics tool doesn't want to work without an external force; I tried going through the demo that uses gait_2354.osim after removing the vertical component of gravity and it worked well until forward dynamics, where the program closed after hitting the run button. Throughout the demo, I also unchecked the option to apply external forces, as I won't have any available for the simulations I mentioned earlier.
Is there something in the input controls or states that is dependent on forces that I can change? Perhaps another setting somewhere?
Thanks for your help,
-Dan
Is there something in the input controls or states that is dependent on forces that I can change? Perhaps another setting somewhere?
Thanks for your help,
-Dan
- Ayman Habib
- Posts: 2248
- Joined: Fri Apr 01, 2005 12:24 pm
RE: Disabling gravity
Dan,
I reproduced and fixed the problem related to trying to run a forward simulation without external loads. The fix will be in version 1.1 which will be out shortly. For what you have I'd suggest you set the values of the ground reaction forces in the data files to 0. and let OpenSim apply them, and that should keep you going.
Have a good one,
-Ayman
I reproduced and fixed the problem related to trying to run a forward simulation without external loads. The fix will be in version 1.1 which will be out shortly. For what you have I'd suggest you set the values of the ground reaction forces in the data files to 0. and let OpenSim apply them, and that should keep you going.
Have a good one,
-Ayman