JointReaction vs InverseDynamics

Provide easy-to-use, extensible software for modeling, simulating, controlling, and analyzing the neuromusculoskeletal system.
User avatar
Mohammadreza Rezaie
Posts: 412
Joined: Fri Nov 24, 2017 12:48 am

Re: JointReaction vs InverseDynamics

Post by Mohammadreza Rezaie » Tue Mar 22, 2022 11:59 am

However, in the graph you showed, it was just ID vs JRA moments, so it was the exact same model, correct?
Same scaled model, IK output, and GRF.
This was the Rajagopal model and the associated sample walking trial. I also tested Gait2354 model and data, there was the same mismatch.
look at the resultant moment from both (i.e., sqrt(Mx^2 + My^2 + Mz^2)
They are quite similar. The RMS difference was only 0.25.
ResultantHip.png
ResultantHip.png (44.59 KiB) Viewed 371 times
Regards,
MrR

Tags:

User avatar
Jacob J. Banks
Posts: 97
Joined: Tue Jul 15, 2014 5:17 am

Re: JointReaction vs InverseDynamics

Post by Jacob J. Banks » Wed Mar 23, 2022 6:13 am

Oh, those are the same (maybe some filtering and/or weird little coordinate differences that don't align)! So it is just a mater of which coordinate system you are using.
Are you looking at the child or the parent frame for your JRA? Which ever you are not, should be in the same coordinates as the ID result (my assumption is the parent should be the same).
Jake Banks

User avatar
Mohammadreza Rezaie
Posts: 412
Joined: Fri Nov 24, 2017 12:48 am

Re: JointReaction vs InverseDynamics

Post by Mohammadreza Rezaie » Wed Mar 23, 2022 2:11 pm

Hi,

I tested all possible options of child, parent, and ground for <express_in_frame> in JointReaction class:

Code: Select all

<JointReaction name="default">
 	<on>true</on>
 	<start_time>-Inf</start_time>
 	<end_time>Inf</end_time>
 	<step_interval>1</step_interval>
 	<in_degrees>true</in_degrees>
 	<forces_file />
 	<joint_names> ALL</joint_names>
 	<apply_on_bodies> child</apply_on_bodies>
 	<express_in_frame> ground</express_in_frame>
 </JointReaction>
For <apply_on_bodies>child</apply_on_bodies>:
<express_in_frame>child</express_in_frame>:
CC.png
CC.png (33.48 KiB) Viewed 340 times
Only hip rotation and MY are the same.

<express_in_frame>parent</express_in_frame>:
CP.png
CP.png (30.74 KiB) Viewed 340 times
Only hip flexion and MZ are the same.

None was similar for <express_in_frame>ground</express_in_frame>.
The results of <apply_on_bodies>parent</apply_on_bodies> were similar to the above but negated.

If the frame is the source of the mismatch, I think there must be a new option to express the forces and moments in joint coordinate system. e.g:
<express_in_frame>joint</express_in_frame>
Then the output will be identical to ID. Am I right?

Regards,
MrR

POST REPLY