Skip to content

Commit

Permalink
Revert "Achilles tendon wrapping 2 (#788)"
Browse files Browse the repository at this point in the history
This reverts commit b93952b.

Revert "Add intial wrapping guess for calf muscles"

This reverts commit 771fe9d.
  • Loading branch information
melund committed Apr 27, 2023
1 parent 771fe9d commit 170d442
Show file tree
Hide file tree
Showing 5 changed files with 37 additions and 179 deletions.
127 changes: 21 additions & 106 deletions Body/AAUHuman/LegTLEM/Mus.any
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,6 @@

#if BM_FOOT_MODEL == _FOOT_MODEL_DEFAULT_


#if BM_LEG_MORPHOLOGY == 1

AnyMuscleViaPoint SoleusMedialis1 = {
AnyMuscleModel &MusMdl = ..MuscleModels.SoleusMedialis1Par;
AnyRefNode &Org = ..Seg.Shank.SoleusMedialis1Node;
Expand Down Expand Up @@ -69,7 +66,7 @@ AnyMuscleViaPoint SoleusLateralis3 = {
};
};


#if BM_LEG_MORPHOLOGY == 1
AnyMuscleShortestPath GastrocnemiusLateralis1 = {
AnyMuscleModel &MusMdl = ..MuscleModels.GastrocnemiusLateralis1Par;
AnyRefNode &Org = ..Seg.Thigh.GastrocnemiusLateralis1Node;
Expand Down Expand Up @@ -98,106 +95,22 @@ AnyMuscleShortestPath GastrocnemiusMedialis1 = {
#endif

#if BM_LEG_MORPHOLOGY == 2

AnyMuscleShortestPath SoleusMedialis1 = {
AnyMuscleModel &MusMdl = ..MuscleModels.SoleusMedialis1Par;
AnyRefNode &Org = ..Seg.Shank.SoleusMedialis1Node;
AnyRefNode &Via1 = ..Seg.Foot.SoleusMedialis1SuperiorNode;
AnyRefNode &Ins = ..Seg.Foot.SoleusMedialis1Node;
AnySurface &srf1 = ..Seg.Shank.AchillesWrapping1.Cyl;
AnySurface &srf2 = ..Seg.Shank.AchillesWrapping2.Cyl;
SPLine = {
StringMesh = 30;
AnyMatrix InitWrapPos = {
transf3D({1.005*.srf1.Radius, 0, 0.5*.srf1.Length }, &.srf1 ) ,
transf3D({-1.005*.srf2.Radius, 0, 0.5*.srf2.Length }, &.srf2 )
};
InitWrapPosVecArr = {&InitWrapPos, None};
};
AnyDrawMuscle DrwMus = {#include "../DrawSettings/MusDrawSettings.any"
};
};

AnyMuscleShortestPath SoleusMedialis2 = {
AnyMuscleModel &MusMdl = ..MuscleModels.SoleusMedialis2Par;
AnyRefNode &Org = ..Seg.Shank.SoleusMedialis2Node;
AnyRefNode &Via1 = ..Seg.Foot.SoleusMedialis2SuperiorNode;
AnyRefNode &Ins = ..Seg.Foot.SoleusMedialis2Node;
AnySurface &srf1 = ..Seg.Shank.AchillesWrapping1.Cyl;
AnySurface &srf2 = ..Seg.Shank.AchillesWrapping2.Cyl;
SPLine.StringMesh = 30;
SPLine.InitWrapPosVecArr = .SoleusMedialis1.SPLine.InitWrapPosVecArr;
AnyDrawMuscle DrwMus = {#include "../DrawSettings/MusDrawSettings.any"
};
};

AnyMuscleShortestPath SoleusMedialis3 = {
AnyMuscleModel &MusMdl = ..MuscleModels.SoleusMedialis3Par;
AnyRefNode &Org = ..Seg.Shank.SoleusMedialis3Node;
AnyRefNode &Via1 = ..Seg.Foot.SoleusMedialis3SuperiorNode;
AnyRefNode &Ins = ..Seg.Foot.SoleusMedialis3Node;
AnySurface &srf1 = ..Seg.Shank.AchillesWrapping1.Cyl;
AnySurface &srf2 = ..Seg.Shank.AchillesWrapping2.Cyl;
SPLine.StringMesh = 30;
SPLine.InitWrapPosVecArr = .SoleusMedialis1.SPLine.InitWrapPosVecArr;
AnyDrawMuscle DrwMus = {#include "../DrawSettings/MusDrawSettings.any"
};
};

AnyMuscleShortestPath SoleusLateralis1 = {
AnyMuscleModel &MusMdl = ..MuscleModels.SoleusLateralis1Par;
AnyRefNode &Org = ..Seg.Shank.SoleusLateralis1Node;
AnyRefNode &Via1 = ..Seg.Foot.SoleusLateralis1SuperiorNode;
AnyRefNode &Ins = ..Seg.Foot.SoleusLateralis1Node;
AnySurface &srf1 = ..Seg.Shank.AchillesWrapping1.Cyl;
AnySurface &srf2 = ..Seg.Shank.AchillesWrapping2.Cyl;
SPLine.StringMesh = 30;
SPLine.InitWrapPosVecArr = .SoleusMedialis1.SPLine.InitWrapPosVecArr;
AnyDrawMuscle DrwMus = {#include "../DrawSettings/MusDrawSettings.any"
};
};

AnyMuscleShortestPath SoleusLateralis2 = {
AnyMuscleModel &MusMdl = ..MuscleModels.SoleusLateralis2Par;
AnyRefNode &Org = ..Seg.Shank.SoleusLateralis2Node;
AnyRefNode &Via1 = ..Seg.Foot.SoleusLateralis2SuperiorNode;
AnyRefNode &Ins = ..Seg.Foot.SoleusLateralis2Node;
AnySurface &srf1 = ..Seg.Shank.AchillesWrapping1.Cyl;
AnySurface &srf2 = ..Seg.Shank.AchillesWrapping2.Cyl;
SPLine.StringMesh = 30;
SPLine.InitWrapPosVecArr = .SoleusMedialis1.SPLine.InitWrapPosVecArr;
AnyDrawMuscle DrwMus = {#include "../DrawSettings/MusDrawSettings.any"
};
};

AnyMuscleShortestPath SoleusLateralis3 = {
AnyMuscleModel &MusMdl = ..MuscleModels.SoleusLateralis3Par;
AnyRefNode &Org = ..Seg.Shank.SoleusLateralis3Node;
AnyRefNode &Via1 = ..Seg.Foot.SoleusLateralis3SuperiorNode;
AnyRefNode &Ins = ..Seg.Foot.SoleusLateralis3Node;
AnySurface &srf1 = ..Seg.Shank.AchillesWrapping1.Cyl;
AnySurface &srf2 = ..Seg.Shank.AchillesWrapping2.Cyl;
SPLine.StringMesh = 30;
SPLine.InitWrapPosVecArr = .SoleusMedialis1.SPLine.InitWrapPosVecArr;
AnyDrawMuscle DrwMus = {#include "../DrawSettings/MusDrawSettings.any"
};
};



AnyMuscleShortestPath GastrocnemiusLateralis1 = {
AnyMuscleModel &MusMdl = ..MuscleModels.GastrocnemiusLateralis1Par;
AnyRefNode &Org = ..Seg.Thigh.GastrocnemiusLateralis1Node;
AnySurface &srf = ..Seg.Thigh.GastroWrapSurf.cyl;
AnySurface &srf1 = ..Seg.Shank.AchillesWrapping1.Cyl;
AnySurface &srf2 = ..Seg.Shank.AchillesWrapping2.Cyl;
// AnyRefNode &Via1 = ..Seg.Thigh.GastrocnemiusLateralis1ViaNode;
// AnyRefNode &Via2 = ..Seg.Thigh.GastrocnemiusLateralis2ViaNode;
// AnyRefNode &Via3 = ..Seg.Thigh.GastrocnemiusLateralis3ViaNode;
// AnyRefNode &Via4 = ..Seg.Thigh.GastrocnemiusLateralis4ViaNode;
// AnyRefNode &Via5 = ..Seg.Thigh.GastrocnemiusLateralis5ViaNode;
// AnyRefNode &Via6 = ..Seg.Thigh.GastrocnemiusLateralis6ViaNode;
AnyRefNode &Via7 = ..Seg.Shank.GastrocnemiusLateralis7ViaNode;
AnyRefNode &Via8 = ..Seg.Shank.GastrocnemiusLateralis8ViaNode;
AnyRefNode &Via9 = ..Seg.Shank.GastrocnemiusLateralis9ViaNode;
AnyRefNode &Via10 =..Seg.Foot.GastrocnemiusLateralis1SuperiorNode;
AnyRefNode &Via10 = ..Seg.Shank.GastrocnemiusLateralis10ViaNode;
AnyRefNode &Ins = ..Seg.Foot.GastrocnemiusLateralis1Node;
SPLine.StringMesh = 30;
SPLine.InitWrapPosVecArr = {None,None,None,&.SoleusMedialis1.SPLine.InitWrapPos, None};
SPLine.StringMesh = 45;
AnyDrawMuscle DrwMus = {
#include "../DrawSettings/MusDrawSettings.any"
};
Expand All @@ -208,16 +121,16 @@ AnyMuscleShortestPath GastrocnemiusMedialis1 = {
AnyRefNode &Org = ..Seg.Thigh.GastrocnemiusMedialis1Node;
AnyRefNode &Via1 = ..Seg.Thigh.GastrocnemiusMedialis1ViaNode;
AnySurface &srf = ..Seg.Thigh.GastroWrapSurf.cyl;
AnySurface &srf1 = ..Seg.Shank.AchillesWrapping1.Cyl;
AnySurface &srf2 = ..Seg.Shank.AchillesWrapping2.Cyl;
// AnyRefNode &Via2 = ..Seg.Thigh.GastrocnemiusMedialis2ViaNode;
// AnyRefNode &Via3 = ..Seg.Thigh.GastrocnemiusMedialis3ViaNode;
AnyRefNode &Via4 = ..Seg.Shank.GastrocnemiusMedialis4ViaNode;
AnyRefNode &Via5 = ..Seg.Shank.GastrocnemiusMedialis5ViaNode;
AnyRefNode &Via6 = ..Seg.Shank.GastrocnemiusMedialis6ViaNode;
AnyRefNode &Via7 = ..Seg.Shank.GastrocnemiusMedialis7ViaNode;
AnyRefNode &Via8 =..Seg.Foot.GastrocnemiusMedialis1SuperiorNode;
AnyRefNode &Via8 = ..Seg.Shank.GastrocnemiusMedialis8ViaNode;
AnyRefNode &Via9 = ..Seg.Shank.GastrocnemiusMedialis9ViaNode;
AnyRefNode &Ins = ..Seg.Foot.GastrocnemiusMedialis1Node;
SPLine.StringMesh = 30;
SPLine.InitWrapPosVecArr = {None,None,None, None, None, &.SoleusMedialis1.SPLine.InitWrapPos, None};
SPLine.StringMesh = 45;
AnyDrawMuscle DrwMus = {
#include "../DrawSettings/MusDrawSettings.any"
};
Expand Down Expand Up @@ -3031,12 +2944,14 @@ AnyMuscleShortestPath Plantaris1 = {
AnyMuscleModel &MusMdl = ..MuscleModels.Plantaris1Par;
AnyRefNode &Org = ..Seg.Thigh.Plantaris1Node;
AnySurface &srf = ..Seg.Thigh.GastroWrapSurf.cyl;
AnySurface &srf1 = ..Seg.Shank.AchillesWrapping1.Cyl;
AnySurface &srf2 = ..Seg.Shank.AchillesWrapping2.Cyl;
AnyRefNode &Via1 =..Seg.Foot.Plantaris1SuperiorNode;
SPLine = {
AnyMatrix InitWrapPos = {
transf3D({0.5*.srf.Radius, 1.2*...Sign*.srf.Radius, 0.8*.srf.Length}, &.srf)
};
InitWrapPosVecArr = {&InitWrapPos};
StringMesh = 90;
};
AnyRefNode &Ins = ..Seg.Foot.Plantaris1Node;
SPLine.StringMesh = 30;
SPLine.InitWrapPosVecArr = {&.SoleusMedialis1.SPLine.InitWrapPos, None};
AnyDrawMuscle DrwMus = {#include "../DrawSettings/MusDrawSettings.any"
};
};
Expand Down
37 changes: 1 addition & 36 deletions Body/AAUHuman/LegTLEM/Seg.any
Original file line number Diff line number Diff line change
Expand Up @@ -520,21 +520,7 @@ AnySeg Foot =
AnyRefNode SoleusLateralis2Node = {sRel = .Scale( .StdPar.SoleusLateralis2Node );};
AnyRefNode SoleusLateralis3Node = {sRel = .Scale( .StdPar.SoleusLateralis3Node );};

#if BM_LEG_MORPHOLOGY == 2
AnyRefNode TendonCalcaneousSuperiorNode = {sRel = .Scale( .StdPar.TendonCalcaneousSuperiorNode );};
AnyRefNode GastrocnemiusLateralis1SuperiorNode = {sRel = .Scale( .StdPar.GastrocnemiusLateralis1SuperiorNode );};
AnyRefNode GastrocnemiusMedialis1SuperiorNode = {sRel = .Scale( .StdPar.GastrocnemiusMedialis1SuperiorNode );};
AnyRefNode Plantaris1SuperiorNode = {sRel = .Scale( .StdPar.Plantaris1SuperiorNode );};

AnyRefNode SoleusMedialis1SuperiorNode = {sRel = .Scale( .StdPar.SoleusMedialis1SuperiorNode );};
AnyRefNode SoleusMedialis2SuperiorNode = {sRel = .Scale( .StdPar.SoleusMedialis2SuperiorNode );};
AnyRefNode SoleusMedialis3SuperiorNode = {sRel = .Scale( .StdPar.SoleusMedialis3SuperiorNode );};
AnyRefNode SoleusLateralis1SuperiorNode = {sRel = .Scale( .StdPar.SoleusLateralis1SuperiorNode );};
AnyRefNode SoleusLateralis2SuperiorNode = {sRel = .Scale( .StdPar.SoleusLateralis2SuperiorNode );};
AnyRefNode SoleusLateralis3SuperiorNode = {sRel = .Scale( .StdPar.SoleusLateralis3SuperiorNode );};
#endif

//Insertion points on Midfoot:
//Insertion points on Midfoot:
#if BM_LEG_MORPHOLOGY == 1
AnyRefNode PeroneusBrevis1Node = {sRel = .Scale( .StdPar.PeroneusBrevis1Node );};
AnyRefNode PeroneusBrevis2Node = {sRel = .Scale( .StdPar.PeroneusBrevis2Node );};
Expand Down Expand Up @@ -795,27 +781,6 @@ AnySeg Shank =

};
#endif

#if BM_FOOT_MODEL != _FOOT_MODEL_NONE_
AnyRefNode AchillesWrapping1 = {
AnyVar ShankLengthScale = vnorm(.AnkleJoint.sRel-.KneeJoint.sRel)
/vnorm(.StdPar.AnkleJoint-.StdPar.KneeJoint);
sRel = .Scale({-0.0336, 0.0987, 0});
AnySurfCylinder Cyl = {
Length = 0.2;
sRel = {-Radius,0,-0.5*Length};
Radius = .ShankLengthScale*0.105;
};
};
AnyRefNode AchillesWrapping2 = {
sRel = .Scale({-0.032, 0.0437, 0.000});
AnySurfCylinder Cyl = {
Length = 0.2;
sRel = {Radius,0,-0.5*Length};
Radius = ..AchillesWrapping1.ShankLengthScale*0.07;
};
};
#endif

//BonyLandMarks
AnyRefNode MedialTibialEpicondyle =
Expand Down
20 changes: 3 additions & 17 deletions Body/AAUHuman/LegTLEM/TLEM2.1/ModelParameters.any
Original file line number Diff line number Diff line change
Expand Up @@ -728,31 +728,17 @@ AnyFolder ModelParameters = {

// TendonCalcaneousNode, Point using 1 elements
AnyVec3 TendonCalcaneousNode = {-0.03679,-0.01718,-0.00514}*.TF';
AnyVec3 TendonCalcaneousMedialisNode = TendonCalcaneousNode-{0, 0, 0.003}*.TF';
AnyVec3 TendonCalcaneousLateralisNode = TendonCalcaneousNode+{-0.001, 0, 0.003}*.TF';
AnyVec3 TendonCalcaneousMedialisNode = TendonCalcaneousNode-{0, 0,0.005}*.TF';
AnyVec3 TendonCalcaneousLateralisNode = TendonCalcaneousNode+{0, 0,0.005}*.TF';
AnyVec3 GastrocnemiusLateralis1Node = TendonCalcaneousLateralisNode;
AnyVec3 GastrocnemiusMedialis1Node = TendonCalcaneousMedialisNode;
AnyVec3 Plantaris1Node = TendonCalcaneousMedialisNode;
AnyVec3 Plantaris1Node = TendonCalcaneousNode;
AnyVec3 SoleusMedialis1Node = TendonCalcaneousMedialisNode;
AnyVec3 SoleusMedialis2Node = TendonCalcaneousMedialisNode;
AnyVec3 SoleusMedialis3Node = TendonCalcaneousMedialisNode;
AnyVec3 SoleusLateralis1Node = TendonCalcaneousLateralisNode;
AnyVec3 SoleusLateralis2Node = TendonCalcaneousLateralisNode;
AnyVec3 SoleusLateralis3Node = TendonCalcaneousLateralisNode;

AnyVec3 TendonCalcaneousSuperiorNode = {-0.03679,-0.003,-0.00514}*.TF';
AnyVec3 TendonCalcaneousMedialisSuperiorNode = TendonCalcaneousSuperiorNode-{0, 0,0.003}*.TF';
AnyVec3 TendonCalcaneousLateralisSuperiorNode = TendonCalcaneousSuperiorNode+{-0.001, 0,0.003}*.TF';
AnyVec3 GastrocnemiusLateralis1SuperiorNode = TendonCalcaneousLateralisSuperiorNode;
AnyVec3 GastrocnemiusMedialis1SuperiorNode = TendonCalcaneousMedialisSuperiorNode;
AnyVec3 Plantaris1SuperiorNode = TendonCalcaneousMedialisSuperiorNode;
AnyVec3 SoleusMedialis1SuperiorNode = TendonCalcaneousMedialisSuperiorNode;
AnyVec3 SoleusMedialis2SuperiorNode = TendonCalcaneousMedialisSuperiorNode;
AnyVec3 SoleusMedialis3SuperiorNode = TendonCalcaneousMedialisSuperiorNode;
AnyVec3 SoleusLateralis1SuperiorNode = TendonCalcaneousLateralisSuperiorNode;
AnyVec3 SoleusLateralis2SuperiorNode = TendonCalcaneousLateralisSuperiorNode;
AnyVec3 SoleusLateralis3SuperiorNode = TendonCalcaneousLateralisSuperiorNode;


// PeroneusBrevisDistal, Point using 1 elements
AnyVec3 PeroneusBrevisDistal1Node = {0.04494,-0.02783,0.03219}*.TF';
Expand Down
9 changes: 0 additions & 9 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,15 +49,6 @@ to account for pelvis segment morphing into leg pelvis coordinate system using

### Changed:

* Wrapping surfaces have been added to the achilles tendon around the ankle in
the TLEM 2.0 leg model. This ensures a even ratio of moment arms between
the soleus and gastrocnemius muscles. Hence, gastroc is recruited less in
especially during downhill walking and stair descent, solving the models tendency
to overpredict the knee contact forces at toe off.
This is the first of a number of improvements to the leg model by Dr. Enrico De Pieri
who is working on a publication on improvements and validation of the TLEM 2 leg model.


* Adjustments to pelvic tilt have changed position of MoCap markers on the pelvis
segment. This mostly affect markers with hardcoded positions.
Particularly PSIS markers furthest posterior from the origin between ASIS. When migrating
Expand Down
23 changes: 12 additions & 11 deletions Tests/Applications/test_EvaluateJointStrength.any
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,10 @@

#ifndef TEST_NAME

#define BM_LEG_MODEL 0
#define BM_ARM_LEFT 1
#define BM_ARM_RIGHT 1
#define BM_LEG_MODEL 2
#define BM_ARM_LEFT 0
#define BM_ARM_RIGHT 0
#define TEST_NAME "GUI"

// #define CREATE_IMAGE 0
#define BM_TRUNK_MUSCLES ON
Expand All @@ -40,14 +41,14 @@ Main =
#if BM_TRUNK_MUSCLES == OFF
AnyOperation& RunTest = Main.RunApplication;
#else
AnyOperationSequence RunTest = {
AnyOperation& PelvisThoraxFlexion = Main.HumanModel.EvalulateJointStrength.Run_all_studies.PelvisThoraxFlexion;
AnyOperation& PelvisThoraxExtension = Main.HumanModel.EvalulateJointStrength.Run_all_studies.PelvisThoraxExtension;
AnyOperation& PelvisThoraxLateralBendingRight = Main.HumanModel.EvalulateJointStrength.Run_all_studies.PelvisThoraxLateralBendingRight;
AnyOperation& PelvisThoraxLateralBendingLeft = Main.HumanModel.EvalulateJointStrength.Run_all_studies.PelvisThoraxLateralBendingLeft;
AnyOperation& PelvisThoraxRotationRight = Main.HumanModel.EvalulateJointStrength.Run_all_studies.PelvisThoraxRotationRight;
AnyOperation& PelvisThoraxRotationLeft = Main.HumanModel.EvalulateJointStrength.Run_all_studies.PelvisThoraxRotationLeft;
};
// AnyOperationSequence RunTest = {
// AnyOperation& PelvisThoraxFlexion = Main.HumanModel.EvalulateJointStrength.Run_all_studies.PelvisThoraxFlexion;
//// AnyOperation& PelvisThoraxExtension = Main.HumanModel.EvalulateJointStrength.Run_all_studies.PelvisThoraxExtension;
//// AnyOperation& PelvisThoraxLateralBendingRight = Main.HumanModel.EvalulateJointStrength.Run_all_studies.PelvisThoraxLateralBendingRight;
//// AnyOperation& PelvisThoraxLateralBendingLeft = Main.HumanModel.EvalulateJointStrength.Run_all_studies.PelvisThoraxLateralBendingLeft;
//// AnyOperation& PelvisThoraxRotationRight = Main.HumanModel.EvalulateJointStrength.Run_all_studies.PelvisThoraxRotationRight;
//// AnyOperation& PelvisThoraxRotationLeft = Main.HumanModel.EvalulateJointStrength.Run_all_studies.PelvisThoraxRotationLeft;
// };
#endif

#else
Expand Down

0 comments on commit 170d442

Please sign in to comment.