Getting the muscle force in the X,Y,Z directions

Hallo there,
For a project i’m analyzing the Motion of a body. Therefore i need the Joints Forces and the Muscle Forces in X,Y,Z directions.
The Joint reactions give out the Forces Fx, Fy, Fz, which is really fine :slight_smile:
but on the other hand I’m not able to get the Muscle forces Fmx, Fmy, Fmz.
I’m only getting the muscle force FM - I assume it is the resulting force of Fmx, Fmy, Fmz -
The Intersection point of the Joint (Knee or Femur) and the muscle could be seen as a pressure-point of the Force, which must have three directions x,y,z (a assumption, not sure )

I hope, I made my que. clear and i’ll appreicate it if someone could help me with this issue.

Best Reagrds from germany

Hi Mewael,

Please note that when you post for the first time in this forum your post will be approved manually by the administrator before it can be seen by others, this the only way to avoid spam.

The standard output from a muscles does not contain the force components just the net force in the line it is working on. Please also note that the moment in the insertation/origin point is always zero, there is no momentarm.

There are ways to measure the force components from the muscles, this can be done using an AnyForceMomentMeasure please see the reference manual and this wiki page https://github.com/AnyBody/support/wiki/All-about-Kinetics#measure-the-reaction-force-in-a-joint-in-a-certain-coordinate-system

It is also possible to export all forces including muscle and joint forces to an xml file using the AnyMechOutputFileForceExport.

Please update your affiliation data, we need to know this to provide support.

Best regards
Søren

Dear Søren,

thx a lot for your very helpful reply. I’m trying to get the components of the Muscle force using Axes (in the local-CS) of the Origin point of the muscle (as contact-point between the muscle and the segment).

i have two Questions:

  1. the Axes gives me a 9*9 Matrix, is this the Transformation-Matrix in the x,y,z directions?

  2. the muscle should have its own coordinate System (CS), shouldn’t it? but which CS should the Origin Point have(from the Segment or muscle)?

I’ll apperciate it, if you can help me

best regards

Wael

Hi Wael,

Please update your profile so it is possible to see your affiliation, thx

Best regards
Søren

Hi Søren,

I’ve just updated my profile.

Best Regards

Wael

Hi Mewal,

Axes is the rotation matrix of the reference frame, Axes is time dependent so if you have motion it will change. ARel is the relative rotation matrix wrt to parent frame, so not time dependent.

The muscles do not have their own coordinate systems they are basically strings between points and wrapping on surfaces, so you can not get Axes property of a muscle.

Please consider using the AnyForceMomentMeasure it has been designed to measure forces in any coordinate system you like.

Best regards
Søren

Hallo Søren,

i did a gait Analysis and i’m trying to measure a possible Torsion on the femur.

Is there anyway to measure the torque around the axial axis of the femur?.

I think the using of AnyForceMomentMeasure could be the solution, but i couldn’t find any tutorial or help for the right using of [b]AnyForceMomentMeasure.

[/b]Can youl please help me with this issue?

Regards

Wael

Hi Wael,

Please check the following object (Main.HumanModel.BodyModel.Left.Leg.MomentMeasure) in the model tree to see how to do it using AnyForceMomentMeasure2 object (in case it is not yet defined there).

Kind regards,
Pavel

Hallo Pavel,

i found this thread and i tried to follow the example.

https://github.com/AnyBody/support/blob/6502fb89f862830cf2a7947246597878820770a0/Wiki_Files/Kinetics/MuscleMomentMeasureExample.any

What i’m looking for is the torque around the axial axis of the femur (in his own Local-KS).

This is the code, what i wrote. I assumed that the RefFrame is the femur itself and i assumed that the Moments generated by the muscle in the femur are equal to the Moments, which are working on the femur. I’m not sure if i should use the moments, which are generated by the reaction forces of the joint , Hip"

