1
$\begingroup$

I know the center of a circle $(C_x, C_y)$. I know a point on the circle $(X_1, Y_1)$. I want to know the coordinates of a new point on the circle $(X_2,Y_2)$ a certain number degrees $(d)$ away from the original point.

Would this equation be correct?

$$X_2 = C_x + \sqrt{(X_1-C_x)^2+(Y_1-C_y)^2}\cos\left(\arctan\left({y\over x}\right) + d\right)\\[10pt] Y_2 = C_y + \sqrt{(X_1-C_x)^2+(Y_1-C_y)^2}\sin\left(\arctan\left({y\over x}\right) + d\right)$$

So to clarify my question to make sure it is clear, I am starting at a certain point $(X_1,Y_1)$ on a circle (center $C_x,C_y$) and want to travel along the circle a certain number of degrees $(d)$ and come up with the new coordinates at that point $(X_2,Y_2)$

Is the equation I have above correct? And if so, is there a way to make it better/simpler?

$\endgroup$
3
  • $\begingroup$ What are $x$ and $y$? What do you do when $x=0$? You can get a much simpler formula by applying a rotation to the initial point. $\endgroup$
    – amd
    Sep 17, 2018 at 23:02
  • $\begingroup$ That is part of my issue. I do not know how to handle that case. How do you apply a rotation to the initial point? That is what I am trying to figure out. Thanks! $\endgroup$
    – user168226
    Sep 18, 2018 at 12:32
  • $\begingroup$ academo.org/demos/rotation-about-point $\endgroup$
    – amd
    Sep 18, 2018 at 19:58

1 Answer 1

1
$\begingroup$

You're almost there. Is there a specific direction you want to go, i.e. do you want to increase d degrees, or decrease d degrees, or both? If both you need +/- in front of d.

Suppose d were 0 and y=Y1 and x=X1. Does your formula yield the proper values for Y2 and X2? If not, how might it need to change?

$\endgroup$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .