# Axis rotation formulas, finding them with systems

• Aug 29th 2012, 04:38 PM
Greymalkin
Axis rotation formulas, finding them with systems
$\displaystyle \text{Use}\:\begin{Bmatrix}x'\:=\:xcos\theta+ysin \theta & [1] \\ y' \:=\:ycos\theta-xsin\theta & [2] \end{Bmatrix}$
$\displaystyle \text{To make}\:\begin{Bmatrix}x\:=\:x'cos\theta-y'sin \theta & [1] \\ y \:=\:y'cos\theta+x'sin\theta & [2] \end{Bmatrix}$

My book is asking me to find this before the chapter is over, it is quite puzzling and one of the toughest questions at the end of the lesson.
• Aug 29th 2012, 06:39 PM
Soroban
Re: Axis rotation formulas, finding them with systems
Hello, Greymalkin!

Quote:

$\displaystyle \text{Use}\:\begin{Bmatrix}x'&=&x\cos\theta+y \sin\theta \\ y' &=& y\cos\theta-x\sin\theta \end{Bmatrix}$

$\displaystyle \text{To make}\:\begin{Bmatrix}x &=& x'\cos\theta-y'\sin \theta \\ y &=& y'\cos\theta+x'\sin\theta \end{Bmatrix}$

$\displaystyle \text{Solve for }x\text{ and }y\text{ as you would }any\text{ system of equations.}$

$\displaystyle \text{We have: }\;\begin{Bmatrix}y\sin\theta + x\cos\theta &=& x' & [1] \\ y\cos\theta - x\sin\theta &=& y' & [2] \end{Bmatrix}$

$\displaystyle \begin{array}{ccccccc}\text{Multiply [1] by }\cos\theta: & y\sin\theta\cos\theta + x\cos^2\!\theta &=& x'\cos\theta & [3] \\ \text{Multiply [2] by }\sin\theta: & y\sin\theta\cos\theta - x\sin^2\!\theta &=& y'\sin\theta & [4] \end{array}$

$\displaystyle \text{Subtract [3] - [4]: }\;x\cos^2\!\theta + x\sin^2\!\theta \;=\;x'\cos\theta - y'\sin\theta$

. . . . . . . . . . . . . $\displaystyle x\underbrace{(\cos^2\!\theta + \sin^2\!\theta)}_{\text{This is 1}} \;=\;x'\cos\theta - y'\sin\theta$
. . . . . . . . . . . . . . . . . . . . . . . $\displaystyle x \;=\;x'\cos\theta - y'\sin\theta$

Get the idea?
• Aug 29th 2012, 07:04 PM
Greymalkin
Re: Axis rotation formulas, finding them with systems
Quote:

Originally Posted by Soroban
Get the idea?

Indeed, and I am very glad I asked this question, that answer is a notch past my mathematical acumen!
• Aug 29th 2012, 07:38 PM
MaxJasper
Re: Axis rotation formulas, finding them with systems
It is much easier to memorize in matrix form:
$\displaystyle \left[\begin{array}{c} x' \\ y'\end{array}\right]= \left[\begin{array}{cc} \cos (\theta ) & \sin (\theta ) \\ -\sin (\theta ) & \cos (\theta )\end{array}\right]\left[\begin{array}{c} x \\ y\end{array}\right]$
• Aug 29th 2012, 11:39 PM
Greymalkin
Re: Axis rotation formulas, finding them with systems
Quote:

Originally Posted by MaxJasper
It is much easier to memorize in matrix form:
$\displaystyle \left[\begin{array}{c} x' \\ y'\end{array}\right]= \left[\begin{array}{cc} \cos (\theta ) & \sin (\theta ) \\ -\sin (\theta ) & \cos (\theta )\end{array}\right]\left[\begin{array}{c} x \\ y\end{array}\right]$

I am curious as to why that is so. Im certain axis rotation gets a lot of love in calculus, but why, apart from the x'/y' formula would you have a use for that? Is there an easier way to form the matrices into the x/y= identity? I would imagine the problems in calculus, from my primitive understanding of differentiation/integration, would go both ways no?
• Aug 30th 2012, 05:07 AM
Deveno
Re: Axis rotation formulas, finding them with systems
i don't know if i can explain this without making it overly complicated, but i will try.

to understand what is going on, let's write (x',y') in POLAR coordinates as (rcos(ψ),rsin(ψ)), where ψ is the angle between the point (x',y') and the x'-axis.

(we don't need to know what r and ψ actually are for what we are going to do, but if you MUST know:

r = √(x'2+y'2)

ψ = arctan(y'/x'), if x' > 0

= π/2 if x' = 0 and y' > 0

= -π/2 if x' = 0 and y' < 0

= arctan(y'/x') + π, if x < 0, y ≥ 0

= arctan(y'/x') - π, if x < 0, y < 0 (and undefined for the origin) ...these rules are to make sure we get the angle ψ in the right "quadrant").

now, if we are given a point (x',y') in the "rotated plane", we might want to know what it's "normal coordinates are". since we got (x',y') after rotating through an angle θ, to recover the coordinates in the "un-rotated axes", we need to add in this angle of rotation:

(x,y) = (rcos(ψ+θ), rsin(ψ+θ)).

using the trigonometry angle-sum identities:

cos(ψ+θ) = cos(ψ)cos(θ) - sin(ψ)sin(θ)
sin(ψ+θ) = sin(ψ)cos(θ) + cos(ψ)sin(θ), we have:

(x,y' = (r(cos(ψ)cos(θ) - sin(ψ)sin(θ)), r(sin(ψ)cos(θ) + cos(ψ)sin(θ)))

= (rcos(ψ)cos(θ) - rsin(ψ)sin(θ), rsin(ψ)cos(θ) + rcos(ψ)sin(θ)).

but now x' = rcos(ψ), and y' = rsin(ψ), so we can just substitute back in:

(x,y) = (x'cos(θ) - y'sin(θ), y'cos(θ) + x'sin(θ))

if we want to run this procedure in reverse (and recover (x',y') from the xy-coordinates), we need to SUBTRACT the angle of rotation:

(and here, we write (x,y) = (rcos(φ), rsin(φ))

(x',y') = (rcos(φ-θ), rsin(φ-θ)) = (rcos(φ)cos(θ) + rsin(φ)sin(θ), rsin(φ)cos(θ) - rcos(φ)sin(θ))

= (xcos(θ) + ysin(θ), ycos(θ) +- xsin(θ)).

perhaps an example will make this clearer:

suppose we have x'y'-coordinates (rotated axes) of (1,0), and the axes have been rotated 1/8 of a turn (so θ = π/4).

then the xy-coordinates are:

x = 1*cos(π/4) - 0*sin(π/4) = √2/2 + 0 = √2/2
y = 0*cos(π/4) + 1*sin(π/4) = 0 + √2/2 = √2/2, so the xy-coordinates are (√2/2, √2/2) (which is exactly what you would expect the coordinates of a unit length at a 45 degree angle to be).

the main use of this is in conic sections, where you choose an angle of axis rotation θ to make an xy-term disappear, and thus be able to put a conic curve in "standard form" in x'y'-coordinates. this allows easy determination of the foci, and vertices (and/or asymptotes), which then can be translated "back" to xy-coordinates for sketching.
• Aug 30th 2012, 05:10 PM
Greymalkin
Re: Axis rotation formulas, finding them with systems
Quote:

Originally Posted by Deveno
i don't know if i can explain this without making it overly complicated, but i will try.

Tried and succeeded! Thank you very much.