OFFSET
1,4
COMMENTS
The positions of records are A029744. - Andrey Zabolotskiy, Jan 30 2017
LINKS
Andrey Zabolotskiy, Table of n, a(n) for n = 1..10000
FORMULA
a(p^(n+1)) = A007018(n) if p is a prime. - Michael Somos, May 19 2018
EXAMPLE
a(12) = a(1)^2 + a(2)^2 + a(3)^2 + a(4)^2 + a(6)^2 = 1^2 + 1^2 + 1^2 + 2^2 + 3^2 = 1 + 1 + 1 + 4 + 9 = 16.
MATHEMATICA
a[ n_] := If[ n < 2, Boole[n == 1], Sum[ a[d]^2, {d, Drop[Divisors @ n, -1]}]]; (* Michael Somos, May 19 2018 *)
PROG
(Python)
a = [1]
for n in range(2, 10001):
a.append(sum(a[d-1]**2 for d in range(1, n) if n%d == 0))
print(a)
# Andrey Zabolotskiy, Jan 30 2017
(PARI) a(n) = if (n==1, 1, sumdiv(n, d, if (d<n, a(d)^2))); \\ Michel Marcus, Jan 30 2017
CROSSREFS
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, May 13 2003
EXTENSIONS
Typo in data corrected by Andrey Zabolotskiy, Jan 30 2017
STATUS
approved