Golf-swing MarkerTracking or ParameterIdentification Problem for rotating feet

Dear AnyBody users,

I am trying to simulate a Golf-Swing motion and analyze the muscle forces and joint reaction forces. However, as it is shown in the following animation there are problems in parameter identification and marker tracking for both feet maekers, RMT5 and RTOE (red markers does not follow blue markers).

Golf-Swing

I have tested different direction to be free to optimize for each marker. For example, if I make RMT5 free in z and y direction as well then, the blue and red markers are so close to each other during the simulation, but it does not influence the foot motion! I suppose the motion is dictated to the feet from shanks motion?!

Is there any suggestion to improve the marker tracking for feet?

Best Regards,
Iman

Hi Iman,

Is there any chance you have a driver on the subtalar dof... in extradrivers.any file, this could explain it?

Otherwise I think you could be right the ankle joint is made using two revolute joints, so there is one DOF which is locked.

Have you tried to increase the weight of these markers.

Best regards
Søren

Dear Søren,

I have not used extra drivers for feet, because there are enough markers on the feet (4 Markers).

Yes, I have tried to change Weight factors as well. There is a little improvement in the result but still needs improvement. I tried 1.5, 2 and 2.5 for RMT5 and RTOE.
WeightX=2.5,WeightY=2.5,WeightZ=2.5,

You can see the result in the following animation (I worked only on the right foot)
Golf Improved

I think when thorax rotates, pelvis rotates as well and it forces legs (thigh and shank) to rotate and as you said, if there is only one dof for ankle, then the foot is forced to rotate. you can see in the beginning of the animation, blue markers from c3d file are standing still but red markers starts moving.

Do you have any more suggestion?

Best regards,
Iman

Hi Iman,

I think what is also missing here are more DOF in the foot part of the difference comes from missing foot flexion, the ankle joint does move a lot it seems, i am afraid this is the best which can be done with the DOF available.

One thing you could try would be to change the subtalar joint to a universal joint... though i am not sure this is the right solution, more dof in the foot would have been a better solution.

What are you trying to calculate with this model? The motion is followed well except for the front foot markers, so it is a question if this is a real problem, though I agree it looks strange.

Best regards
Søren

This topic was automatically closed 125 days after the last reply. New replies are no longer allowed.

Dear Søren,

The problem Is that because of the excessive rotation of the foot, the foot penetrates the force plate and at some points, especially at the end of the previously attached animations, there are no GRF applied to the foot and there are mistakes in the muscle calculation as can been in the following:

Disappearing ground reaction

What I did so far:
1- I changed the subtalar DOF from Eversion-Inversion to axial rotation (I changed the axis of rotation for the revolute joint). It improved the marker tracking a lot and solved the problem of the disapearing GRF. However, I received overloaded muscle problems, strange ankle and subtalar joint moment curves and strange muscle wrapping route (visible in the model view).

2- I changed back the subtalar DOF to its original format and once again I played around with the marker tracking parameters such as marker weights and optimization directions and I could solve the problem of disapearing GRF, as well as overloaded muscles. However, still there exist a huge deviation between blue and red markers for the foot.

Compared to the gait, golf is a highly complex motion and axial rotation of the lower limbs plays an important role in properly simulating the motion. I compared the result of the simulated motion using Anybody and Visual 3d (with the same C3d file):

Unlike AnyBody, Visual3d has 3 DOF for each lower limb joint. Therefore, as it is shown in the top right figure, Hip external rotation DOF in Anybody model needs to compensate the lack of axial rotation DOF in other joints (knee and ankle).

Therefore, I concluded that at least one DOF should be added to the knee or ankle. However, I think it is better to apply it to the knee.

Question: How can I change anyscript of the LowerExtremity model, to add axial rotation DOF to the knee or in the best case, is it possible to integrate the detailed knee model in the LowerExtremity model?

Best regards,
Iman

Dear Iman,

Concerning the missing GRF, I would consider to increase the LimitLow and LimitHigh values used by the GRF prediction class these are optional values which can be altered.

The knee model change is more difficult to do in a good way.

