Matrix operators

18
1 Matrix operators Rotation x x' y' z y A x' x y' y cos cos sin - sin A x --> x' A y --> y'

description

Matrix operators. Rotation. z. y. y'. A a. cos a. cos a. x'. a. y'. sin a. a. a. y. x. - sin a. x. a. x'. A a x --> x' A a y --> y'. Matrix operators. Rotation. z. y. y'. A a. cos a. cos a. x'. a. y'. sin a. a. a. y. x. - sin a. x. a. x'. - PowerPoint PPT Presentation

Transcript of Matrix operators

Page 1: Matrix operators

1

Matrix operators

Rotation

xx'

y'

z

y

A

x'

x

y'y

cos cos

sin

- sin

Ax --> x' Ay --> y'

Page 2: Matrix operators

2

Matrix operators

Rotation

xx'

y'

z

y

A

x'

x

y'y

cos cos

sin

- sin

Ax --> x' Ay --> y'

x' = x cos + y sin y' = - x sin + y cos z' = z

Page 3: Matrix operators

3

Matrix operators

Rotation

xx'

y'

z

y

A

x'

x

y'y

cos cos

sin

- sin

x' = x cos + y sin x' cos sin 0 xy' = - x sin + y cos y' = – sin cos 0 yz' = z z' 0 0 1 z

X' = A X

Page 4: Matrix operators

4

Matrix operators

Rotation of a point

x y z

x

x’ y’ z’

y

Rotation of point same asx' cos – sin 0 xleaving point fixed &y' = sin cos 0 yrotating coord. system z' 0 0 1 zthrough angle –

X' = A X = A X T -1

Page 5: Matrix operators

5

Matrix operators

General transformation matrix

x y z

x2

x’ y’ z’

x3

r = (r i)i + (r j)j+ (r k)k

r = (r i')i' + (r j')j'+ (r k')k'

If r = i', j', k', in turn:

i' = (i' i)i + (i' j)j+ (i' k)k

j'= (j' i)i + (j' j)j+ (j' k)k

k'= (k' i)i + (k' j)j+ (k' k)k

x1x1’

x3’

x2’

r

Page 6: Matrix operators

6

Matrix operators

General transformation matrix

x y z

x2

x’ y’ z’

x3If r = i', j', k', in turn:

i' = (i' i)i + (i' j)j+ (i' k)k

j'= (j' i)i + (j' j)j+ (j' k)k

k'= (k' i)i + (k' j)j+ (k' k)k

(i' i), (i' j), ….. are directioncosines lmn = cos mn, and:

i' l11 l12l13 i

j' = l21 l22l23 j

k' l31 l32l33 k

x1x1’

x3’

x2’

r

Page 7: Matrix operators

7

Matrix operators

General transformation matrix

(i' i), (i' j), ….. are directioncosines lmn = cos mn, and:

i' l11 l12l13 i

j' = l21 l22l23 j

k' l31 l32l33 k

x l11 l12l13 x' x' l11 l21l31 x

y = l21 l22l23 y' y' = l12 l22l32 y

z l31 l32l33 z' z' l13 l23l33 z

Page 8: Matrix operators

8

Matrix operators

General transformation matrix

Transformation matrix is then product of 3 matrices:

P = A-1R A where X' = P X

1. X3 ––> r = A

2. rotate about r= R

3. r ––> X3' = A-1

x y z

x2

x’ y’ z’

x3

x1x1’

x3’

x2’

r

Page 9: Matrix operators

9

Matrix operators

General transformation matrix

Transformation matrix is then product of 3 matrices:

P = A-1R A where X' = P X

P = l11 l21 l31 cos sin 0 l11 l12 l13

l12 l22 l32 -sin cos 0 l21 l22 l23

l13 l23 l33 0 0 1 l31 l32 l33

Page 10: Matrix operators

10

Matrix operators

General transformation matrix

Transformation matrix is then product of 3 matrices:

P = A-1R A where X' = P X

P = l11 l21 l31 cos sin 0 l11 l12 l13

l12 l22 l32 -sin cos 0 l21 l22 l23

l13 l23 l33 0 0 1 l31 l32 l33

Multiplying matrices, finally get

P = l31(1 - cos ) + cos l32l31 (1 - cos ) + l33 sin l31l33 (1 - cos ) - l32 sin

l32l31 (1 - cos ) - l33 sin l32(1 - cos ) + cos l32l33 (1 - cos ) + l31 sin

l33l31 (1 - cos ) + l32 sin l32l33 (1 - cos ) - l31 sin l33(1 - cos ) + cos

2

2

2

Page 11: Matrix operators

11

Matrix operators

General transformation matrix

Transformation matrix is then product of 3 matrices:

P = A-1R A where X' = P X

P = l31(1 - cos ) + cos l32l31 (1 - cos ) + l33 sin l31l33 (1 - cos ) - l32 sin

l32l31 (1 - cos ) - l33 sin l32(1 - cos ) + cos l32l33 (1 - cos ) + l31 sin

l33l31 (1 - cos ) + l32 sin l32l33 (1 - cos ) - l31 sin l33(1 - cos ) + cos

