P. Axelrad, D. Lawrence ASEN3200 Spring 2006 ATTITUDE REPRESENTATION l Attitude cannot be...

18
P. Axelrad, D. Lawrence ASEN3200 Spring 2006 ATTITUDE REPRESENTATION Attitude cannot be represented by vector in 3-dimensional space, like position or angular velocity, even though attitude is a “3-dimensional” quantity. Attitude is always specified as a rotation relative to a base, or reference frame, just as vector position is specified as a displacement from a reference point. However there is often confusion in the direction: Rotation of the body frame to align with the reference frame Rotation of the reference frame to align with the body frame Rotations are described by various means Direction Cosines Matrix (DCM) Euler Angles Euler Axis/Angle Quaternion Rodriquez parameters, Gibbs vector, etc.

Transcript of P. Axelrad, D. Lawrence ASEN3200 Spring 2006 ATTITUDE REPRESENTATION l Attitude cannot be...

P. Axelrad, D. Lawrence ASEN3200 Spring 2006

ATTITUDE REPRESENTATION

Attitude cannot be represented by vector in 3-dimensional space, like position or angular velocity, even though attitude is a “3-dimensional” quantity.

Attitude is always specified as a rotation relative to a base, or reference frame, just as vector position is specified as a displacement from a reference point. However there is often confusion in the direction: Rotation of the body frame to align with the reference frame Rotation of the reference frame to align with the body frame

Rotations are described by various means Direction Cosines Matrix (DCM) Euler Angles Euler Axis/Angle Quaternion Rodriquez parameters, Gibbs vector, etc.

P. Axelrad, D. Lawrence ASEN3200 Spring 2006

DIRECTION COSINES MATRIX

The DCM transforms a vector representation from one coordinate frame to another, or rotates vectors from one attitude to another.

The DCM can be formed by dot products of unit vectors of two frames

Note that if we set A=1 and B=2,

The nine elements are not independent because the DCM must be orthonormal

1

2 12

A

B B A A Ar T r or r R r

2 1 2 1 2 1

1

2 1 2 1 2 12

2 1 2 1 2 1

B A B A B A

A

B A B A B AB

B A B A B A

i i i j i k i i j i k i

T j i j j j k or R i j j j k j

k i k j k k i k j k k k

= A B B A

B A A BT T T T I

1

2

TA

BT R

P. Axelrad, D. Lawrence ASEN3200 Spring 2006

EULER ANGLES

Euler Angles are a particular sequence of three rotations about particular reference frame axes. Both the sequence and the axes must be specified to clearly define the attitude (rotation) of interest.

The same angle values used in a different sequence, or about different axes, results in a different attitude

Example: Yaw-Pitch-Roll Euler angle sequence rotating the reference frame (call it frame 1) into the body frame:

1) - Yaw the reference frame about its k-axis with angle to produce the 2-frame

2) - Pitch about the new j-axis with angle to produce the 3-frame

3) - Roll about the new i-axis with angle to produce the body frame B

The resulting rotation matrix rotating 1-frame vectors v into their corresponding body frame position is given by

1 1 3 2 1

B 11 1 3 2v = R v where R ( ) ( ) ( )

B B BR R R

EULER ANGLE EXAMPLE

i2

Reference Frame is Frame 1

yaw

i1

j1

k1,k2

j2

i3

pitch

j2,j3i2

k3k2

Body frame is Frame B

roll

j3

k3

i3,iB

kBjB

Rotate about k1 Rotate about j2

Rotate about i3

Yaw,Pitch,Roll (k,j,i) Sequence