AnyForceMomentMeasure2 MomentMeasureLoc =
{

  AnyRefFrame &Ref = Main.CanineModel.Segs.Right.Femur;
  
  AnySeg &Seg = Main.CanineModel.Segs.Right.Femur;
  
 AnyFolder &Mus1 = Main.CanineModel.Muscles.Right.Vastus_lateralis_intermedius;
 AnyFolder &Mus2 = Main.CanineModel.Muscles.Right.Vastus_medialis;
 AnyFolder &Mus3 = Main.CanineModel.Muscles.Right.Adductor_magnus;
 AnyFolder &Mus4 = Main.CanineModel.Muscles.Right.Gluteus_medius_caudalis;
};

Regards

Wael

Hi Wael,

In the ref. manual:

"F OutputVar Equivalent point force vector in global coordinates. "

So the code, from the link I recommended looks like this:

AnyForceMomentMeasure2 KneeNetMomentMuscle = {
  AnyRefNode &ref = ..Seg.Thigh.KneeJoint.RotNode;
  AnySeg &seg1=..Seg.Shank;      
  AnySeg &seg2=..Seg.Foot;      
  #include  "LegMuscleNames.any"

      AnyVec3 Mlocal=M*ref.Axes;
      AnyVar MKneeFlexion=Mlocal[2];
  
};

Where the last section shows how to recompute it in the relevant ref. frame.

Kind regards,
Pavel

Hallo Pavel,

Thx a lot for your helpful reply. Unfortunately I didn’t notice your reply until now.

I understand now how to make a transformation from local to global CS, but I’m not sure how to find the the torque around the axial axis of the femur.

I did it using the muscle forces, which go through the femur. As a reference frame I used the femur itself. So I’m not sure if that the right way to get the torque.

I would appreciate it if you could tell me if this the right way to do it.

Best regards

Wael

Hallo Pavel,

Thx a lot for your helpful reply. Unfortunately I didn’t notice your reply until now.

I understand now how to make a transformation from local to global CS, but I’m not sure how to find the the torque around the axial axis of the femur.

I did it using the muscle forces, which go through the femur. As a reference frame I used the femur itself. So I’m not sure if that the right way to get the torque.

I would appreciate it if you could tell me if this the right way to do it.

Best regards

Wael

Dear Wael,

I may be misunderstanding something. But I will refer back to the previous code:


AnyForceMomentMeasure2 MomentMeasureLoc = 
{

      AnyVec3 Mlocal=M*ref.Axes;
      AnyVar AxialTorque=Mlocal[2]; [b]// Z torque[/b]

[b] // defines the axial axis, Z aligned with the axis[/b]
AnyRefFrame &Ref = Main.CanineModel.Segs.Right.Femur.[b]NodeOfInterest;[/b];

AnySeg &Seg = Main.CanineModel.Segs.Right.Femur;

AnyFolder &Mus1 = Main.CanineModel.Muscles.Right.Vastus_lateralis_in termedius;
AnyFolder &Mus2 = Main.CanineModel.Muscles.Right.Vastus_medialis;
AnyFolder &Mus3 = Main.CanineModel.Muscles.Right.Adductor_magnus;
AnyFolder &Mus4 = Main.CanineModel.Muscles.Right.Gluteus_medius_caud alis;
};

As a result you will get the torque about Z axis (your axial axis), generated by specified muscles. You just need to define NodeOfInterest to be on the relevant axis and Z pointing in the needed direction.


Main.CanineModel.Segs.Right.Femur = {
  AnyRefNode NodeOfInterest = {
    sRel = {...}; [b]// coordinates of a point on the axis[/b]
    ARel = {...};[b]// rotation matrix to align Z axis, please read about RotMat functions[/b]
};

If that does not make sense - you could try a simple example and check your variation of this code works.

Kind regards,
Pavel

Hallo Pavel,

perfect. That’s exactly, what i wanted to know.

Thank you so much :slight_smile:

Best Regards

Wael