Foot alignment during motion

Good day everyone

I have a model in which talus was scaled. For my case, I am focusing on the knee joint only. So, I excluded the custom scaling of the talus. On top of that, the talus ankle joint center and axes (sRel and ARel) where determined using analytical surface fitting but, as for my case, I do not want to redefine these parameters (I want to use the default model template center and axes). So, I commented it out in the script. I did the same for the ankle joint center and axes in the shank segment.
For illustration:
AnkleJoint = {
// AnyVec3 AnkleOrigin = 0.5*(Main.Studies.HumanModel.SubjectSpecificJointAxis.AnkleSphereData.Origin1+Main.Studies.HumanModel.SubjectSpecificJointAxis.AnkleSphereData.Origin2);
//
// sRel = .CustomMarkerScaling( AnkleOrigin/1000);
// ARel = RotMat(sRel,.CustomMarkerScaling(Main.Studies.HumanModel.SubjectSpecificJointAxis.AnkleSphereData.Origin1/1000),.CustomMarkerScaling(Main.Studies.HumanModel.SubjectSpecificJointAxis.HipSphereData.Origin))*RotMat(pi/2,y);
// //AnyDrawRefFrame drw = {RGB = {0,0,1}; ScaleXYZ = {0.08, 0.08, 0.08};};
// };

When I excluded the talus ankle joint above, the following issue happened.
I found that the foot on the left is in an eversion position during the stance which does not make sense.
image

So, how can I use the model default joint centers and axes. I made sure that these are not redefined elsewhere too.

Thank you

Best regards,
Omar

Hi Omar,

Looking at the screenshot, I agree that there is something wrong with the angle of the left foot. What I notice here is that all the red markers are off the blue markers in the same direction. That is the foot is not respecting the marker data for some reason.

This makes me wonder have you rerun parameter optimization and marker tracking after making the changes in the joint definition? Can you also check if there is a weak driver at the subtalar joint in your model? You can look for them in the file ExtraDrivers.any through LabSpecificData.any.

Best regards,
Dave

Thank you Dave for your reply.

For your information, I am not using the lowerextremity.any model from AMMR. I am using another one but almost with the same structure and workflow.

I have a sequence that I run for parameter identification and tracking (check kinematic.any): Kinematics.any (5.6 KB)

I have doubt regarding the exclusion process of the talus axes redefinition. When I switch off PATIENT_SPECIFIC_SUBTALAR_JOINTAXIS, I get the issue.

#if PATIENT_SPECIFIC_SUBTALAR_JOINTAXIS == 1
#if InverseDynamicModel== 0 | INV_DYN_EXCLUDE_RIGHT_LEG == 0
Main.Studies.HumanModel.BodyModel.Right.Leg.Seg.Talus.SubTalarJoint = {
//AnyDrawRefFrame drw ={};
sRel = .Scale(.StdPar.SubTalarJoint+{-0.015,0.0,.Sign*0.015});
ARel = RotMat({0.0,0,0}, .StdPar.SubTalarJointAxis, .ScalingNode.ARel'[1])*RotMat(pi/2,y);
};
#endif

Somehow this does not happen to the mirrored right side! So, I am a bit lost with this issue.

Regarding the extra drivers, they are not activated:
#ifndef ThreeFootMarkersOnOff
#define ThreeFootMarkersOnOff 1
#endif

#if ThreeFootMarkersOnOff == 0
AnyKinEqSimpleDriver AnkleDriverRight={
AnyKinMeasureOrg &ref2= Main.Studies.HumanModel.BodyModel.Interface.Right.SubTalarEversion;
DriverPos = pi/180*{.JntPos.Right.SubTalarEversion};
DriverVel=pi/180*{.JntVel.Right.SubTalarEversion};
CType = {Soft};
Reaction.Type={Off};
CType = {Soft};
};
AnyKinEqSimpleDriver AnkleDriverLeft={
AnyKinMeasureOrg &ref2= Main.Studies.HumanModel.BodyModel.Interface.Left.SubTalarEversion;
DriverPos = pi/180*{.JntPos.Left.SubTalarEversion};
DriverVel=pi/180*{.JntVel.Left.SubTalarEversion};
CType = {Soft};
Reaction.Type={Off};
CType = {Soft};
};
#endif

Please let me know if you need more details.

Hi Omar,

It's a little bit challenging to help you with a non-standard AMMR model. I can't be sure of what exactly is happening in the model.

PATIENT_SPECIFIC_SUBTALAR_JOINTAXIS seems to work only on the right leg. The way this is implemented, it should only affect the right subtalar joint and not the left subtalar joint.

ThreeFootMarkersOnOff = 0 will add the extra drivers to the subtalar joint. From the code you posted, it will be defined to 1 only if it has not been defined elsewhere in the model? Can you check if ThreeFootMarkersOnOff is set to 0 somewhere else in the model? You can search for this phrase in all the loaded files by selecting it and then hitting ctrl+shift+F

Another way to quickly check the definition is by exploring to the subtalar joint for right/left leg on the model tree and follow the link to the anyscript file where it is defined. You can explore to sRel/ARel, see some expressions in the information window, and jump to its definition in the AnyScript file. Maybe you are able to find how exactly it is defined and if there are some other settings in the model that are modifying the definition of these joints.

Best regards,
Dave

Thank you Dave again for your response. I think I missed this point.
The ThreeFootMarkersOnOff is set to 1, which means that there are markers that will driver the model; thus, not incorporating the ExtraDrivers:
image

It does confuse me too. The right side was custom-scaled, and the left side was mirrored. So, Whatever changes take place on the right side should be reflected on the left side. However, it seems the other way around, somehow!

Best regards,
Omar

Hi Omar,

I will try to explain a little bit about custom scaling. Custom scaling defines the scaling function that will scale the standard parameters that are used to define the joints. The mirroring part will define the scaling function accordingly.

However, if you manually define the joint on the right side by specifying sRel and ARel values in your model, then you are not using the standard parameters anymore. Then, this will not be mirrored to the left side just by the mirrored custom scaling function. You will need to manually define the joint for the left side.

I hope this helps.

Best regards,
Dave

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