This matrix for rotation of basis vectors. More interesting to rotate points (xyz).

Use inverse (transpose) matrix:

P-1 = l31(1 - cos ) + cos l32l31 (1 - cos ) - l33 sin l33l31 (1 - cos ) + l32 sin

l32l31 (1 - cos ) + l33 sin l32(1 - cos ) + cos l32l33 (1 - cos ) - l31

sin

l31l33 (1 - cos ) - l32 sin l 32l33 (1 - cos ) + l31 sin l33(1 - cos ) + cos

2

2

2

2

2

2

Page 12: Matrix operators

12

Matrix operators

General transformation matrix

Transformation matrix is then product of 3 matrices:

P = A-1R A where X' = P X

P-1 = l31(1 - cos ) + cos l32l31 (1 - cos ) - l33 sin l33l31 (1 - cos ) + l32 sin

l32l31 (1 - cos ) + l33 sin l32(1 - cos ) + cos l32l33 (1 - cos ) - l31

sin

l31l33 (1 - cos ) - l32 sin l 32l33 (1 - cos ) + l31 sin l33(1 - cos ) + cos

Ex: r along z l31 = l32 = 0 l33 = 1

P-1 = cos – sin 0

sin cos 0

0 0 1

2

2

2

Page 13: Matrix operators

13

Matrix operators

General transformation matrix

Transformation matrix is then product of 3 matrices:

P = A-1R A where X' = P X

P-1 = l31(1 - cos ) + cos l32l31 (1 - cos ) - l33 sin l33l31 (1 - cos ) + l32 sin

l32l31 (1 - cos ) + l33 sin l32(1 - cos ) + cos l32l33 (1 - cos ) - l31

sin

l31l33 (1 - cos ) - l32 sin l 32l33 (1 - cos ) + l31 sin l33(1 - cos ) + cos

Ex: C4 along [100] l33 = l32 = 0 l31 = 1 = π/2 cos = 0 sin = 1

P-1 = 1(1-0)+0 0(1-0)-0(1) 0(1-0)+0(1) = 1 0 0

0(1-0)+0(1) 0(1-0)+0 0(1-0)-1(1) 0 0 -1

0(1-0)+0(1) 0(1-0)+1(1) 0(1-0)+0 0 1 0

(x', y', z') = (x, -z, y)

2

2

2

Page 14: Matrix operators

14

Matrix operators

General transformation matrix

Transformation matrix is then product of 3 matrices:

P = A-1R A where X' = P X

P-1 = l31(1 - cos ) + cos l32l31 (1 - cos ) - l33 sin l33l31 (1 - cos ) + l32 sin

l32l31 (1 - cos ) + l33 sin l32(1 - cos ) + cos l32l33 (1 - cos ) - l31

sin

l31l33 (1 - cos ) - l32 sin l 32l33 (1 - cos ) + l31 sin l33(1 - cos ) + cos

Ex: C3 along [111] l33 = l32 = l31 = 1/ 3 = 2π/3 cos = -1/2 sin = 3/2

P-1 = 1/3(3/2)-1/2 1/3(3/2)-1/2 1/3(3/2)+1/2 = 0 0 1

1/3(3/2)+1/2 1/3(3/2)-1/2 1/3(3/2)-1/2) 1 0 0

1/3(3/2)-1/2 1/3(3/2)+1/2 1/3(3/2)-1/2 0 1 0

(x', y', z') = (z, x, y)

2

2

2

Page 15: Matrix operators

15

Matrix operators

Unit cell transformations

Transformation of unit cell transforms:

(hkl)reciprocal cell basis vectorszone axes [uvw]atom position coordinates

Page 16: Matrix operators

16

Matrix operators

Unit cell transformations

Transformation of unit cell transforms:

(hkl)reciprocal cell basis vectorszone axes [uvw]atom position coordinates

Suppose

a2 = s11a1+ s12b1 + s13c1

b2 = s21a1+ s22b1 + s23c1

c2 = s31a1+ s32b1 + s33c1

sij also transforms (hkl) to the new basis a2, b2, c2

But a2i* = ((sij)-1)T a1i* <–– [uvw] & (xyz) transform the same way

Page 17: Matrix operators

17

Matrix operators

Unit cell transformations

a2 = s11 s12 s13 a1

b2 s21 s22 s23 b1

c2 s31 s32 s33 c1

Ex: F cubic ––> P cell

aP = 1/2 1/2 0 aF

bP 0 1/2 1/2 bF

cP 1/2 0 1/2 cF

aP

bPcP

aF

cF

bF

Page 18: Matrix operators

18

Matrix operators

Unit cell transformations

a2 = s11 s12 s13 a1

b2 s21 s22 s23 b1

c2 s31 s32 s33 c1

Ex: F cubic ––> P cell

aP = 1/2 1/2 0 aF

bP 0 1/2 1/2 bF

cP 1/2 0 1/2 cF

Typical F cubic diffraction pattern:(111), (200), (220) …..

(111), (101), (211) for P cell

aP

bPcP

aF

cF

bF