Questions on the MoCap model (residual forces on the pelvis)

Hello experts,

How do I check what the residual forces (i.e., the “hand of God”) are on the pelvis? I would like to make sure those forces are acceptable. Should I just what the reaction forces are on the pelvis? I guess I want to know if there is a specific variable named pelvis residual force or something along those lines.

Thank you,

Vikas

Hi Vikas,

In a MoCap driven model, the residual force can be found in the ModelEnvironmentConnection:
Main.Studies.InverseDynamicStudy.Output.ModelEnvironmentConnection.JointsAndDrivers.JntDriverTrunk.Reaction.Fout

I just added a line to the Wiki:

http://wiki.anyscript.org/index.php/All_about_Kinetics#Why_is_it_ok_to_have_a_reaction_force_between_the_pelvis_and_environment_if_you_have_measured_ground_reaction_forces.3F

Hi Amir,

Thank you.

I notice that the residual force on the pelvis, at its peak, is about 16 N. That is a little more than I was hoping for. On the other hand, I “guess” or “hope” the effect on muscles a few links away may be an order of magnitude lesser. Does that sound reasonable?

That being said, I wonder if there is a strategy that I could employ to ensure these forces are minimal (an order of magnitude smaller, preferably, i.e., ~1 N).

I know I have to work on improving the scaling. For instance, I didn’t have access to any data on segment lengths. Once I have that data, I suspect the scaling, and therefore, muscle forces will be more appropriate - and, hopefully, the pelvis residual forces will drop.

By the way, is there a female mannequin or AnyWoman/AnyLady?

Hi Vikas,

I think the residual you are reporting is reasonable.

The residual originates from :

[ul]
[li]Difference in anthropometrics [/li][li]Errors on motion [/li][li]Errors on measured force[/li][/ul]
In general it would be possible to make an optimization study on a model with no muscles on. Then have as the objective to minimize the residual error and the design variables to be

[ul]
[li]Anthropometrics, individual masses, CoM etc [/li][li]Small alterations to the measured motion [/li][li]Small alteration to the measured force[/li][/ul]
It is possible to do inside AnyBody, but I think it will not change the results much.

Best regards
Søren

Hi ,

Thank you again.

I did not have optimization in my mind - which is a cool idea, by the way - when I was thinking about strategies to reduce the residual forces on the pelvis.

I was simply thinking about the model as it is currently i.e., ensuring the model markers are as close as possible to the experimental markers, making sure subject anthropometrics (segment lengths, e.g.) are as well represented as possible, etc.

Now I know that while the motion that I am interested in capturing looks great from an anatomical sense and the forces are not unreasonable, there are some markers that are not entirely overlapping experimental markers; you can clearly see space opening up between them during certain time windows. What strategies do I employ to fix this situation?

Hi Vikas,

There is one other source of error that you will see the effect of as gaps between markers, this is the joint axis definitions.

So as an example the knee axis is fixed in the model. In reality the knee motion is complex and imposing the revolute joint is of course an approximation, it is also possible to optimize the knee axis to better full fill the motion, this may require more data.

So in principle you can introduce more design variables into the model that will allow it to find a better optimum, but there are some practical limitations when doing this, you can create problems which are unbounded and you in general need more kinematic data to optimize joint axes.

Best regards
Søren

Hi Søren,

Thank you for your continued support and patience.

At this point, while they have a major role to play, I do not have the degrees of freedom ("joint axes") at a given joint in my mind. I am simply concerned about the basic steps of the MotionAndParameterOptimization (MAPO) and InverseDynamics (ID) parts of the process.

As an example, when the MAPO finishes, the model markers end up being right on top of experimental markers. However, when the ID runs, the model markers do not seem to be matching the experimental markers as well.

So, what can explain this and how do I try to minimize this error?

Best,

Vikas

Hi vikas,
Please ensure you are running the inversedynamic sequence operation seen in the operation tree. This ensures that the optimization result from the kinematic study is being applied. If you just run inverse dynamics this will not happen automatically.
Best regards
Søren

Hi Søren,

I believe I follow the procedure correctly. Here is what I am doing:

[ul]
[li]Turn on MotionAndParameterOptimization (and ensure [/li]InverseDynamics is off)
[li]Hit F7[/li][li]Go to model tree in the Operations tab,click on RunMotionAndParameterOptimization, and then click on the Start operation (play) button.[/li][li]Once that part of the process is finished, I turn the InverseDynamicsflag on (and turn the MotionAndParameterOptimization flag off.)[/li][li]Hit F7[/li][li]Go to model tree in the Operations tab,click on InverseDynamicsAnalysisSequence, and then click on the Start operation (play) button.[/li][/ul]

Hi Vikas,

Your procedure looks correct to me.

There will be small differences between the models because they are driven differently and any kinematic tolerance will then have a different impact, additionally the kinematic model motion is being applied through an interpolation function which also leads to small differences. The differences should be very small if you see big differences it sounds strange.