You could easily change the knee joint to be a spherical joint but the ligaments would be missing to carry the moment reactions previously taken by the revolute joint. It would be ok if the purpose is the comparison with Visual3d model.

Alternatively to the FDK knee model there is also the the AnyKnee model see GitHub - AnyBody/anyknee: Stand alone example of excluding the generic knee joint and then including your own userdefined knee. the joint is still a revolute joint but it can move.

Hope it helps

Best regards
Søren

1 Like

Dear Søren,

You could easily change the knee joint to be a spherical joint but the ligaments would be missing to carry the moment reactions previously taken by the revolute joint.

May you please explain the above statement more?
I don't want to change the knee joint from revolute to spherical. I want to keep the revolute joint for the flexion degree and add one other revolute joint for the internal/external rotation.

I think to define a new joint, some changes have to be done to the Jnt.any, InitialPositions.any, and Interface.any in the LegTLEM folder. However, I wonder what other .any files should be updated?

The purpose is to study the joint and muscle forces.

Best regards,
Iman

Hi Iman,

Ok then you should use a universal joint instead.

You are right that this will trigger a number of changes in various files...since the knee joint is being used.

I would simply just try to do it and see which errors it will trigger.
Try to use define statements to ensure you can switch this on and off as you like.

I think it would be easiest if you use the same name for the new joint, then add a reaction force on the internal external dof of it.

Except the files you mentioned i think selected output will need a change, but i do not think initial position will, unless you specifically want to specify internal rotation at load time, but this would not be needed in my opinion.

Best regards
Søren
Best regards
Søren

Dear Søren,

I have replaced the knee joint with a universal joint in Jnt.any file. Then, in the Interface.any I used the MeasureOrganizer={1} of the AnyKinRotational KneeRot for the KneeInternalRotation.

AnyUniversalJoint Knee = 
{
  Axis1 = z ;    // Knee Flexion
  Axis2 = y ;    // knee InternalRotation
  AnyRefFrame &ThighNode = ..Seg.Thigh.KneeJoint;
  AnyRefFrame &ShankNode = ..Seg.Shank.KneeJoint;
};
        AnyKinMeasureOrg KneeInternalRotation = {
          AnyKinRotational KneeRot={
            AnyRefNode &ShankNode = ...Seg.Shank.KneeJoint.RotNode;
            AnyRefNode &ThighNode = ...Seg.Thigh.KneeJoint.RotNode;
            Type=RotAxesAngles;
            // Rotation sequence for RotAxesAngles is ZYX
          };
          MeasureOrganizer={1};    // 0 is flexion (z), 1 is internal rotation (y), 2 is adduction (x)
        };   // KneeInternalRotation

The output joint angle for the added DOF seem correct compared to the Visual3d.
ParameterIdentification and MarkerTracking run without problem.

However, I have problem with InverseDynamic. After the middle of the simulation (when the direction of body rotation in the golf swing changes from back swing to the forward swing), It starts giving warnings:

WARNING(OBJ.MCH.MUS3) :   AnyMocapModel.any(61)  :   InverseDynamicStudy.InverseDynamics  :  Overloaded muscle configuration.
WARNING(OBJ.MCH.MUS3) :   AnyMocapModel.any(61)  :   InverseDynamicStudy.InverseDynamics  :  Overloaded muscle configuration.
WARNING(OBJ.MCH.MUS3) :   AnyMocapModel.any(61)  :   InverseDynamicStudy.InverseDynamics  :  Overloaded muscle configuration.
ERROR(OBJ.MCH.MUS4) :   AnyMocapModel.any(61)  :   InverseDynamicStudy.InverseDynamics  :  Muscle recruitment solver :  maximum number of setbacks occured

Please also pay attention to the highlighted GluteusMaximusSuperior1. Something is wrong with the muscle wrapping!

I think there are still some changes and updates that should be made to the model especially about the joint moments that I may skipped. I have also updated the following files:
Mannequin.ClassTemplate.any
BodyModel.MannequinDrivers.ClassTemplate.any
BodyModel.MannequinDrivers.any
RangeOfMotionLimits-Templae.any
JointAngleoutputs.any
Initialpositions.any
JointAndDriversOptimized.any
LeMoments.any

