Upper Body Model

Hello All,

I’m currently trying to get an Upper Body Model to move in the example: GaitFullBody.

I can read my own C3D file and link the markers to the segments, but when I try to run a MotionAndParameterOptimizationSequence, I get the error:

Macro command > operation Main.Studies.ParameterIdentification.ParameterOpti mization

Macro command > run

  1. Operation Sequence: (Operation: Main.Studies.ParameterIdentification.Analysis):
    0.0) Kinematics (Operation: Main.Studies.KinematicStudyForParameterIdentificat ion.Kinematics):
    0.0.0) PreOperation (Operation: Main.Studies.KinematicStudyForParameterIdentificat ion.Kinematics.PreOperation):
    0.0.0) InitialConditions (Operation: Main.Studies.KinematicStudyForParameterIdentificat ion.InitialConditions):
    0.0.0) …Design variables have been updated.
    0.0.1) …Load time positions have been re-established.
    Position analysis failed : 275 independent constraints and 282 unknowns
    • attempts to continue (attempt no. 1)
      etc…
      Position analysis failed : 275 independent constraints and 282 unknowns
    • attempts to continue (attempt no. 10)
      Constraint no. #0 in ‘Main.Studies.KinematicStudyForParameterIdentifica tion.HumanModel.BodyModel.Right.ShoulderArm.Mus.Ar tificialRake.LinCombDrv’ above error tolerance 0.001000, error = 0.029193.
      etc…

The markers from the C3D file are within 1mm of the markers of the Segments. You could say, in the Model View they are practically on the same position.

I’ve made the Trunk / Pelvis Initial Position a constant value.
I have no driver that links the Pelvis to the other markers…

If that could be a problem, how do I solve this?
I do not know what to drive the Pelvis with,
I have no markers on the Pelvis.

I’ve read the Tutorials and Forum, tried many different options in order to remove these errors, but nothing worked so far.

Does anyone have an idea where I should look for an answer?

My AnyBody folder is added as a Zip file.

Hi,

The problem is that you are missing some drivers in the ExtraDrivers file. First you should keep the SCDriverRight because the SHO marker is not enough to driver the axial rotation of the clavicula. Second one is the neck: you have no markers on the head so you need a driver for the neck joint. And finaly the Cane segment also needs a driver. You used an IF statement to enable this driver only during the inverse dynamic, but it also needed during the optimization for the kinematic.

It should work fine if you add those drivers.

Best regards, Sylvain.

Hello Sylvain,

Thank you for your reply.

