PlanetPhysics/Direction Cosine Matrix to Euler 121 Sequence

From testwiki
Jump to navigation Jump to search

Starting with a [[../DirectionCosineMatrix/|direction cosine matrix]] (DCM), we need to determine the three Euler angles. The connection is made by comparing the DCM elements with the combined [[../Euler121Sequence/|Euler 121 sequence]]. It is important to note that the 12 combinations of Euler angles for a given sequence can be found from a given DCM. The DCM [[../Matrix/|matrix]] is

DCM=[A11A12A13A21A22A23A31A32A33]

The Euler 121 sequence is

R1(ψ)R2(θ)R1(ϕ)=[cθsθsϕsθcϕsψsθcψcϕsψcθsϕcψsϕ+sψcθcϕsθcψsψcϕcψcθsϕsψsϕ+cψcθcϕ]

If we examine the element in coloum 1 row 1, then by inspection

A11=cos(θ)

Solving for θ yields

θ=cos1(A11)

Care must now be taken when evaluating the inverse cosine. It is a multivalued [[../Bijective/|function]]. Analytically, the convention is to choose the principle value such that

0θπ

If a numerical [[../SupercomputerArchitercture/|program]] is used, a function acos() usually does this for us. The next step is to analyze the ratio A12A13. Using these values from the Euler sequence we get

A12A13=sin(θ)sin(ϕ)sin(θ)cos(ϕ)

Rearranging the minus sign and using the tangent yields

tan(ϕ)=A12A13

Solving the quadrant ambiquity caused by the inverse tangent is done by examining the signs of the numerator and denominator. Denoting y as the numerator and x as the denominator, then the quadrant is chosen by:

quadrant 1 </math> \left[ \begin{matrix} y & x \\ + & + \\ \end{matrix} \right] soifxandyarebothpositive,then<math>0ϕπ/2. Similarily for the other quadrant possibilites

quadrant 2 </math> \left[ \begin{matrix} y & x \\ + & - \\ \end{matrix} \right] quadrant3 \left[ \begin{matrix} y & x \\ - & - \\ \end{matrix} \right] quadrant4 \left[ \begin{matrix} y & x \\ - & + \\ \end{matrix} \right] Ofcourse,itismuchsimpliertouseacalculatorornumericalprogramthatusestheatan2()functionwhichwillchoosetheprinciplevalue.InasimilarfashionwecanfindthefinalEuleranglebylookingattheratio<math>A21A31 which gives the [[../Bijective/|relation]] A21A31=sin(ψ)sin(θ)sin(θ)cos(ψ)

Canceling terms and rearrangeing gives us

ψ=tan1(A21A31)

which uses the same method to resolove quadrant ambiguity as above. To summarize, we will give the [[../Formula/|formulas]] for the conversion from a direction cosine matrix to the Euler 121 angles in Matlab syntax. Be careful how you implement this in other numerical programs. In Matlab it goes atan2(y,x) and in Mathematica it is ArcTan[x, y].

ϕ=atan2(A12,A13) θ=acos(A11) ψ=atan2(A21,A31)

Template:CourseCat