OFFSET
1,1
COMMENTS
Let points 1, 2 & 3 be placed on a straight line at intervals of 1 unit. At point 1, make a half unit circle; then, at point 2, make another half circle and maintain continuity of circumferences. Continue using this procedure at points 3, 1, 2 and so on. The form of the spiral is a non-expanded loop.
The sequence will be A047622 if the second radius = 2; if the second radius = 0, the sequence is a(n).
See illustration in links.
LINKS
Harvey P. Dale, Table of n, a(n) for n = 1..1000
Kival Ngaokrajang, Illustration of initial terms
Index entries for linear recurrences with constant coefficients, signature (1,0,0,0,1,-1).
FORMULA
G.f.: x*(7*x^4 + 4*x^3 + 4*x^2 + 7*x + 2)/((1-x)*(1-x^5)). - Ralf Stephan, Jan 20 2014
MATHEMATICA
LinearRecurrence[{1, 0, 0, 0, 1, -1}, {2, 9, 13, 17, 24, 26}, 60] (* Harvey P. Dale, May 21 2021 *)
PROG
(Small Basic)
a[1]=2
For n = 1 To 100
d1=2
m5=math.Remainder(n+1, 5)
If m5=0 Or m5=2 Then
d1=7
EndIf
If m5=3 Or m5=4 Then
d1=4
EndIf
a[n+1]=a[n]+d1
TextWindow.Write(a[n]+", ")
EndFor
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Kival Ngaokrajang, Jan 01 2014
STATUS
approved