(angle (angle

(angle

P. Axelrad, D. Lawrence ASEN3200 Spring 2006

DCMs FOR GENERAL EULER ROTATIONS

1

2

1 0 0

0

0

R c s

s c

1

2

0

0 1 0

0

c s

R

s c

1

2

0

0

0 0 1

c s

R s c

j

k

i

j

k

i

j

k

i

1

2

1

2

2

1

P. Axelrad, D. Lawrence ASEN3200 Spring 2006

Transformation Matrix for Euler Yaw,Pitch,Roll (k,j,i)

1

321 , ,B

c c c s s

R c s s s c c c s s s s c

s s c s c s c c s s c c

P. Axelrad, D. Lawrence ASEN3200 Spring 2006

EULER’S THEOREM (EULER AXIS/ANGLE REP.)

Any rigid body rotation can be expressed by a single rotation about a fixed axis.

The rotation matrix [R] is given in terms of a unit vector along the “Euler axis” e (a unit vector), and the angle,

1

11 12, cos + 1-cos e e sin [[ ] ]

TR n I e

e

Shuster, M., "Survey of Attitude Representations," Journal of Astronautical Sciences, Vol. 41, No. 4, Oct.-Dec. 1993. pp. 439-517.

112 2

23 32

31 131

12 21

cos R 1

1

2sin

tr

R R

e R R

R R

P. Axelrad, D. Lawrence ASEN3200 Spring 2006

NOTATION

Vector Dot Product

Vector Cross Product

Cross Product Matrix for vector

c= cos() s= sin()

1 1 2 2 3 3

T

B Br b r b rb r b r b

3 2 1

3 1 2

2 1 3

0

[[ ] ] 0

0B B

b b b

b b b where b b

b b b

[[ ] ]B BBr b b r

P. Axelrad, D. Lawrence ASEN3200 Spring 2006

QUATERNION REPRESENTATION OF ATTITUDE

Only one redundant element requiring use of a constraint | q | = 1

Only ambiguity is a sign Can be combined easily to produce

successive rotations DCM computation given by multiply

& add of quaternion elements (no trig functions)

Propagation requires integration of only 4 kinematic equations

Widely used because of simplicity of operations and small dimension, together with lack of representation singularity

Shuster, M., "Survey of Attitude Representations," Journal of the Astronautical Sciences, Vol. 41, No. 4, Oct.-Dec. 1993. pp. 439-517.

1

2

3

4

q

qq

q

q

P. Axelrad, D. Lawrence ASEN3200 Spring 2006

QUATERNION REPRESENTATION

1

1

2

2 4

3

3

4

2 24

sin , cos , 2 2

1 ( must be constrained to unit length)

qq

qq q e q q

qq

q

q q q

Given Euler Axis e and angle

P. Axelrad, D. Lawrence ASEN3200 Spring 2006

Quaternion versus Rotation Matrix (DCM_

2 2 2 2

1 2 3 4 1 2 4 3 1 3 4 2

2 2 2 2

1 2 4 3 1 2 3 4 2 3 4 1

2 2 2 2

3 1 4 2 3 2 4 1 1 2 3 4

4 4

1

224 4 4

2

23 324

2 2

( ) 2 2

2 2

4

R( , ) 2 2 [[ ]]

11, 1 ,

21

4

T

q q q q q q q q q q q q

R q q q q q q q q q q q q q

q q q q q q q q q q q q

trR q q

q

q q q q I q q q q

trR

R Rq

2 331 13 12 21

4 4

1 1, ,

4 4q qR R R R

q q

P. Axelrad, D. Lawrence ASEN3200 Spring 2006

Quaternion Composition (Successive Rotations)

3 2 1

3 1 2

4 3 2 1

3 4 1 2

2 1 4 3

1 2 3 4

(Note the swapped order)

A B AC C B

A B A

C C B

A A B

C B C

R R R

q q q

q q q

q q q q

q q q qq

q q q q

q q q q

P. Axelrad, D. Lawrence ASEN3200 Spring 2006

Kinematics

4 3 2

1

3 4 1

2

2 1 4

3

1 2 3

( )= ( ) [[ ]]

( ) ( ) ( )( )

( ) ( ) ( )( ) 1= ( )

2 ( ) ( ) ( )( )

( ) ( ) ( )

d R tR t t

dtq t q t q t

tq t q t q td q t

tdt q t q t q t

tq t q t q t

Relationship between angular velocity and attitude representations

P. Axelrad, D. Lawrence ASEN3200 Spring 2006

SMALL ANGLE APPROXIMATIONS

For a small angles , sin( ~ , cos( ~ 1

The rotation DCM for a sequence of three small Euler angles is:

3 2

3 1

2 1

1[[ ]] 1

1R I

P. Axelrad, D. Lawrence ASEN3200 Spring 2006

ATTITUDE DETERMINATION PROBLEM

Use standard attitude sensors such as a star tracker or sun sensor Sensor axes are calibrated with respect to body-fixed reference frame

(B) Direction to reference object (sun or star) is found in an inertial frame (I)

using star catalog, ephemeris prediction, etc. Direction to reference object is also measured by the on-board sensors

and expressed in the (B) frame. Now have one or more unit vectors to objects expressed in both (I) and

in (B). Note that a minimum of 2 “independent” objects is required to determine 3-D attitude

Calculate the attitude DCM

P. Axelrad, D. Lawrence ASEN3200 Spring 2006

ATTITUDE DETERMINATION PROBLEM

Given measurements of two unit vectors (pointing to two objects) in a body frame and a reference frame

How can the DCM representing attitude be determined? T must simultaneously satisfy

Deterministic method - TRIAD Use two of the measured vectors to define a set of three orthogonal

unit vectors in the two frames. Create a matrix equation from the three vector equations and use

this to solve for the attitude DCM

1 1 2 2

A A

B B A B B Av T v and v T v

1 1 2 2, , , A B A B

v v v v

P. Axelrad, D. Lawrence ASEN3200 Spring 2006

DETERMINISTIC ATTITUDE DETERMINATION

1 21 1 2 3 1 2

1 2

1 21 1 2 3 1 2

1 2

Construct , ,

, ,

A AA

A A

B BB

B B

v vr v r r r r

v v

v vs v s s s s

v v

1 1 2 2Given unit vectors , , , A B A B

v v v v

1 2 3 1 2 3 R s

A Ts RB

M r r r M s s s

T M M

Transformation DCM estimate (note rotation DCM is the transpose of this)

ABR

P. Axelrad, D. Lawrence ASEN3200 Spring 2006

Attitude Representations and Attitude Determination

REFERENCES Shuster, M., "Survey of Attitude Representations," Journal of the

Astronautical Sciences, Vol. 41, No. 4, Oct.-Dec. 1993. pp. 439-517. Shuster, M. D. and Oh, S. D., "Three-Axis Attitude Determination from

Vector Observations," Journal of Guidance and Control, Vol. 4, No. 1, Jan.-Feb. 1981, pp. 70-77.

Wertz, J. R., ed. Spacecraft Attitude Determination and Control, Kluwer Academic Publishers, Dordrecht, Netherlands, 1978.