I`m an inexperienced user and do not yet know how to write a driver or how to correctly link this to a certain segment/movement. I want the Cane segment to be driven by the right hand. I’ve made the link a RigidJoint, but what do I need to add? I also do not yet know how to drive the neck joint, could you give some examples/demo’s where I could look?

I’m also interested in tilting and turning the Cane segment into an initial position. Now it has a constant start, but this does not reflect the real life measurement.

I’ll search through the database and tutorials, but if you could give me a direction, I would be very grateful.

Greetings,

Hans

Extra Information:

I’ve now also looked at the BodyPartsSetup.any , It seems that when I want to have the Trunk_Neck instead of Trunk, AnyBody.exe seems to be having an error. This occurs in multiple examples/demo’s.

I receive this well-known Microsoft pop-up message:

AnyBody.exe has encountered a problem and needs to close. We are sorry for the inconvenience.

My AnyBody:
AnyBody version : 5. 0. 0. 2014
Build : 14963.38760

Hi Hans,

Forthe drivers in general it is a good idea to read the tutorials first. It will give you all the basic notions that you need.

For the cane the standard joint you used will work fine. The cane will follow the hand kinematically and in term of force you will have reactions in all 6 DoF. So there is nothing to add. For the neck joint you can copy the neck driver of the FreePosture model and put it in the ExtraDrivers file (and eventually update the relative path of the references).

You can also set the initial position of the cane segment using the r0 and Axes0 menbers of the segment. This can be made dependent of the hand initial position if you wish (you can look at the bone segments r0 in the Seg file to see an example of this dependency).

The error concerning the Trunk_Neck model is a bit surprising, and i can’t reproduce the faillure on my machine so far. Please give us more details, including the repository version, if it happens systematically and for which models. Also if you can describe us exactly one configuration that creates the crash we can try to reproduce it and debug it.

Best regards, Sylvain.

Hello Sylvain,

I’ve taken the example FreePosture, it crashes during Parsing…

Loading Settings Script from : 'C:\Documents and Settings\hans.essers\Local Settings\Application Data\AnyBody Technology\AnyBody.5.x.x\Settings.anyst
Settings Loaded
Loading Main : “C:\Documents and Settings\hans.essers\Application Data\AnyBody Technology\AnyBody.5.x.x\AMMRV1.3\Application\Examples\FreePosture\BodyPartsSetup.any”
Scanning…
Parsing…

It happens with all of my other examples as well, I haven’t modified these examples and they work when I let the Trunk active;

// Trunk: 1 included, 0 not included
// *********************************
#define TRUNK 0
// This is just the bones,
// Choose one of the following options to add muscles
#define TRUNK_SIMPLE_MUSCLES 0
// Additional stiffness in the lumbar joints can be added.
#define TRUNK_DISC_STIFFNESS_NORMAL 0

// Trunk with neck: 1 included, 0 not included
// *********************************
#define TRUNK_NECK 1
// This is just the bones,
// Choose one of the following options to add muscles
#define TRUNK_NECK_SIMPLE_MUSCLES 0
#define TRUNK_NECK_SIMPLE_MUSCLES_ONLY_ON_NECK 0
// Additional stiffness in the lumbar joints can be added.
#define TRUNK_NECK_DISC_STIFFNESS_NORMAL 0

If I activate them both, AnyBody does recognize that both Trunks are activated

For the Neck Driver, I’ve copied the following code:

//Neck driver
AnyKinEqSimpleDriver CervicalDriver ={
AnyKinMeasureOrg &Ref1 = .RefHM.Interface.Trunk.SkullThoraxFlexion;
AnyKinMeasureOrg &Ref2 = .RefHM.Interface.Trunk.SkullThoraxLateralBending;
AnyKinMeasureOrg &Ref3 = .RefHM.Interface.Trunk.SkullThoraxRotation;
DriverPos = pi/180*{0, 0, 0};
DriverVel = pi/180*{0, 0, 0};
Reaction.Type = {Off, Off, Off};
};

But I do not have the SkullThoraxFlexion / Rotation / LateralBending,
I’ve searched and found the Interface.Trunk, so I guessed that in order to get these three, I needed to add the Trunk_Neck, but this makes my AnyBody crash, so I don’t know if that would be correct

My AnyBody version is:

AnyBody version : 5. 0. 0. 2014
Build : 14963.38760

Before I received a Dongle, I used a Demo Trial for 30 days, so I’ve received the installed program a few months ago from one of your colleagues

Thanks for the help,

Hans

Quick Update:

I’ve added this Neck Driver:

//Neck driver
AnyKinEqSimpleDriver NeckJntDriver = {
AnyRevoluteJoint &T12L1Joint = …HumanModel.BodyModel.Interface.Trunk.NeckJoint;
DriverPos = pi/180*{.JntPos.NeckExtension};
DriverVel = pi/180*{.JntVel.NeckExtension};
Reaction.Type = {Off};
};

It did not give me any errors, so I’m going to test if everything works

I’ve tested the new code, but I still seem to have more DoF than designated drivers,

Macro command > runmacro “C:\Documents and Settings\hans.essers\Application Data\AnyBody Technology\AnyBody.5.x.x\AMMRV1.3\Application\Examples\Copy of GaitFullBody\Sequence1.anymcr”

Macro command > operation Main.Studies.ParameterIdentification.ParameterOptimization

Macro command > run

  1. Operation Sequence: (Operation: Main.Studies.ParameterIdentification.Analysis):
    0.0) Kinematics (Operation: Main.Studies.KinematicStudyForParameterIdentification.Kinematics):
    0.0.0) PreOperation (Operation: Main.Studies.KinematicStudyForParameterIdentification.Kinematics.PreOperation):
    0.0.0) InitialConditions (Operation: Main.Studies.KinematicStudyForParameterIdentification.InitialConditions):
    WARNING for Main.Studies.KinematicStudyForParameterIdentification.EnvironmentModel.Cane: Non-orthogonal axes were adjusted.
    0.0.0) …Design variables have been updated.
    0.0.1) …Load time positions have been re-established.
    Position analysis failed : 553 independent constraints and 559 unknowns

Constraint no. #0 in Trunk.Buckle.Slider1.Slider1Jnt.Constraints’ above error tolerance 0.001000, error = 0.034232.
etc…

ERROR(OBJ.MCH.KIN3) : /GaitFullBody.main.any : KinematicStudyForParameterIdentification.InitialConditions : Kinematic analysis failed in time step 0

Macro command > runmacro “SaveMacroOperation-Save.anymcr”

Macro command > classoperation Main.ModelSetup.SaveMacroOperation “Save AnyString to file” --file=“RunMacroOperation-Save.anymcr”

Macro command > runmacro “RunMacroOperation-Save.anymcr”

Macro command > classoperation Main.Studies.ParameterIdentification “Save design” --file=“GaitNormal0003-processed-OptimizedParameters.txt”

Macro command > operation Main.Studies.MotionOptimization.Kinematics

Error : Main.Studies.MotionOptimization.Kinematics : object is not AnyOperation.

I’ve adjusted the Cane Segment Axes0 to Wrist - Hand + (angle of cane in hand itself), but I receive the following message:
WARNING for Main.Studies.KinematicStudyForParameterIdentification.EnvironmentModel.Cane: Non-orthogonal axes were adjusted.

I don’t have any Legs nor markers to drive them, do I need them?
I’ve attached my current Code as a zip

Greetings,

Hans

All Constraints:

Constraint no. #0 in Trunk.Buckle.Slider1.Slider1Jnt.Constraints’ above error tolerance 0.001000, error = 0.034232.
Constraint no. #0 in Trunk.Buckle.Slider2.Slider1Jnt.Constraints’ above error tolerance 0.001000, error = 0.030629.
Constraint no. #0 in Trunk.Buckle.Slider3.Slider1Jnt.Constraints’ above error tolerance 0.001000, error = 0.028827.
Constraint no. #0 in Trunk.Buckle.Slider4.Slider1Jnt.Constraints’ above error tolerance 0.001000, error = 0.089713.
Constraint no. #0 in Trunk.Buckle.Slider4.LinDrv’ above error tolerance 0.001000, error = 0.082664.
Constraint no. #0 in Trunk.Buckle.Slider5.Slider1Jnt.Constraints’ above error tolerance 0.001000, error = 0.005855.
Constraint no. #0 in Trunk.Buckle.Disc1.Disc.LinDrvRight’ above error tolerance 0.001000, error = 0.026498.
Constraint no. #0 in Trunk.Buckle.Disc1.Disc.LinDrvLeft’ above error tolerance 0.001000, error = 0.026498.
Constraint no. #0 in Trunk.Buckle.Disc1.Disc.drv’ above error tolerance 0.001000, error = 0.122614.
Constraint no. #0 in Trunk.Buckle.Disc2.Disc.LinDrvRight’ above error tolerance 0.001000, error = 0.016525.
Constraint no. #0 in Trunk.Buckle.Disc2.Disc.LinDrvLeft’ above error tolerance 0.001000, error = 0.016525.
Constraint no. #0 in Trunk.Buckle.Disc2.Disc.drv’ above error tolerance 0.001000, error = 0.109101.
Constraint no. #0 in Trunk.Buckle.Disc3.Disc.drv’ above error tolerance 0.001000, error = 0.100093.
Constraint no. #0 in Trunk.Buckle.Disc4.Disc.drv’ above error tolerance 0.001000, error = 0.086580.
Constraint no. #0 in Trunk.Buckle.Disc5.Disc.LinDrvRight’ above error tolerance 0.001000, error = 0.001095.
Constraint no. #0 in Trunk.Buckle.Disc5.Disc.LinDrvLeft’ above error tolerance 0.001000, error = 0.001095.
Constraint no. #0 in Trunk.Buckle.Disc5.Disc.drv’ above error tolerance 0.001000, error = 0.077572.
Constraint no. #0 in Trunk.Buckle.JointsAndDrivers.LinTopDrv’ above error tolerance 0.001000, error = 0.028827.
Constraint no. #1 in Trunk.Buckle.JointsAndDrivers.LinTopDrv’ above error tolerance 0.001000, error = 0.065311.
Constraint no. #0 in Trunk.Buckle.JointsAndDrivers.LinBottomDrv’ above error tolerance 0.001000, error = 0.018017.
Constraint no. #0 in Trunk.Buckle.JointsAndDrivers.MeasuringSegmentRight.Drv1’ above error tolerance 0.001000, error = 0.045042.
Constraint no. #1 in Trunk.Buckle.JointsAndDrivers.MeasuringSegmentRight.Drv1’ above error tolerance 0.001000, error = 0.021899.
Constraint no. #0 in Trunk.Buckle.JointsAndDrivers.MeasuringSegmentLeft.Drv1’ above error tolerance 0.001000, error = 0.045042.
Constraint no. #1 in Trunk.Buckle.JointsAndDrivers.MeasuringSegmentLeft.Drv1’ above error tolerance 0.001000, error = 0.021899.
Constraint no. #0 in Right.ShoulderArm.Jnt.SCLinCon’ above error tolerance 0.001000, error = 0.005333.
Constraint no. #1 in Right.ShoulderArm.Jnt.SCLinCon’ above error tolerance 0.001000, error = 0.002039.
Constraint no. #2 in Right.ShoulderArm.Jnt.SCLinCon’ above error tolerance 0.001000, error = 0.010570.
Constraint no. #1 in Right.ShoulderArm.Jnt.ACLinCon’ above error tolerance 0.001000, error = 0.002877.
Constraint no. #2 in Right.ShoulderArm.Jnt.ACLinCon’ above error tolerance 0.001000, error = 0.006475.
Constraint no. #1 in Right.ShoulderArm.Jnt.FE.Constraints’ above error tolerance 0.001000, error = 0.006709.
Constraint no. #2 in Right.ShoulderArm.Jnt.FE.Constraints’ above error tolerance 0.001000, error = 0.004357.
Constraint no. #0 in Right.ShoulderArm.Jnt.PSProximalConstraints’ above error tolerance 0.001000, error = 0.004893.
Constraint no. #2 in Right.ShoulderArm.Jnt.PSProximalConstraints’ above error tolerance 0.001000, error = 0.004467.
Constraint no. #0 in Right.ShoulderArm.Jnt.PSLinDistalConstraint’ above error tolerance 0.001000, error = 0.019643.
Constraint no. #1 in Right.ShoulderArm.Jnt.PSLinDistalConstraint’ above error tolerance 0.001000, error = 0.001372.
Constraint no. #0 in Right.ShoulderArm.Jnt.WristJointDeviation.Constraints’ above error tolerance 0.001000, error = 0.013156.
Constraint no. #1 in Right.ShoulderArm.Jnt.WristJointDeviation.Constraints’ above error tolerance 0.001000, error = 0.004788.
Constraint no. #0 in Right.ShoulderArm.Jnt.ScapulaAIThoraxNodeDriver’ above error tolerance 0.001000, error = 0.012295.
Constraint no. #0 in Right.ShoulderArm.Jnt.ScapulaTSThoraxNodeDriver’ above error tolerance 0.001000, error = 0.016981.
Constraint no. #0 in Right.ShoulderArm.Jnt.ScapulaAIThoraxNodeReaction.ContactSegDriver’ above error tolerance 0.001000, error = 0.012217.
Constraint no. #1 in Right.ShoulderArm.Jnt.ScapulaAIThoraxNodeReaction.ContactSegDriver’ above error tolerance 0.001000, error = 0.012280.
Constraint no. #2 in Right.ShoulderArm.Jnt.ScapulaAIThoraxNodeReaction.ContactSegDriver’ above error tolerance 0.001000, error = 0.012428.
Constraint no. #3 in Right.ShoulderArm.Jnt.ScapulaAIThoraxNodeReaction.ContactSegDriver’ above error tolerance 0.001000, error = 0.315552.
Constraint no. #0 in Right.ShoulderArm.Jnt.ScapulaTSThoraxNodeReaction.ContactSegDriver’ above error tolerance 0.001000, error = 0.017361.
Constraint no. #1 in Right.ShoulderArm.Jnt.ScapulaTSThoraxNodeReaction.ContactSegDriver’ above error tolerance 0.001000, error = 0.016878.
Constraint no. #2 in Right.ShoulderArm.Jnt.ScapulaTSThoraxNodeReaction.ContactSegDriver’ above error tolerance 0.001000, error = 0.016831.
Constraint no. #3 in Right.ShoulderArm.Jnt.ScapulaTSThoraxNodeReaction.ContactSegDriver’ above error tolerance 0.001000, error = 0.315552.
Constraint no. #0 in Right.ShoulderArm.Jnt.ConoideumLigamentDrv’ above error tolerance 0.001000, error = 0.004350.
Constraint no. #1 in Right.ShoulderArm.Jnt.HandGloveLinDrv’ above error tolerance 0.001000, error = 0.005961.
Constraint no. #2 in Right.ShoulderArm.Jnt.HandGloveLinDrv’ above error tolerance 0.001000, error = 0.005173.
Constraint no. #0 in Right.ShoulderArm.Mus.ArtificialRake.LinCombDrv’ above error tolerance 0.001000, error = 0.040057.
Constraint no. #1 in Right.ShoulderArm.Mus.ArtificialRake.LinCombDrv’ above error tolerance 0.001000, error = 0.317713.
Constraint no. #2 in Right.ShoulderArm.Mus.ArtificialRake.LinCombDrv’ above error tolerance 0.001000, error = 0.179964.
Constraint no. #0 in Right.ShoulderArm.Mus.ArtificialRake.LinCom2Drv’ above error tolerance 0.001000, error = 0.100000.
Constraint no. #0 in Right.ShoulderArm.Mus.Pectoralis_minor2_cyl.Cylinder.SphericalJoint.Constraints’ above error tolerance 0.001000, error = 0.064048.
Constraint no. #1 in Right.ShoulderArm.Mus.Pectoralis_minor2_cyl.Cylinder.SphericalJoint.Constraints’ above error tolerance 0.001000, error = 0.072671.
Constraint no. #2 in Right.ShoulderArm.Mus.Pectoralis_minor2_cyl.Cylinder.SphericalJoint.Constraints’ above error tolerance 0.001000, error = 0.033211.
Constraint no. #0 in Right.ShoulderArm.Mus.Pectoralis_minor2_cyl.Cylinder.CylRotDrv2’ above error tolerance 0.001000, error = 0.325201.
Constraint no. #0 in ModelEnvironmentConnection.Drivers.SCDriverRight’ above error tolerance 0.001000, error = 0.209293.
Constraint no. #0 in Drivers.RigidCane.Constraints’ above error tolerance 0.001000, error = 0.023194.
Constraint no. #1 in Drivers.RigidCane.Constraints’ above error tolerance 0.001000, error = 0.017398.
Constraint no. #2 in Drivers.RigidCane.Constraints’ above error tolerance 0.001000, error = 0.046276.
Constraint no. #3 in Drivers.RigidCane.Constraints’ above error tolerance 0.001000, error = 2.199873.
Constraint no. #4 in Drivers.RigidCane.Constraints’ above error tolerance 0.001000, error = 0.172973.
Constraint no. #5 in Drivers.RigidCane.Constraints’ above error tolerance 0.001000, error = 0.441141.

Hi Hans,

Sorry for the late answer.

First for the error that crashes AnyBody: I have reproduced the error with the FreePosture model. However I can see you are loading the file BodyPartsSetup.any. This is not the right one, you always have to load the main file. That should avoid the crash.

For the neck driver: It seems you got this part already. The CervicalDriver has to be used when the Trunk_Neck model is used. It should not crash anymore if you load correctly the main file. I fit still does please report it.
And the NeckJntDriver correspond to the simple flexion extension DoF of the TRUNK model.

Finally there are still some problems in the ExtraDrivers file. You drive both the hand and the cane to a fixed point of the GlobalRef, that’wrong. You should just have one joint between the hand and the cane (or a node of the Cane).
Then the model is moving forward (walking) so you cannot drive the pelvis to a fixed position even with a soft driver, the solution is to have only the posture driver. In short the ExtraDriver file should look like this:

AnyKinEqSimpleDriver SCDriverRight ={
AnyKinMeasureOrg &ref3 =…HumanModel.BodyModel.Interface.Right.SternoClavicularAxialRotation;
DriverPos = pi/180*{
.JntPos.Right.SternoClavicularAxialRotation
};
DriverVel = {
.JntVel.Right.SternoClavicularAxialRotation
};
Reaction.Type={Off};
};

// Cane Joint
AnyStdJoint RigidCane =
{
AnyRefFrame &RFIN = …HumanModel.BodyModel.Right.ShoulderArm.Seg.Hand;
AnyRefFrame &Hub = …EnvironmentModel.Cane;
};

//Neck driver
AnyKinEqSimpleDriver NeckJntDriver = {
AnyRevoluteJoint &T12L1Joint = …HumanModel.BodyModel.Interface.Trunk.NeckJoint;
DriverPos = pi/180*{.JntPos.NeckExtension};
DriverVel = pi/180*{.JntVel.NeckExtension};
Reaction.Type = {Off};
};

//Thorax pelvis rotation driver
AnyKinEqSimpleDriver PostureDriver ={
AnyKinMeasureOrg &Ref2 = …HumanModel.BodyModel.Interface.Trunk.PelvisThoraxLateralBending;
AnyKinMeasureOrg &Ref3 = …HumanModel.BodyModel.Interface.Trunk.PelvisThoraxRotation;
AnyKinMeasureOrg &Ref1 = …HumanModel.BodyModel.Interface.Trunk.PelvisThoraxExtension;

DriverPos = pi/180*{
.JntPos.PelvisThoraxLateralBending,
.JntPos.PelvisThoraxRotation,
.JntPos.PelvisThoraxExtension
};
DriverVel = pi/180*{
.JntVel.PelvisThoraxLateralBending,
.JntVel.PelvisThoraxRotation,
.JntVel.PelvisThoraxExtension
};
Reaction.Type = {Off,Off,Off};
};

Also you have switched On the muscles for the kinematic optimization, this is not necessary and will cost you computational time, just remove them.

Best regards, Sylvain.

Hello Sylvain,

Thank you for your reply. My model is moving now with the Cane segment attached. However I can’t reposition my Cane segment anymore, it’s reference and starting position is now locked to the Hand. I wish to set the Cane to it’s realistic starting position in the Hand.

The former used method with Axes0 does not work in RunMotionAndParameterOptimizationSequence.

AnySeg Cane = {
r0 = .GlobalRef.Hub.sRel;

Axes0 = ..HumanModel.BodyModel.Right.ShoulderArm.Seg.WristJointSeg.Axes0
-..HumanModel.BodyModel.Right.ShoulderArm.Seg.Hand.Axes0
+{{1.0, 0.0, 0.0}, {0.7, 0.0, 0.0}, {0.0, 0.0, 0.0}};

Mass = 0.21773;
Jii = {0.00733, 0.00001, 0.00733};
sCoM = {0.0, 0.65, 0.0};
JaboutCoMOnOff = On;

As for Inverse Dynamics; the folder HumanModel.BodyModel is in a different place, so AnyBody does not find the BodyModel (Constructing model tree…
ERROR(SCR.PRS9) : C:/D…s/h…s/A…a/A…y/A…x/A…3/A…n/E…s/C…y/Environment.any : ‘BodyModel’ : Unresolved object)

I also have a question about the Jii. What is the Unit in which this needs to be filled? Is it Kgm^2? Because the Inertia values of the Cane is measured at 73,3 kgm^2 for 2 DoF and very small for the last. But when I input 73,3 (instead of 0.00733) the segment is blown out of proportion. Should I just scale it down with InertiaScale or remain with the 1/10000 version?

I also tried an Inverse Dynamic Analysis and got the following errors:

3.0) InitialConditions (Operation: Main.Studies.InverseDynamicStudy.InitialConditions):
3.0) …Design variables have been updated.
WARNING(OBJ.MCH.KIN7) : C:/D…s/h…s/A…a/A…y/A…x/A…3/Body/A…n/Arm/Muscle.any : Triceps_LH_1.SPLine : Penetration of surface : oleacranon : Via-point ‘Main.Studies.HumanModel.BodyModel.Right.ShoulderArm.Seg.Ulna.I_Triceps_LH_1’ on ‘Main.Studies.HumanModel.BodyModel.Right.ShoulderArm.Mus.Triceps_LH_1.SPLine’ is located below the wrapping surface 'Main.Studies.HumanModel.BodyModel.Right.ShoulderArm.Seg.Ulna.oleacranon.oleacranon
WARNING(OBJ.MCH.KIN7) : C:/D…s/h…s/A…a/A…y/A…x/A…3/Body/A…n/Arm/Muscle.any : Triceps_LH_2.SPLine : Penetration of surface : oleacranon : Via-point ‘Main.Studies.HumanModel.BodyModel.Right.ShoulderArm.Seg.Ulna.I_Triceps_LH_2’ on ‘Main.Studies.HumanModel.BodyModel.Right.ShoulderArm.Mus.Triceps_LH_2.SPLine’ is located below the wrapping surface 'Main.Studies.HumanModel.BodyModel.Right.ShoulderArm.Seg.Ulna.oleacranon.oleacranon
WARNING(OBJ.MCH.KIN7) : C:/D…s/h…s/A…a/A…y/A…x/A…3/Body/A…n/Arm/Muscle.any : Triceps_ME_1.SPLine : Penetration of surface : oleacranon : Via-point ‘Main.Studies.HumanModel.BodyModel.Right.ShoulderArm.Seg.Ulna.I_Triceps_ME_1’ on ‘Main.Studies.HumanModel.BodyModel.Right.ShoulderArm.Mus.Triceps_ME_1.SPLine’ is located below the wrapping surface 'Main.Studies.HumanModel.BodyModel.Right.ShoulderArm.Seg.Ulna.oleacranon.oleacranon
WARNING(OBJ.MCH.KIN7) : C:/D…s/h…s/A…a/A…y/A…x/A…3/Body/A…n/Arm/Muscle.any : Triceps_ME_2.SPLine : Penetration of surface : oleacranon : Via-point ‘Main.Studies.HumanModel.BodyModel.Right.ShoulderArm.Seg.Ulna.I_Triceps_ME_2’ on ‘Main.Studies.HumanModel.BodyModel.Right.ShoulderArm.Mus.Triceps_ME_2.SPLine’ is located below the wrapping surface 'Main.Studies.HumanModel.BodyModel.Right.ShoulderArm.Seg.Ulna.oleacranon.oleacranon
WARNING(OBJ.MCH.KIN7) : C:/D…s/h…s/A…a/A…y/A…x/A…3/Body/A…n/Arm/Muscle.any : Triceps_LA_1.SPLine : Penetration of surface : oleacranon : Via-point ‘Main.Studies.HumanModel.BodyModel.Right.ShoulderArm.Seg.Ulna.I_Triceps_LA_1’ on ‘Main.Studies.HumanModel.BodyModel.Right.ShoulderArm.Mus.Triceps_LA_1.SPLine’ is located below the wrapping surface 'Main.Studies.HumanModel.BodyModel.Right.ShoulderArm.Seg.Ulna.oleacranon.oleacranon
WARNING(OBJ.MCH.KIN7) : C:/D…s/h…s/A…a/A…y/A…x/A…3/Body/A…n/Arm/Muscle.any : Triceps_LA_2.SPLine : Penetration of surface : oleacranon : Via-point ‘Main.Studies.HumanModel.BodyModel.Right.ShoulderArm.Seg.Ulna.I_Triceps_LA_2’ on ‘Main.Studies.HumanModel.BodyModel.Right.ShoulderArm.Mus.Triceps_LA_2.SPLine’ is located below the wrapping surface 'Main.Studies.HumanModel.BodyModel.Right.ShoulderArm.Seg.Ulna.oleacranon.oleacranon
3.1) …Load time positions have been re-established.
WARNING(OBJ.MCH.KIN1) : C:/D…s/h…s/A…a/A…y/A…x/A…3/A…n/E…s/C…y/GaitFullBody.main.any : InverseDynamicStudy : Model is kinematically indeterminate : Position analysis failed : 281 independent constraints and 287 unknowns
- attemps to continue (attempt no. 1)
WARNING(OBJ.MCH.KIN1) : C:/D…s/h…s/A…a/A…y/A…x/A…3/A…n/E…s/C…y/GaitFullBody.main.any : InverseDynamicStudy : Model is kinematically indeterminate : Position analysis failed : 281 independent constraints and 287 unknowns
- attemps to continue (attempt no. 2)
WARNING(OBJ.MCH.KIN1) : C:/D…s/h…s/A…a/A…y/A…x/A…3/A…n/E…s/C…y/GaitFullBody.main.any : InverseDynamicStudy : Model is kinematically indeterminate : Position analysis failed : 281 independent constraints and 287 unknowns
- attemps to continue (attempt no. 3)
WARNING(OBJ.MCH.KIN1) : C:/D…s/h…s/A…a/A…y/A…x/A…3/A…n/E…s/C…y/GaitFullBody.main.any : InverseDynamicStudy : Model is kinematically indeterminate : Position analysis failed : 281 independent constraints and 287 unknowns
- attemps to continue (attempt no. 4)
WARNING(OBJ.MCH.KIN1) : C:/D…s/h…s/A…a/A…y/A…x/A…3/A…n/E…s/C…y/GaitFullBody.main.any : InverseDynamicStudy : Model is kinematically indeterminate : Position analysis failed : 281 independent constraints and 287 unknowns
- attemps to continue (attempt no. 5)
ERROR(OBJ.MCH.KIN1) : C:/D…s/h…s/A…a/A…y/A…x/A…3/A…n/E…s/C…y/GaitFullBody.main.any : InverseDynamicStudy : Model is kinematically indeterminate : Position analysis failed

Macro command > operation Main.Studies.HumanModel.Calibration.CalibrationSequence

Error : Main.Studies.HumanModel.Calibration.CalibrationSequence : object is not AnyOperation.

My guess is that I’m missing a Driver for 6 DoF, but I don’t know what I would be missing.

Best regards,

Hans

Hi Hans,

The r0 and Axes0 menbers of the Cane segment are only used at load time for the initial position. After that the kinematic constraint are solve and it is the joint between the hand and cane that drive the cane position (not anymore r0 and Axes0). In the code I sent the cane orientation is probably wrong because i refered in the directly to the cane reference frame, that was to have enough kinematic constraint and i did not care about the orientation. What you have to do know it to create a node in the cane with the right local position and orientation (use sRel and ARel members of the AnyRefNode) and use it in the standard joint so that the cane have the right position.

And the avoid the path issue for the cane Axes0, you can use is fixed value. It is not strictly necessary to be related to the hand Axes0. It just have to be close enough at load time so that the kinematic constraint of the joint can be solved.

The inertia unit is in Kg.m^2, that right. But it seems to me that 73,3 kg*m^2 is a quite high value if the cane weights only 0.2Kg as you set in the script. Maybe you should check those values.

For the inverse dynamic study you indeed miss 6 DoF to drive. Most likely it is the cane segment. All the joint of the body have drivers automatically created in JointsAndDriversOptimized.any using the text files. So that leaves the cane to be driven, and you have to use the same joint as in the parameter optimization study. You can place it at the end of the JointsAndDriversOptimized file for example.

Best regards, Sylvain.

Hello Sylvain,

Indeed, the Inertia properties were too high. It seems I forgot some ( ) within my Inertia formula. It is fixed now to 0.034 kg*m^2 at the Center of Mass.

The Optimization works fine now, but I still get errors from the Inverse Dynamics.

I’ve attached the errors in a Text file and my current model as a Zip.

I hope it makes senses to you.

Greetings,

Hans

Hi Hans,

In your case the kinematic is failling from the begining. That usualy means that the initial position is not adequate, and when it is already close to the real position (like in your case) some small changes can be enough to remove an unstability in the equations.

So I modified the following initial positions in the TrialSpecificData file and it works fine now:

AnyVar GlenohumeralFlexion = 25;
AnyVar GlenohumeralAbduction = 20;
AnyVar GlenohumeralExternalRotation = -15;

AnyVar ElbowFlexion = 40;

Best regards, Sylvain.

Hello Sylvain,

Thank you for your reply.

I still don’t seem to get the Inverse Dynamics working. I’ve modified the TrailSpecificData.any as you stated, but I still get the same type of errors.

The study works at your computer right? I haven’t modified anything else. Could you send me the model you have working?

Thanks,

Best regards,

Hans Essers

Hi,

Here is the version that works on my machine. Unless you have done modifications on the Body folder it should work as well on yours. Note that i haven’t run the entire analysis, only the first few steps to make sure it can solve the kinematic.

Best regards, Sylvain.

Hello Sylvain,

I’ve saved and opened the map you send me.

When I run the Inverse Dynamics study, I get the same errors as in my own model.

Greetings,

Hans

Hi Hans,

Probably you have made some modifications elsewhere in the repository. I just checked again that the model runs in the AMMR1.3.1 with your AMS version : 5. 0. 0. 2014 Build : 14963.38760.

So try to download again a clean version of the repository and run the application in it.

Best regards, Sylvain.

Hello Sylvain,

Thank you for your reply.

I’ve re-downloaded AnyBody and re-installed it.

I’m currently running the Inverse Dynamics, which means the problem is solved.

Now I’ll go ahead with my analysis to make sure there are no more errors. Afterwards I’ll upload the model as stated by the Forum Rules.

Thank you for your time and help.

Greetings,

Hans

Hello Sylvain,

Currently, I can run the Inverse Dynamica Analysis for multiple experiments.
However, when the Analysis is complete and I’m examining the data, AnyBody occasionally freezes, which forces me to shut it down and do everything all over again.

Is there a way to save all the output files at once? That case, if it would freeze again, I don’t need to do an hour’s work of Analysis again.

Greetings,

Hans

Hi Hans,

Sure this is possible,

Try the following:

[ol]
[li]Go the ModelTree and find output folder of your study
[/li][li]Right click and select “save data”
[/li][li]select if the output should stored in a flat or deep structure (it does matter much for this purpose)
[/li][li]select a file name
[/li][/ol]

now all the data present in the output you selected has been stored. To read it in again do the following:

[ol]
[li]Load the model
[/li][li]Preform scaling calibrations as you did on the model from which the data was saved from.
[/li][li]Select the same output folder in the modeltree
[/li][li]right click and select “load data”
[/li][li]Now all the data has been loaded and you can access it in the charts as before the model can be replayed
[/li][/ol]

Best regards
Søren