Page 1 of 1

Inverse Dynamics using Matlab

Posted: Thu Nov 26, 2020 1:43 am
by mchendriksen
Hi all,

I am using Matlab to perform inverse dynamics in OpenSim. I would like to add the body forces acting at the joints by using the _outputBodyForcesAtJointsFileName command, but it doesn't work.

id= InverseDynamicsTool(ID_setup);
id.setOutputGenForceFileName(strcat(trial,'_ID.sto'));
id.setOutputBodyForcesAtJointsFileName(strcat(trial,'_BodyForcesatJoints.sto'))

The setOutputGenForceFileName does work but the setOutputBodyForcesAtJointsFileName give the following error: Undefined function or variable 'setOutputBodyForcesAtJointsFileName'.

Does anyone know what I'm doing wrong? Any help would be much appreciated.

Best,
Maud