Rotating a function about the origin

Click For Summary
To algebraically rotate a function about the origin for any given angle, the coordinates of a point (x, y) are transformed using the equations x' = x*cos(a) - y*sin(a) and y' = x*sin(a) + y*cos(a), where a is the angle of rotation. This process can be complex, especially for non-linear functions, as the new function must be expressed in terms of the rotated coordinates (x', y') rather than the original (x, y). The discussion highlights that while simple functions may yield a straightforward rotated form, more complex functions, like sine curves, may not have a closed expression after rotation. Users are encouraged to explore simpler functions first to understand the rotation process better. Overall, the algebra involved can become intricate, particularly when inverting equations to find the new functional form.
lolgarithms
Messages
120
Reaction score
0
stupid question from a high school kid. How do you algebraically rotate (not flip) a function about the origin for any given angle? and what is the notation for it?
 
Mathematics news on Phys.org
lolgarithms said:
stupid question from a high school kid. How do you algebraically rotate (not flip) a function about the origin for any given angle? and what is the notation for it?
Nothing stupid about that question.

There are several ways to look at it, depending on your level of mathematical knowledge. I'm guessing you haven't studied vectors or matrices, is that true? How about trig?

If know some trig, then this might make some sense:

For a given point (x,y) on your original function, you can identify the rotated point (x',y') as follows:

x' = x*cos(a) - y*sin(a)
y' = x*sin(a) + y*cos(a)

where a is the angle of rotation.

Does that help?
 
An idea could be to transform the function to polar form, rotate with an angle of choice and then transform back to cartesian form.
 
This is really the same as belliott448's answer: Multiply
\begin{bmatrix}cos(\theta) & -sin(\theta) \\ sin(\theta) & cos(\theta)\end{bmatrix}\begin{bmatrix}x \\ y \end{bmatrix}

to rotate the point (x,y) about the origin an angle \theta.
 
so you mean for y=f(x) you can get the new function by plugging f(x) for y into the matrices and multiplying them?
I get first row: x cos(theta) - f(x) sin(theta)
second row: f(x) cos(theta) + x sin(theta)

Is the new function f(x) cos(theta) + x sin(theta)?
 
Last edited:
lolgarithms said:
so you mean for y=f(x) you can get the new function by plugging f(x) for y into the matrices and multiplying them?
I get first row: x cos(theta) - f(x) sin(theta)
second row: f(x) cos(theta) + x sin(theta)

Is the new function f(x) cos(theta) + x sin(theta)?
Sort of.

If you start with a point (x,f(x)), that point will be rotated to (x',f'(x)), where the primes indicate the rotated values and are given by the equations you have. The trouble is that you now have a new function value, f', but it's expressed as a function of the original x, not of the new x', which is what you need in order to find the form of the new function.

You can fix this by inverting the equation for x' in order to solve for x in terms of x', and then plug that into your expression for f' to express it as a function of x'.

I'm pretty sure that what you'll end up with is the same as what you'd get by following Jarles' suggestion to switch to polar coordinates, do the rotation, and then transform back again. That's bound to give you the same sines and cosines.

I'm not sure if one method will be easier to perform, but it's too late for me to try it tonight! Sorry! I'll do it tomorrow if no one else has by then.
 
I tried putting e^x cos(pi/3) + x sin(pi/3) on my calculator and it didn't work. Am I doing something wrong?
 
You have to use the vector representation of your function.
 
lolgarithms said:
I tried putting e^x cos(pi/3) + x sin(pi/3) on my calculator and it didn't work. Am I doing something wrong?
Okay, so your function is y = e^x, right? If you plug in a specific value of x, say 1.5, then you get y = e^1.5 = 4.5 (approximately).

If you rotated this point (1.5,4.5) by pi/3, you'll get:

x' = 1.5 cos(pi/3) - 4.5 sin(pi/3) = -3.1
y' = 1.5 sin(pi/3) + 4.5 cos(pi/3) = 3.5

for the coordinates of the rotated point. That's fine if all you want to do is to plot the rotated function, but if you write down a new function whose curve is the rotated one, you need a few more steps.

y' is the y coordinate of the rotated point (3.5), so it's the value of the new function, but the expression above gives you y' in terms of x, the original x coordinate (1.5); what you need is an expression in terms of x', the x coordinate of the rotated point (-3.1), since that's the x value that corresponds to y'. To get that, you have substitute for x in the expression for y' (x appears both as x and also in the expression for y, namely e^x), to write it in terms of x'.

This means that you have to invert the equations for x' and y' to get equations for x and y in terms of x' and y'. Try that - you'll have to solve the two equations for x and y. (Hint: the answer should look very much like the original equations, but with some changes of sign. This makes sense, if you think about it, since writing x and y as functions of x' and y' just tells you how to rotate (x',y') back to (x,y), so it's just a rotation by the negative of the original angle.)

Do all that, and should have an expression for y' as a function of x', which is the equation for the rotated curve.
 
  • #10
You know, now that I attempt the algebra involved in the example above, I see that it gets pretty complicated because of the exp() function and the need to invert equations containing it (this is related to the fact that not every function gives rise to a simple function when rotated).

I recommend going through the steps above for a simple linear function, like a line through the origin. It's a lot easier both to solve this and also to see if the result makes sense, since you should be able to predict the correct answer.
 
  • #11
i have a ti-83... what do i put in X1T and Y1T?
 
  • #12
Beats me! I'm old-school and have never programmed a TI-83.

It's still not clear to me what you're trying to do. Do you just want to produce a plot of the rotated function? If so, then the steps outlined above should be sufficient (I'm assuming the TI-83 let's you create a function as a routine with several steps in it.)

Are you actually trying to determine the functional form of the rotated function? Do you have a specific function in mind that you want to rotate?

It would be a little easier to help if we knew what your goal is.
 
  • #13
lolgarithms said:
i have a ti-83... what do i put in X1T and Y1T?
If your original function is y= f(x), you can use x itself a parameter: x= t, y= f(t).

After the rotation, through angle \theta you have
x' = x cos(\theta) - y sin(\theta)
y' = x sin(\theta) + y cos(/theta)

Again, using x itself as parameter, that becomes
x' = t cos(\theta) - f(t) sin(\theta)
y' = t sin(\theta) + f(t) cos(\theta)

Use those as X1T and Y1T.
 
  • #14
lolgarithms said:
i have a ti-83... what do i put in X1T and Y1T?

Change [mode] to parametric, then do as Halls suggests.
 
  • #15
I assumed lolgarithms was asking about parametric mode. "X1T" and "Y1T" are what the TI-83 calls the functions in parametric mode. In function mode it would be just Y1, Y2, etc.
 
  • #16
oh, i mean ti-84 silver edition
 
  • #17
the most important for me is the functional form. is it in closed form?
 
  • #18
lolgarithms said:
the most important for me is the functional form. is it in closed form?
Not in general, I wouldn't think. Suppose you rotate a sine curve by more than 45 degrees - it will no longer be single-valued, so you won't be able to write down a simple expression for the resulting function. If it is in closed form, I'll bet it's ugly!
 

Similar threads

  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 1 ·
Replies
1
Views
1K
  • · Replies 7 ·
Replies
7
Views
2K
  • · Replies 6 ·
Replies
6
Views
3K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 7 ·
Replies
7
Views
2K
  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 3 ·
Replies
3
Views
2K