OFFSET
2,5
LINKS
J. C. Lagarias, E. M. Rains and N. J. A. Sloane, The EKG sequence, arXiv:math/0204011 [math.NT], 2002; Exper. Math. 11 (2002), 437-446.
MATHEMATICA
ekg[s_] := Block[{m = s[[-1]], k = 3}, While[MemberQ[s, k] || GCD[m, k] == 1, k++]; Append[s, k]];
EKG = Nest[ekg, {1, 2}, 71] ;
a[n_] := Count[EKG[[2 ;; n]], _?OddQ];
Table[a[n], {n, 2, 71}] (* Jean-François Alcover, Jan 11 2019, after Robert G. Wilson v in A064413 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
N. J. A. Sloane, Oct 05 2001
STATUS
approved