OFFSET
0,3
EXAMPLE
The positive divisors of 8 are 1,2,4,8. So a(8) = (the number of earlier terms coprime to 1, which is 8) + (the number of earlier terms coprime to 2, which is 3 for a(0)=1, a(1)=1 and a(6) = 15) + (the number of earlier terms coprime to 4, which is 3) + (the number of earlier terms coprime to 8, which is 3) = 8 + 3 + 3 + 3 = 17.
MATHEMATICA
f[l_List] := Block[{n = Length[l], d = Divisors[n], c = 0}, Do[ c += Length[Select[l, GCD[ #, d[[i]]] == 1 &]]; , {i, Length[d]}]; Append[l, c]]; Nest[f, {1}, 64] (* Ray Chandler, Feb 08 2007 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Leroy Quet, Jan 29 2007
EXTENSIONS
Extended by Ray Chandler, Feb 08 2007
STATUS
approved