Importing a body into the model, part II

Okay, I think I’m almost there with the model. I can get the model to
compile, SetInitialConditions, and run the KinematicAnalysis, however
I know that my kinematic tolerance is high. I need to have the
shoulder be positioned at the origin of the global reference frame.
Right now, I am driving the placement of the body by:

AnyKinEqSimpleDriver SeatHeight = {
AnyKinLinear &PelvisPos = .PelvisPos;
DriverPos = {0,1,0};
DriverVel = {0,0,0};
Reaction.Type = {0,0,0};
};

This is approaching the correct initial position for me, however I
want to set the initial positions by the placement of the Right
Shoulder marker in space (not the height of the seat). Besides, when
I try to alter the DriverPos to shift the body in space so that the
shoulder marker aligns more closely with the globalref origin,
{-0.2580307, 1.497251, 0.2118869};, the torso tilts in space - only a
DriverPos of {0.1.0} seems to keep the body upright. Why is this the
case?

I have also tried the following (created a spherical joint between the
following):

AnyRefNode &Ground = Main.MyValidation.EnvironmentModel.GlobalRef.RSHO;
AnyRefNode &Humerus =
Main.MyValidation.HumanModel.Right.ShoulderArm.Seg.Humerus.gh;

and then taking out the AnyKinEqSimpleDriver SeatHeight, but I end up
with the body then parallel to the ground, not perpendicular as it
should be.

I have also tried positioning the shoulder with respect to the ground
(instead of the pelvis with respect to the ground) as follows:

AnyKinLinear ShoulderPos = {
AnyFixedRefFrame &Ground = Main.MyValidation.EnvironmentModel.GlobalRef;
AnyRefNode &gh =
Main.MyValidation.HumanModel.Right.ShoulderArm.Seg.Humerus.gh;
};

AnyKinRotational ShoulderRot = {
AnyFixedRefFrame &Ground = Main.MyValidation.EnvironmentModel.GlobalRef;
AnySeg &Humerus =
Main.MyValidation.HumanModel.Right.ShoulderArm.Seg.Humerus;
Type = RotAxisAngles;
};

AnyReacForce ShoulderReac = {
AnyKinRotational &ref = .ShoulderRot;
};

AnyKinEqSimpleDriver ShoulderHeight = {
AnyKinLinear &ShoulderPos = .ShoulderPos;
DriverPos = {-0.2580307, 1.497251, 0.2118869};
DriverVel = {0,0,0};
Reaction.Type = {1,1,1};
};

Again, the body becomes horizontal to the ground, ShoulderRot becomes
“Close to singular position: Orientation close to Gimbal Lock,” adn
the kinematic error is above the error tolerance.

Sorry for the long email, but I think I am really close. I’m
attaching the file (Validation II - driven by Vicon) to take a look at

  • it should be easier now that it compiles and such.

Any suggestions at this point?

Thank you so much in advance,
Sarah

Hi Sarah

Thank you for your long mail… I made a mistake yesterday.
Reaction.type is only controlig the reaction forces, but the
kinematic. Sorry about that. It sounds like you are getting close to
the goal. You say you attach the file, but you have to upload it to
the file space… we dont get the attachments. I will look at it when
you upload it.

Best regards
Christian, AnyBody Support

— In anyscript@yahoogroups.com, “Sarah R. Sullivan” <sarsulli@…>
wrote:
>
> Okay, I think I’m almost there with the model. I can get the model to
> compile, SetInitialConditions, and run the KinematicAnalysis, however
> I know that my kinematic tolerance is high. I need to have the
> shoulder be positioned at the origin of the global reference frame.
> Right now, I am driving the placement of the body by:
>
> AnyKinEqSimpleDriver SeatHeight = {
> AnyKinLinear &PelvisPos = .PelvisPos;
> DriverPos = {0,1,0};
> DriverVel = {0,0,0};
> Reaction.Type = {0,0,0};
> };
>
> This is approaching the correct initial position for me, however I
> want to set the initial positions by the placement of the Right
> Shoulder marker in space (not the height of the seat). Besides, when
> I try to alter the DriverPos to shift the body in space so that the
> shoulder marker aligns more closely with the globalref origin,
> {-0.2580307, 1.497251, 0.2118869};, the torso tilts in space - only a
> DriverPos of {0.1.0} seems to keep the body upright. Why is this the
> case?
>
> I have also tried the following (created a spherical joint between the
> following):
>
> AnyRefNode &Ground = Main.MyValidation.EnvironmentModel.GlobalRef.RSHO;
> AnyRefNode &Humerus =
> Main.MyValidation.HumanModel.Right.ShoulderArm.Seg.Humerus.gh;
>
> and then taking out the AnyKinEqSimpleDriver SeatHeight, but I end up
> with the body then parallel to the ground, not perpendicular as it
> should be.
>
> I have also tried positioning the shoulder with respect to the ground
> (instead of the pelvis with respect to the ground) as follows:
>
> AnyKinLinear ShoulderPos = {
> AnyFixedRefFrame &Ground =
Main.MyValidation.EnvironmentModel.GlobalRef;
> AnyRefNode &gh =
> Main.MyValidation.HumanModel.Right.ShoulderArm.Seg.Humerus.gh;
> };
>
> AnyKinRotational ShoulderRot = {
> AnyFixedRefFrame &Ground =
Main.MyValidation.EnvironmentModel.GlobalRef;
> AnySeg &Humerus =
> Main.MyValidation.HumanModel.Right.ShoulderArm.Seg.Humerus;
> Type = RotAxisAngles;
> };
>
> AnyReacForce ShoulderReac = {
> AnyKinRotational &ref = .ShoulderRot;
> };
>
> AnyKinEqSimpleDriver ShoulderHeight = {
> AnyKinLinear &ShoulderPos = .ShoulderPos;
> DriverPos = {-0.2580307, 1.497251, 0.2118869};
> DriverVel = {0,0,0};
> Reaction.Type = {1,1,1};
> };
>
> Again, the body becomes horizontal to the ground, ShoulderRot becomes
> “Close to singular position: Orientation close to Gimbal Lock,” adn
> the kinematic error is above the error tolerance.
>
> Sorry for the long email, but I think I am really close. I’m
> attaching the file (Validation II - driven by Vicon) to take a look at
> - it should be easier now that it compiles and such.
>
> Any suggestions at this point?
>
> Thank you so much in advance,
> Sarah
>

