Hello !
I’m currently working on a shoulder model, based on the Bergmann model in the repository. In fact I’m integrating a total shoulder arthroplasty into the model.
I’d like to know the relative rotation between two nodes of the 2 prosthetic components of a TSA : Scapula.GlenPos (fixed to the scapula) and Humerus.HumerusBoneGeometryNode.HumProthNode (fixed to the humerus). My objective is to position the two components in ProEngineer(PTC), using their position obtained in Anybody at several abduction angles. For that, I need to express the rotation of each axis of the humeral coordinate system (CS) relative to the position of the glenoid CS. In clear :
rotation of the xhumeral CS relative to the xglenoid CS in degrees
rotation of the yhumeral CS relative to the yglenoid CS in degrees
rotation of the zhumeral CS relative to the zglenoid CS in degrees
I used 2 different methods, as described in the wiki page :

AnyKinLinear and AnyKinRotational with Type = RotAxesAngle ; Axis 1= x ; Axis 2= y ; Axis 3= z ;
I understood that the rotations are described by the Pos variable. What I guessed was that we should obtain a rotation matrix ; i.e. maybe a 33 matrix, what is not the case since Pos is a 31 vector.
I also understood that successive rotations follow a mobile sequence (rather than a fixed sequence). So using a (xyz)mobile sequence in anybody, it should correspond to a (zyx)fixed sequence to use in ProEngineer.
But, visual CS positions do not correspond between Anybody and ProEngineer.
So, am I wrong somewhere ? Did I a mistake in my sequence understanding ?

For the second method I decided to use the global position of my 2 components CS to calculate their relative position : AnyMatrix ScapHum = .Seg.Scapula.GlenPos.Axes’.Seg.Humerus.HumerusBoneGeometryNode.HumProthNode.Axes’;
I obtain a 33 matrix what make sense for me.
I then tried to get angles using a (zyx)fixed sequence using matlab. I’m pretty sure my problem does not come from my matlab function since it has been validated with other data.
As for the first method, visual CS positions do not correspond between Anybody and ProEngineer.
I really don’t know where is (are) my mistake(s) and your help will be greatfully appreciated !
Thanks,
Lauranne
Hey Lauranne,
have you looked at this example in the Wiki?
http://wiki.anyscript.org/index.php/All_about_Kinematics#How_to_understand_the_AnyKinRotational_Cardan_angles_.28Type.3DRotAxesAngles.29
You also write: Type = RotAxesAngle ; Axis 1= x ; Axis 2= y ; Axis 3= z ;
When you look into the ref manual:
Axis1 Const First axis of rotation for RotAxesAngles. z
Axis2 Const Second axis of rotation for RotAxesAngles. y
Axis3 Const Third axis of rotation for RotAxesAngles. x
so it is z, y, x
Sorry,
clicked the button too early.
the Z, Y , X is by default. What I wanted to say is did you change that to X, Y, Z?
Hey Amir !
Thanks for your quick reply.
I looked on your example in the wiki and finally was able to found the relative rotations between my two components. Nevertheless, I wanted to ensure my well understanding of the system. What I wanted to check was that I still was able to get the “right” angle if I changed the sequence.
So, to answer your question, yes, I explicitly specified the rotation sequence. My method was as following:

Default : Axis 1=z ; Axis 2= y ; Axis 3= x ;
Corresponds to a xyz fixed sequence (i.e. all rotations described relative to the fixed frame)

Modified : Axis 1=x ; Axis 2= y ; Axis 3= z ;
Corresponds to a zyx fixed sequence.
So, comparing first and third components of my 2 sequences should give the same result, isn’t it ? It’s unfortunately not my case. So either I don’t understand well something, or, some references in my model are wrong. Would you have any explanation ?
Moreover, regarding my second method described in my previous post, I’m note sure of the possibility to get solution for my objective : I only have axes of glenoid component relative to scapula (.Scapula.GlenePos) and Humerus component relative to another node fixed on humerus (Humerus.HumerusBoneGeometryNode.HumProthNode). So I don’t know really the position of these component relative to a globalrefframe, rigth ? Or, if I turn my question differently : how to create nodes (or a frames) at the same position than the components but relative to a globalrefframe (to obtain “axes” parameter relative to the globalrefframe)
Thank a lot for your answers !
Lauranne
Dear Lauranne,
unfortunately it is very tough understanding those rotations. I think everybody is struggling there.
I don’t think you can compare rotations a fixed and a rotating ref frame at all.
Regarding method 2. do you have a ’ at the second Axes as well? I think that is wrong.
I think I need to do little more thinking about that.
PS: A little advice, you can export STLs in global at a specific posture, so you can import them into ProE and see their position there as well.
Amir,
In fact, yes, there are correspondances between fixed and mobile rotation sequences. Reason can be found by mathematical demonstration : to obtain the final CS by a mobile sequence of 2 rotations, in fact you express it as 2 succesives fixed rotations with change of coordinate. For example for the second rotation with change of coordinate :
V’’(Ri) = [P(Ri R’)] [2nd Rotation (R’)]. [P(R’ Ri )]. V’(Ri)
(I’m not sure I’m clear enough ; let me know if you would like more explanation about that!)
Regarding method 2, I’m thinking it’s not so easy : of what I understood, a node and its axes refer to its parents and no to the global system. Am I right ? So to correctly use this method I would need to describe all the chain by successive matrix transformations. Right ?
Thank you for your advice about the idea to export STL in a global posture. In fact I did think to such a solution but I found at least 2 major drawbacks for my application :
 STL is only a surface object ; So, I lost lots information regarding the volume and will need to reconstruct the part in ProE while I already have the solid part as a CAD file.
 I would prefer using transform matrix because I want to automate the procedure for several positions
Thank you for your help and advices about that topic !
Lauranne
Lauranne,
method 2: Axes is global (ARel is not), so using Axes is correct.
(about the STL export, I understand that it will not give all the info, but I do that often to check if it is correct.)