Rotations

 

Calculator: TI-83 Plus.

 

A matrix [B] = [[cos(A), -sin(A)][sin(A), cos(A)]] represents a counterclockwise rotation by angle A, around a center of coordinates on a plane. Remember that if A is negative, the direction is actually clockwise (opposite to counterclockwise).

 

Here is a program that rotates a 2-dimensional picture counterclockwise by angle A around the origin. It uses (calls) the program DRAW, which is in the unit Pictures. You need to prepare matrices [I] and [J] beforehand. [I] holds the coordinates of the points in your drawing, and [J] tells which points are connected. The program keeps all the pictures, overlaying the next one on the previous ones. (I named it ROTATETW (for "rotate in 2 dimensions"), but you may choose your own name!)

 

Drawing Program Explanation
PROGRAM:ROTATETW  
:PrgmDRAW Draws picture in original orientation

:Prompt A

:While 1

:[[cos(A), -sin(A)][sin(A),cos(A)]]→[B]

User enters angle A in degrees
:[B]*[I]->[I]

Rotate matrix [I] counterclockwise by angle A

:PrgmDRAW Draw the new picture
:Pause

Press enter to get the next picture

:End  

 

How would you change the program if you wanted to erase the previous picture before drawing the next one?

 

 

The question is: Given a 2 by 2 matrix [B], does it represent a rotation? If so, how to find its angle A?

 

The answer to the first question.

If det([B]) ≠ 1, then [B] is not a rotation,

else if [B]*[B]T is the 2 by 2 identity matrix [[1,0][0,1]] then [B] is a rotation,

else [B] is not a rotation.

 

The answer to the second question.

If [B] is a rotation, compute, cos-1([B](1,1)), (it is always positive); then if [B](2,1) is negative then A = -cos-1([B](1,1)), else A = cos-1([B](1,1))

 

Task.

Students work in pairs using one calculator. One student prepares a matrix which either is or is not a rotation, and the other checks it (and finds A if appropriate).

(Set: MODE to Float 2.)

 

Example.

First student:

[[cos(27),-sin(27)][sin(27),cos(27)]]→[B]

[[.89    -.45]

[.45    .89 ]]

CLEAR

 

Second student:

det([B])

1.00    So far it is okay.

[B]*[B]T

[[1    0]

[0    1]]    It is a rotation.

cos-1([B](1,1))

27.00

[B](2,1)

.45    It is positive.

The angle is A = 27 degrees.


Webpage by Owen Ramsey
Lesson Index