Page 1 of 1

How to output total body COM

Posted: Wed Feb 13, 2019 10:18 am
by atl5029
Hello all,

I am using the full body opensim model to model certain aspects of aircraft ejection, and total body COM is very important parameter to the simulations. After I scale my model, how can I check that the total body COM matches my subjects. I have data for total body COM of my subjects seated with 90 degree hip, knee, and elbow flexion. Once I position my model in the same pose, if I right click the bodies main tab on the Navigator tab, i can choose to see the total body COM, but I see no way to get it's actual position with respect to ground. Is there an easy way to get this data within the Opensim GUI? Since it shows you the COM, it has to be calculated in the program somewhere. If anyone has an easy way to extract that data, please tell me.

Re: How to output total body COM

Posted: Wed Feb 13, 2019 1:33 pm
by tkuchida
Is there an easy way to get this data within the Opensim GUI?
Yes, you can use the "ScriptingShell Window":

Code: Select all

model = getCurrentModel();
state = model.initSystem();
pos = model.calcMassCenterPosition(state);
pos