The regular polygons with an integral number of degrees in their angles are as follows:
degrees sides divisors of
number of sides
60 3 2
90 4 3
108 5 2
120 6 4
135 8 4
140 9 3
144 10 4
150 12 6
156 15 4
160 18 6
162 20 6
165 24 8
168 30 8
170 36 9
171 40 8
172 45 6
174 60 12
175 72 12
176 90 12
177 120 16
178 180 18
179 360 24
In order for a regular polygon to be the only inscribable polygon of that number of sides and equal angles, the number of sides must be odd, as an even number of sides could have two alternating side lengths and still have equal angles. The only entry on the above table with an odd number of sides which also has an odd number of divisors, is the 9-gon.
So N is 9 and M is 3.
DEFDBL A-Z
PRINT
FOR d = 60 TO 179
den = 180 - d
IF 360 MOD den = 0 THEN
n = 360 / den
ct = 0
FOR i = 1 TO n
IF n MOD i = 0 THEN ct = ct + 1
NEXT
PRINT d, n, ct
END IF
NEXT
Based on Enigma No. 1587, "Deja vu", by Susan Denham, New Scientist, 20 March 2010. |