I thought I uploaded it? I will try again tonight - and let you know the
name once again.

Thanks,
Sarah

> Hi Sarah
>
> Thank you for your long mail… I made a mistake yesterday.
> Reaction.type is only controlig the reaction forces, but the
> kinematic. Sorry about that. It sounds like you are getting close to
> the goal. You say you attach the file, but you have to upload it to
> the file space… we dont get the attachments. I will look at it when
> you upload it.
>
> Best regards
> Christian, AnyBody Support
>
>
> — In anyscript@yahoogroups.com, “Sarah R. Sullivan” <sarsulli@…>
> wrote:
>>
>> Okay, I think I’m almost there with the model. I can get the model to
>> compile, SetInitialConditions, and run the KinematicAnalysis, however
>> I know that my kinematic tolerance is high. I need to have the
>> shoulder be positioned at the origin of the global reference frame.
>> Right now, I am driving the placement of the body by:
>>
>> AnyKinEqSimpleDriver SeatHeight = {
>> AnyKinLinear &PelvisPos = .PelvisPos;
>> DriverPos = {0,1,0};
>> DriverVel = {0,0,0};
>> Reaction.Type = {0,0,0};
>> };
>>
>> This is approaching the correct initial position for me, however I
>> want to set the initial positions by the placement of the Right
>> Shoulder marker in space (not the height of the seat). Besides, when
>> I try to alter the DriverPos to shift the body in space so that the
>> shoulder marker aligns more closely with the globalref origin,
>> {-0.2580307, 1.497251, 0.2118869};, the torso tilts in space - only a
>> DriverPos of {0.1.0} seems to keep the body upright. Why is this the
>> case?
>>
>> I have also tried the following (created a spherical joint between the
>> following):
>>
>> AnyRefNode &Ground = Main.MyValidation.EnvironmentModel.GlobalRef.RSHO;
>> AnyRefNode &Humerus =
>> Main.MyValidation.HumanModel.Right.ShoulderArm.Seg.Humerus.gh;
>>
>> and then taking out the AnyKinEqSimpleDriver SeatHeight, but I end up
>> with the body then parallel to the ground, not perpendicular as it
>> should be.
>>
>> I have also tried positioning the shoulder with respect to the ground
>> (instead of the pelvis with respect to the ground) as follows:
>>
>> AnyKinLinear ShoulderPos = {
>> AnyFixedRefFrame &Ground =
> Main.MyValidation.EnvironmentModel.GlobalRef;
>> AnyRefNode &gh =
>> Main.MyValidation.HumanModel.Right.ShoulderArm.Seg.Humerus.gh;
>> };
>>
>> AnyKinRotational ShoulderRot = {
>> AnyFixedRefFrame &Ground =
> Main.MyValidation.EnvironmentModel.GlobalRef;
>> AnySeg &Humerus =
>> Main.MyValidation.HumanModel.Right.ShoulderArm.Seg.Humerus;
>> Type = RotAxisAngles;
>> };
>>
>> AnyReacForce ShoulderReac = {
>> AnyKinRotational &ref = .ShoulderRot;
>> };
>>
>> AnyKinEqSimpleDriver ShoulderHeight = {
>> AnyKinLinear &ShoulderPos = .ShoulderPos;
>> DriverPos = {-0.2580307, 1.497251, 0.2118869};
>> DriverVel = {0,0,0};
>> Reaction.Type = {1,1,1};
>> };
>>
>> Again, the body becomes horizontal to the ground, ShoulderRot becomes
>> “Close to singular position: Orientation close to Gimbal Lock,” adn
>> the kinematic error is above the error tolerance.
>>
>> Sorry for the long email, but I think I am really close. I’m
>> attaching the file (Validation II - driven by Vicon) to take a look at
>> - it should be easier now that it compiles and such.
>>
>> Any suggestions at this point?
>>
>> Thank you so much in advance,
>> Sarah
>>
>
>
>
>


Sarah R. Sullivan
PhD Candidate, Biomedical Engineering
Rutgers, The State University of New Jersey
Piscataway, NJ 08854
sarsulli@eden.rutgers.edu
908-420-3371