login
a(n) = n! + n*(n-1)!!.
1

%I #10 Dec 07 2016 12:35:25

%S 1,2,4,12,36,160,810,5376,41160,366336,3638250,39959040,479126340,

%T 6227619840,87180183090,1307684044800,20922822320400,355687603568640,

%U 6402374325997650,121645103938928640,2432902021271221500,51090942249743155200,1124000728080092512650

%N a(n) = n! + n*(n-1)!!.

%H Alois P. Heinz, <a href="/A275539/b275539.txt">Table of n, a(n) for n = 0..449</a>

%F a(n) = n! + n*(n-1)!! = n*((n-1)! + (n-1)!!).

%p a:= proc(n) option remember; `if`(n<5, [1, 2, 4, 12, 36]

%p [n+1], ((n-3)^2*n*a(n-1) +(n-4)*n*(n-1)*a(n-2)

%p -(n-3)*n*(n-1)*(n-2)*a(n-3))/((n-4)*(n-2)))

%p end:

%p seq(a(n), n=0..25); # _Alois P. Heinz_, Dec 07 2016

%t Table[n! + n (n-1)!!, {n, 0, 20}] (* _Bruno Berselli_, Aug 11 2016 *)

%Y Cf. A000142, A080497.

%K nonn,easy

%O 0,2

%A _Olivier GĂ©rard_, Aug 01 2016