Formula for Graphing Circle based on Points

236 Views Asked by At

I'm a Software Engineer, not super awesome at Math; however, I definitely need some help on the Math side for some animation work I'm trying to accomplish, and I am clueless how to get there :)

For a basic idea of what I am trying to achieve, imagine a circle whose $0$ degree mark is $12$ o'clock and $180'$ is $6$ o'clock. I need to draw the outline starting at about $200$ degrees to about $160$ degrees.

The platform I am developing on, is limited to drawing lines, or a dot at point$(x, y)$. This animation must change position each frame, so I need to be able to re-apply the formula to the new $(x, y)$, the old ones, and draw it again. Is there a formula that would change $(x, y)$ each time I pass it that would graph a circle? I'm probably not explaining things that great, so I'll try to break it down as simply as I can, because I do not know what the word/terminology is for what I'm attempting to ask...

I need to say, computer, take point$(x, y)$, draw a dot. (NEW_FRAME) Now, take point$(x, y)$. draw a dot, and take point$(x_2, y_2)$, draw a dot. Over and over. I need a way to get $(x, y)$ to $(x_2, y_2)$, and then to $(x_3, y_3)$ until the outline of a circle would be created.

I apologize in advance for sounding like complete moron and using all of the wrong terminology. Thanks in advance for any advice!

2

There are 2 best solutions below

0
On BEST ANSWER

In an x–y Cartesian coordinate system, the circle with centre coordinates (a, b) and radius r is the set of all points (x, y) such that $$\left(x - a \right)^2 + \left( y - b \right)^2=r^2.$$ (Source: Wikipedia) Use the equation to plot all points/lines on your table of x's and y's.

0
On

enter image description here This might help, you can take the image down .