I would open two instances of the same model one in kinematic mode and one in inverse, then compare the position of each segment starting from pelvis. I would also compare segment lengths in the two models and marker positions.

One more thing if you are using different no of timesteps in the model this could of course also lead to differences.

How big a difference do you see?

Best regards
Søren

How big a difference do you see?

From being indiscernible (model markers overlapping experimental markers) in the first part to being clearly separated by, at most, a few centimeters in the second part.

Hi Vikas,

I have double checked the standard model, and it has revealed a small error in the visualization of the marker trajectory ball for the inverse model, so the blue sphere. The error is only visual and results from the model is not changed.

To correct it please localize the CreateMarkerClass being used to create the marker.

Then replace the “AnyDrawVector MarkerName” object in this class with this code:


[SIZE=3]AnyDrawSphere [/SIZE]MarkerName={
Visible=On;
Opacity=0.5;
Position={Main.ModelSetup.C3DFileData.Points.Markers.MarkerName.PosInterpol(Main.Studies.InverseDynamicStudy.t)}[0];
[SIZE=3]
 [/SIZE]GlobalCoord=On;
ScaleXYZ={1,1,1}*0.01;
RGB={0,0,1};
[SIZE=3]AnyRefFrame[/SIZE]&Globalref=Main.Studies.InverseDynamicStudy.EnvironmentModel.GlobalRef;
};

If you still see errors please try to use more timeframes in both studies, maybe also try to use higher nStep for kinematic analysis than inverse for example a factor 2. Both of these approaches will decrease the influence of the interpolation error introduces by the drivers.

Best regards
Søren

Hi Søren,

Thank you. As soon as I find some time to revisit this, I will make the suggested changes and post my feedback here.

Best,

Vikas

Hello

Why is this a vector with 9 elements?
How do I calculate the resultant residual force with this vector?

Thanks in advance

Hi Fritz,

Please have a look at driver:


AnyKinEqInterPolDriver JntDriverTrunk = {
    FileErrorContinueOnOff = On;
    Type = Bspline;
    BsplineOrder = 4;
    FileName = "../Input/"+OutputFileNamePrefix+Main.ModelSetup.C3DFileData.NameOfFile+"-euler-trunk.txt";
    AnyKinMeasureOrg &PelvisPosX = ...BodyModel.Interface.Trunk.PelvisPosX;
    AnyKinMeasureOrg &PelvisPosY = ...BodyModel.Interface.Trunk.PelvisPosY;
    AnyKinMeasureOrg &PelvisPosZ = ...BodyModel.Interface.Trunk.PelvisPosZ;
    AnyKinMeasureOrg &PelvisRotX = ...BodyModel.Interface.Trunk.PelvisRotX;
    AnyKinMeasureOrg &PelvisRotY = ...BodyModel.Interface.Trunk.PelvisRotY;
    AnyKinMeasureOrg &PelvisRotZ = ...BodyModel.Interface.Trunk.PelvisRotZ;
    AnyKinMeasureOrg &PelvisThoraxExtension = ...BodyModel.Interface.Trunk.PelvisThoraxExtension;
    AnyKinMeasureOrg &PelvisThoraxLateralBending = ...BodyModel.Interface.Trunk.PelvisThoraxLateralBending;
    AnyKinMeasureOrg &PelvisThoraxRotation = ...BodyModel.Interface.Trunk.PelvisThoraxRotation;
    #if TRUNK == 1
    AnyKinMeasureOrg &NeckExtension = ...BodyModel.Interface.Trunk.NeckJoint;
    Reaction.Type={On,On,On,On,On,On,Off,Off,Off,Off};
    #endif 
    #if TRUNK_NECK == 1
    AnyKinMeasureOrg& SkullThoraxFlexion = ...BodyModel.Interface.Trunk.SkullThoraxFlexion;
    AnyKinMeasureOrg& SkullThoraxLateralBending = ...BodyModel.Interface.Trunk.SkullThoraxLateralBending;
    AnyKinMeasureOrg& SkullThoraxRotation = ...BodyModel.Interface.Trunk.SkullThoraxRotation; 
    Reaction.Type={On,On,On,On,On,On,Off,Off,Off,Off,Off,Off};
    #endif
  };


The vector has 9 elements but only the first 6 of them can be non-zero, since the rest has been switched off.

By default all drivers has reactions which are on until they are disabled, and size of the reactions listed will always be the size of the driver

Best regards
Søren

Thank you.

Am I right that the PelvisPosZ is the residual force of the transverse axis (left 2 right direction)?

Or does it depend on the global CS? Since in my case: Gravity = {0, 0, -9.81} instead of {0, -9.81, 0}

Kind regards

Hi

The PelvisPosZ is the position with respect to the global system, so it depends on the orientation in the model.

I would visualize the the global coordinate system to see this e.g.

AnyFixedRefFrame MyGlobalRef ={
AnyDrawRefFrame drw ={};
};

Best regards
Søren