Finding specific plots in a circle

59 Views Asked by At

New to the site, but I've run into a math problem, and I thought I'd ask the amazing internet for help. The problem is as follows: I want to find 8 plots in a 100x100 circle 2D plane, all 8 plots must have an equal distance between each other. Furthermore, I need to do the same with 7 plots, 6 plots.. all down to 3 plots. Further-furthermore - I need a way to slightly decrease the circle and then find those plots again with the newly created smaller circle. It all sounds very confusing to me, so I found my inner paint artists and tried to illustrate what I meant.

Click here to see the image. I hope it makes slightly sense. Thank you in advance.

1

There are 1 best solutions below

5
On

If you want each of your circles to have the same number of points/plots on them, then just use the formula $$ (x, y) = \left( (50 - kr)\cdot\cos\left(n\cdot\frac{2\pi}{p}\right) + 50, (50 - kr)\cdot\sin\left(n\cdot\frac{2\pi}{p}\right) + 50 \right) $$ where $p$ is the number of plots that you want, $n$ ranges between $0, 1, \ldots, p-1$ to give you equally spaced points around the circle(s), $r$ is the distance between the different sized circles, and $k$ ranges from $0$ to the integer part of $50/r$ where $k = 0$ corresponds to the largest circle, $k=1$ corresponds to the next largest circle, and so on. Is this what you're after?


Example. Suppose you want eight equally spaced points, so that $p = 8$. Then you have the following cosine and sine values: $$ \begin{array}{r|c|c|c|c|c|c|c|c} n & 0 & 1 & 2 & 3 & 4 & 5 & 6 & 7\\\hline \cos(2n\pi/8) & 1 & 1/\sqrt{2} & 0 & -1/\sqrt{2} & -1 & -1/\sqrt{2} & 0 & 1/\sqrt{2}\\ \sin(2n\pi/8) & 0 & 1/\sqrt{2} & 1 & 1/\sqrt{2} & 0 & -1/\sqrt{2} & -1 & -1/\sqrt{2}\\ \end{array} $$ These can be determined quickly by using Excel (or some variant), especially for other values of $p$. Thus, the coordinates on the largest circle are $$ \begin{array}{cc} (100, 50), & \big((50/\sqrt{2}) + 50, (50/\sqrt{2}) + 50\big),\\ (50, 100), & \big((-50/\sqrt{2}) + 50, (50/\sqrt{2}) + 50\big),\\ (0, 50), & \big((-50/\sqrt{2}) + 50, (-50/\sqrt{2}) + 50\big),\\ (50, 0), & \big((50/\sqrt{2}) + 50, (-50/\sqrt{2}) + 50\big),\\ \end{array} $$ or, in decimal, $$ \begin{array}{cc} (100, 50), & (85.3553, 85.3553),\\ (50, 100), & (14.6447, 85.3553),\\ (0, 50), & (14.6447, 14.6447),\\ (50, 0), & (85.3553, 14.6447).\\ \end{array} $$ If your distance to the next largest circle is $10$, then the coordinates are $$ \begin{array}{cc} (90, 50), & \big((40/\sqrt{2}) + 50, (40/\sqrt{2}) + 50\big),\\ (50, 90), & \big((-40/\sqrt{2}) + 50, (40/\sqrt{2}) + 50\big),\\ (10, 50), & \big((-40/\sqrt{2}) + 50, (-40/\sqrt{2}) + 50\big),\\ (50, 10), & \big((40/\sqrt{2}) + 50, (-40/\sqrt{2}) + 50\big),\\ \end{array} $$ or, in decimal, $$ \begin{array}{cc} (90, 50), & (78.2843, 78.2843),\\ (50, 90), & (21.7157, 78.2843),\\ (10, 50), & (21.7157, 21.7157),\\ (50, 10), & (78.2843, 21.7157).\\ \end{array} $$ All decimal values have been rounded to four significant figures. I hope it is clear now how one might continue, and do the same with different values for $p$.


Excel Spreadsheet. The following image gives a small example of what I would do to generate the points. I have included the equations for cells B$3$, B$4$, B$6$, and B$7$ at the bottom --- these can be dragged across to apply to all cells in the range that you require. Then you can change the values for $p, k, r$ to get the points on different circles according to which circle you want the coordinates for.

enter image description here