login
A129440
a(0)=0, a(1)=1, a(2)=5 and for n>2: a(n) = a(n-1)*(a(n-1) + 1)*(2*a(n-1) + 1)/6.
3
0, 1, 5, 55, 56980, 61667666167030, 78172010815921069181209893626754427513955
OFFSET
0,3
LINKS
FORMULA
a(n) = A000330(if n<=2 then n else a(n)).
a(n) ~ sqrt(3) * c^(3^n), where c = 1.13701835838072682283814038264701129587627956851233106833915157... . - Vaclav Kotesovec, Dec 17 2014
MATHEMATICA
Flatten[{0, 1, RecurrenceTable[{a[2] == 5, a[n] == a[n-1]*(a[n-1] + 1)*(2*a[n-1] + 1)/6}, a[n], {n, 8}]}] (* Vaclav Kotesovec, Dec 17 2014 *)
Join[{0, 1}, NestList[(#(#+1)(2#+1))/6&, 5, 5]] (* Harvey P. Dale, Sep 13 2022 *)
PROG
(Magma) [0, 1] cat [n le 1 select 5 else Self(n-1)*(Self(n-1)+1)*(2*Self(n-1)+1)/6: n in [1..8]]; // G. C. Greubel, Feb 06 2024
(SageMath)
def a(n): # a = A129440
if n<3: return (0, 1, 5)[n]
else: return a(n-1)*(a(n-1)+1)*(2*a(n-1)+1)/6
[a(n) for n in range(9)] # G. C. Greubel, Feb 06 2024
CROSSREFS
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, Apr 15 2007
STATUS
approved