OFFSET
0,3
LINKS
Alois P. Heinz, Table of n, a(n) for n = 0..6
Wikipedia, Falling and rising factorials
FORMULA
a(n) = Pochhammer(...(Pochhammer(Pochhammer(1, 2), 3), ...), n).
a(n) = gamma(n + a(n-1)) / gamma(a(n-1)).
a(n) = Product_{j=0..n-1} (j + a(n-1)), a(0) = 1. - Alois P. Heinz, Sep 12 2023
MAPLE
a:= proc(n) option remember; `if`(n<0, 0,
(z-> mul(z+j, j=0..n-1))(a(n-1)))
end:
seq(a(n), n=0..5); # Alois P. Heinz, Sep 12 2023
MATHEMATICA
FoldList[Pochhammer, 1, Range[5]] (* Amiram Eldar, Sep 12 2023 *)
PROG
(Python)
from gmpy2 import *
from functools import reduce
gamma = lambda n: fac(n - 1)
Pochhammer = lambda z, n: gamma(n + z) // gamma(z)
list_Pochhammer = lambda lst: int(reduce((lambda x, y: Pochhammer(x, y)), lst)) if len(lst) > 0 else 1
print([list_Pochhammer(range(1, n + 1)) for n in range(0, 6)])
(Python)
from functools import reduce
from sympy import rf
def A365617(n): return reduce(rf, range(1, n+1), 1) # Chai Wah Wu, Sep 15 2023
(PARI) P(x, y) = my(P=1); for (i=0, y-1, P *= x+i); P;
a(n) = my(x=1); n--; for (i=1, n, x = P(x, i+1)); x; \\ Michel Marcus, Sep 13 2023
CROSSREFS
KEYWORD
nonn
AUTHOR
Darío Clavijo, Sep 12 2023
STATUS
approved