# What angles of a ray will result in a closed shape?

Lets say you have a point, draw a ray of length 1 from it, let the angle of that ray be $$\theta$$. Now, draw another ray of length $$1$$ from the end of the previous ray with the same angle as before, $$\theta$$. Repeat this process.

Example: Let $$\theta = \pi/2$$. Draw a point, and then draw a ray of length $$1$$ from it, at an angle of $$\pi/2$$ (straight to the left.) Then, draw another ray of length $$1$$ and at an angle of $$\pi/2$$ from the end of the previous ray, repeat this and eventually you will end up with a square.

My question is, is there any way to find and recognize values for $$\theta$$ which will produce non-trivial closed shapes? (Non-trivial as in not a regular polygon wich never intersects itself.) (Intersection with previous rays is allowed.)

• Can you find a example except $\theta=\frac{\pi}{2}$ or $\theta=\frac{3\pi}{2}$ where it is not closed? Commented Nov 18, 2023 at 18:58
• If I understand correctly: assume your closed form has N rays. Start in one point, and from there draw lines to each other corner point. How many triangles do you have? What is the total sum of angles then for your closed form? So what is the angle between each two adjacent rays? Commented Nov 18, 2023 at 19:34
• From what I understand, the number of triangles wich any polygon can be divided into is its number of vertices minus two, the sum of all the internal angles will be 180 multiplied by the number of triangles, and the angle between 2 adjacent rays will be θ. What I struggle to understand however, is there any criteria for θ such that it will make a closed shape? Commented Nov 19, 2023 at 20:39
• @user1253977 If you keep drawing length $1$ after each turn through $\theta$ and you want to come back exactly to start, then the figure has to be a regular polygon, unless you can intersect previous sides some times and then eventually return to start, in which case i don't know what might occur. Commented Nov 19, 2023 at 20:50
• @coffeemath Yes, in this problem side intersection is allowed. Wich is why I am now stuck on how to solve this, because how would you know that the shape will return to its original point? For all we know it could go on for 1 million rays until it returns back to the original point. This seems similar to the 3x + 1 problem Commented Nov 19, 2023 at 20:52

Once you have three points, that is, once you have actually constructed two line segments so that the angle between line segments is demonstrated, then these three points uniquely determine a circle that passes through all three points.

Assuming you turn $$\theta$$ radians in the same direction every time, the third line segment has the same geometric relation to the second segment as the second segment had to the first, and the three endpoints of these two segments will determine the exact same circle.

Continue like this and every endpoint of every line segment will land on the same circle again.

Now imagine an observer sitting at the center of this circle, watching the tip of your pencil as it traces the line segments you are drawing and measuring the angle through which you traveled from their point of view. Traveling $$2\pi$$ radians would take you exactly once around the circle.

In order for you to return back to the starting point in order to make a closed shape, the observer at the center of the circle will have to see you travel an exact multiple of $$2\pi$$ radians in whatever number of steps you took. Any other angle will not bring you back to the starting point. Suppose you drew $$n$$ line segments and the observer saw you travel a total of $$2m\pi$$ radians. Then on each line segment you traveled $$2m\pi/n$$ radians, that is, each segment is the base of an isosceles triangle whose apex is at the center of the circle, the apex angle is $$2m\pi/n$$, the two base angles are each $$(\pi/2) - (m\pi/n)$$, the interior angle between two line segments (the bases of two adjacent isosceles triangles) is $$\pi - 2m\pi/n$$, and the exterior angle between two line segments (how much you have to change your direction of travel if you travel to the end of one segment and then start traveling along the next one) is $$2m\pi/n$$.

It was not clear to me whether $$\theta$$ was the interior angle between two line segments or the exterior angle between the two line segments, but each of these angles is a rational multiple of $$\pi$$. That is, you get a closed figure if and only if $$\theta$$ is a rational multiple of $$\pi$$.

So to tell whether your angle will produce a closed figure, divide it by $$\pi$$. You have a closed figure if and only if $$\theta/\pi$$ is a rational number.

You get a regular polygon in all cases where the exterior angle between segments is $$\pi/k$$ for some integer $$k \geq 3$$. In all other cases where you get a closed figure, the figure is a star. There are no other closed figures.

• This is the complete answer! I thought there were gonna be other shapes other than the regular polygons and stars, but I guess not. Thank you! Commented Nov 20, 2023 at 2:58

I think you are asking for the star polygons. Start with a regular $$n$$-gon. Choose some $$k$$ less than $$n$$ and relatively prime to $$n$$ and join the vertices of the $$n$$-gon with diagonals that connect vertices $$k$$ apart.

• This is probably the answer! This fits what I'm looking for, but would there be a way to find other shapes that fit the criteria other than stars? Commented Nov 19, 2023 at 21:23
• @user1253977 There is a strong connection to the "Billiard Shot Angles for Circular Table: Return to Starting Point" thread math.stackexchange.com/questions/4796069/… which you might find helpful.
– KDP
Commented Nov 19, 2023 at 22:11