|
|
A081405
|
|
a(n) = (n+1)*a(n-2) with a(0) = a(1) = 1.
|
|
6
|
|
|
1, 1, 3, 4, 15, 24, 105, 192, 945, 1920, 10395, 23040, 135135, 322560, 2027025, 5160960, 34459425, 92897280, 654729075, 1857945600, 13749310575, 40874803200, 316234143225, 980995276800, 7905853580625, 25505877196800, 213458046676875
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,3
|
|
COMMENTS
|
|
|
LINKS
|
|
|
FORMULA
|
a(0)=a(1)=1; a(2n) = A001147(2*n-2) odd terms, double factorial numbers; a(2n-1) = A002866(n) = 2^(n-1)*n!
0 = a(n)*(a(n+1) - a(n+3)) + a(n+1)*a(n+2) if n>=0. - Michael Somos, Jan 24 2014
|
|
EXAMPLE
|
G.f. = 1 + x + 3*x^2 + 4*x^3 + 15*x^4 + 24*x^5 + 105*x^6 + 192*x^7 + ...
|
|
MAPLE
|
a[0]:=1:a[1]:=1:for n from 2 to 50 do a[n]:=(a[n-2]*(n+1)^2) od: seq(sqrt(a[n]), n=0..26); # Zerinvary Lajos, Mar 04 2008
|
|
MATHEMATICA
|
f[n_]:= (n+1)*f[n-2]; f[0] = 1; f[1] = 1; Table[f[n], {n, 1, 30}]
a[ n_]:= If[ n < 0, 0, If[OddQ[n], 2^((n-1)/2) ((n+1)/2)!, (n+1)!!]]; (* Michael Somos, Jan 24 2014 *)
RecurrenceTable[{a[0]==a[1]==1, a[n]==(n+1)a[n-2]}, a, {n, 30}] (* Harvey P. Dale, Nov 05 2021 *)
|
|
PROG
|
(PARI) {a(n) = if( n<2, n>=0, (n+1) * a(n-2))}; /* Michael Somos, Jan 24 2014 */
(PARI) {a(n) = if( n<0, 0, if( n%2, 2^(n\2) * (n\2 + 1)!, (n+1)! / (2^(n\2) * (n\2)!)))}; /* Michael Somos, Jan 24 2014 */
(Magma) [n le 1 select 1 else (n+1)*Self(n-1): n in [0..30]]; // Vincenzo Librandi, Oct 26 2014
(Sage)
def a(n):
if n<2: return 1
else: return (n+1)*a(n-2)
(GAP)
a:= function(n)
if n<2 then return 1;
else return (n+1)*a(n-2);
fi;
end;
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|