Is there any other change I should make?

Best regards,
Iman

Hello,

The overloaded muscle problem is solved. I just forgot to add reaction force to the added Dof (internal rotation) to the knee in the Interface.any file:

        AnyReacForce KneeInternalRotationReac = {
          AnyKinMeasure &KneeInternalRotation = .KneeInternalRotation;
        };  

now Inverse dynamic runs without problem. I just need to check if the results are logical but as a first look they seem well. Would you please explain the theory behind this? Why this reaction force has to be added and what does it do exactly?

The problem of the GluteusMaximus wrapping still exists. Would you please provide me a solution to solve this? (check the last post image please)

Best regards,
Iman

Dear Søren,

I updated the LegSelectedOutput.any file:

      AnyVar KneeInternalRotation = -....Left.Leg.MomentMeasure.KneeNetMomentMuscle.MKneeInternalRotation;  

and the LegMoments.any file:

AnyForceMomentMeasure2 KneeNetMomentMuscle = 
{
.
.
.
  
  AnyVec3 Mlocal=M*ref.Axes;
  AnyVar MKneeFlexion = Mlocal[2];
  AnyVar MKneeInternalRotation = Mlocal[1];
  
};

I used Mlocal[1] for the Internal Rotation DOF. Is it correct?

Then I plotted Internal rotation joint moment measure:

The pattern of the joint moments seem to be the same but is the deviation between the softwares' result normal? if not, how can I adjust the parameters to decrease this deviation? Is there any settings for AnyReacForce that can help?

        AnyReacForce KneeInternalRotationReac = {
          AnyKinMeasure &KneeInternalRotation = .KneeInternalRotation;
        }; 

Best regards,
Iman

Hi Iman,

Sorry for the slow answer.

The AnyReacForce has no settings, it is simply a reaction force applied on a measure. So what this reaction forces does is determined by the measure it is applied on (and the rest of the model).

In a normal model there is a revolute joint in the knee, this allows three forces and two moment reactions, it replicates the combination of contact forces between surfaces, ligament forces. Now you have removed the two moment reactions since you have a spherical joint, this will mean that the muscles will have to carry these two torques, this may not represent reality, this is why you could consider to have reaction on these two dofs.

If you have doubts on what the moment represents i would try to add some know loads to the model and verify the output in this way, you can use e.g AnyForce3D or AnyMoment3D for this. If you reference frame in the forcemoment measure has y pointing in the internal rotation direction it looks correct your code.

I can see you are using a AnyForceMomentMeasure2 object to find the moments, this is possible but may not be needed in this case.

You could simply look at the refframeoutput folder inside you reaction force, here you will find the reaction moment measure in the two refframes given in global ref system

The differences in the curves can also originate from model differences, e.g. marker placements, inertia properties of models.. in AnyBody you will always see forces as a function of applied loads, applied dynamics, and muscle contractions.

Sorry if I have misunderstood some of the issues.

Best regards
Søren

The differences

Dear Søren,

Thank you for your reply. Would you please explain the following statement a little more:

Another question is that I compared the results, before and after adding the new dof to the knee joint. Although joint angles are changed significantly, hip joint external rotation moments are almost the same, i.e. adding new dof to the knee could not change the kinetics. Therefore, I wonder if I should still update some scripts and *.any files?

Best regards,
Iman

Hi Iman,

If you have a static model with zero gravity the forces and moments will be zero, then applying AnyForce3D or AnyMoment3D to the thigh or shank would allow you to verify that your measure things as you would like to measure them.

Concerning the hip forces i think it can be ok that you do not see major changes there, are the angles in the hip changed? The hip torques will come from the applied forces on the ground and unless hip joint center changed it will feel the same torques.

Best regards
Søren

Hi Søren,

Yes the joint angles are changed.

The other concern is that I think the Measured joint moments for KneeInternalRotational has illogically spiky curve at some instances (Joint angle curve is okay though). Is there any way to refine this?


Drop in the curve between 60.50 and 60.75 secs is due to the overloaded muscles.