Mathematica Solving Polar Coordinate Rotation Problems with Mathematical Models

  • Thread starter Thread starter transgalactic
  • Start date Start date
  • Tags Tags
    Mathematical
AI Thread Summary
The discussion focuses on solving polar coordinate rotation problems, specifically rotating a point around a center point by a given angle. The initial approach involved calculating the slope and using trigonometric functions, but it yielded incorrect results in certain cases. A more effective method involves translating the points so the center point is at the origin, applying rotation formulas, and then translating back to the original position. The correct formulas for rotation around a non-origin center point were provided, emphasizing the importance of understanding the underlying theory rather than relying solely on memorized formulas. This comprehensive approach ensures accurate results for all cases of point rotation.
transgalactic
Messages
1,386
Reaction score
0
i lack the knowledge in some area of polar coordenates

my problem is:

i was given a two points and an angle

one point is the center point the other is the the point we spin around the
center point by the given angle(rotation clock wise).

i have build a model to solve this problem by

slope=(y-center.y)/(x-center.x);
fi=arctan(slope);

beta=fi-angle;

xi=rad*cos(beta);
yi=rad*sin(beta);
x=center.x+xi;

y=center.y+yi;

but in a case of 2,1 as a center point
and 0,0 as the point we want to spin
when i spined it 90 deress(clock wise)

by this model i gave me a wronge answer (the right one is 1,3)

so by tryle and error method i found that we need to add 180 degrees

i don't know why
i don't know how to solve this problem
??
i want a solution for all the cases
 
Physics news on Phys.org
transgalactic said:
i lack the knowledge in some area of polar coordenates

my problem is:

i was given a two points and an angle

one point is the center point the other is the the point we spin around the
center point by the given angle(rotation clock wise).

i have build a model to solve this problem by

You are talking about soving a problem, but you have not mentioned what is the problem. Mention it clearly. (The rest of your post is your method about an undefined problem.)
 
i am looking for mathematical formulas that
takes two points
one point considered as a center point
the other point is the point which is rotated around her.
by a given angle
the direction of the rotation is clock wise

i want to find the coordinates of the point after we rotated the given one
around the cente point

for example
(0,1)
(0,0) -center point
rotation angle 90 degrees
the answer is (1,0)

there are many cases in this problems
i don't know how to solve it
how to find a method that solves all the possibilities
 
x = x'cosθ - y'sinθ
y = x'sinθ + y'cosθ

These are the formulae, if the x'-y' axes are rotated by angle θ anticlockwise. So, wrt x'-y' system, x-y system will rotate clockwise, thus giving you the answer.
 
what about the center point
its not mentioned anywhere

i was tal to use polar angle etc...
i don't know ho to use them here??
 
The centre point is (0,0).

For polar angles, put x=r cos theta, y = r sin theta.

You had given the example:
for example
(0,1)
(0,0) -center point
rotation angle 90 degrees
the answer is (1,0)


Try the formula I'd given to verify it. Use proper signs.
 
for the center point 0,0 i had a working model that i shower
previosly
i tried your sulotion it dousnt work for all cases
like

in a case of 2,1 as a center point
and 0,0 as the point we want to spin
when i spined it 90 deress(clock wise)

i didnt get ( 1,3)

please wright a whole formula for all cases
when i use
a1,b1 as a center point
a2,b2 as a spin point
beta as the angle we want to spin point a2,b2 clock wise

one formule for X

one formule for y
 
Where do people get this idea that there is some "magical formula" that will do everything for them? One of the reasons you learn "theory" or how to derive formulas is so you will be able to modify formulas for other situations.

Shootingstar gave you the formulas for the case when the "center point" is (0,0). If it not, if the center point is (x_0, y_0), follow this procedure: translate all points so the center point is at (0,0). To do that, subtract x_0 from the x coordinate, y_0 from the y coordinate. Then use Shootingstar's formula to rotate. Finally, translate back to the starting position by adding x_0 and y_0.

In your example, in your first example, your center point is (2, 1) and you want to rotate (0, 0) 90 degrees about (2, 1). Okay. first "translate". Subtracting (2, 1) moves (2, 1) to (2- 2, 1-1)= (0,0) and moves (0, 0) to (0-2, 0-1)= (-2, -1). Now we want to rotate (-2,-1) 90 degrees around (0,0). cos(90)= 0, sin(90)= 1 so Shootingstar's formulas become x= x'cosθ - y'sinθ= (-2)(0)- (-1)(1)= 1 and y = x'sinθ + y'cosθ= (-2)(1)+ (-1)(0)= -2. Finally translate back: (1+ 2, -2+ 1)= (3, -2). I don't know why you said above "I didn't get (1, 3)" a rough picture should show you that rotating (0,0) 90 degrees counter clockwise around (2, 1) will give a point with x larger than 2 and y negative: (3, -2).

To rotate the point (a_2, b_2) \beta degrees counter clockwise around (a_1, b_1):

First translate: (a_2,b_2) is moved to (a_2- a_1, b_2- b_1)

Then rotate: ((a_2-a_1)cos(\beta)- (b_2-b_1)sin(\beta), (a_2-a_1)sin(\beta)-(b-2-b_1)cos(\beta)).

Finally translate back: ((a_2-a_1)cos(\beta)- (b_2-b_1)sin(\beta)+ a_1, (a_2-a_1)sin(\beta)-(b-2-b_1)cos(\beta)+ b_2).

I can't imagine anyone trying to memorize or even use a formula in that form. Far better to think about what you are doing!
 

Similar threads

Back
Top