OFFSET
1,2
FORMULA
G.f. A(x) satisfies: A(x) = x * (1 / (1 - x) + Sum_{k>=1} phi(k) * A(x^k)).
a(1) = 1; a(n+1) = 1 + Sum_{d|n} phi(n/d) * a(d).
MATHEMATICA
a[n_] := a[n] = 1 + Sum[a[GCD[n - 1, k]], {k, 1, n - 1}]; Table[a[n], {n, 1, 50}]
nmax = 50; A[_] = 0; Do[A[x_] = x (1/(1 - x) + Sum[EulerPhi[k] A[x^k], {k, 1, nmax}]) + O[x]^(nmax + 1) // Normal, nmax + 1]; CoefficientList[A[x], x] // Rest
CROSSREFS
KEYWORD
nonn
AUTHOR
Ilya Gutkovskiy, Jul 05 2021
STATUS
approved