%I #15 Apr 21 2018 06:22:08
%S 0,1,2,3,6,21,108,693,5220,44901,433350,4632147,54285714,691817841,
%T 9522592632,140763435957,2223647197416,37379712048201,666163875275370,
%U 12544974494087427,248900998255922430,5189286039892108749,113417589882858625188,2593036709186072053077,61892628250817153398284
%N a(0)=0, a(1)=1; for n>1, a(n) = n*a(n-1) - 3*a(n-2).
%C a(n) is divisible by 3^floor(n/3).
%H Colin Barker, <a href="/A303224/b303224.txt">Table of n, a(n) for n = 0..450</a>
%F From _Peter Bala_, Apr 20 2018: (Start)
%F a(n) = Sum_{k = 0..floor((n-1)/2))} (-3)^k*binomial(n-k,k+1)*binomial(n-k-1,k)*(n-2*k-1)!.
%F a(n)/n! ~ BesselJ(1, 2*sqrt(3)) / sqrt(3). (End)
%F a(n) = -2 * i^n * 3^(n/2) * (BesselI(1+n, -2*i*sqrt(3)) * BesselK(1,-2*i*sqrt(3)) + (-1)^n * BesselI(1, 2*i*sqrt(3)) * BesselK(1+n, -2*i*sqrt(3))), where i is the imaginary unit. - _Vaclav Kotesovec_, Apr 20 2018
%t RecurrenceTable[{a[0] == 0, a[1] == 1, a[n] == n a[n - 1] - 3 a[n - 2]}, a, {n, 0, 30}]
%t Flatten[{0, Table[n!*HypergeometricPFQ[{1/2 - n/2, 1 - n/2}, {2, 1 - n, -n}, -12], {n, 1, 25}]}] (* _Vaclav Kotesovec_, Apr 20 2018 *)
%t Round[Table[-2 I^n 3^(n/2) (BesselI[1 + n, -2 I Sqrt[3]] BesselK[1, -2 I Sqrt[3]] + (-1)^n BesselI[1, 2 I Sqrt[3]] BesselK[1 + n, -2 I Sqrt[3]]), {n, 0, 25}]] (* _Vaclav Kotesovec_, Apr 20 2018 *)
%o (PARI) a=vector(30); a[1]=0; a[2]=1; for(n=3, #a, a[n]=(n-1)*a[n-1]-3*a[n-2]); a
%Y Cf. A058798: a(n) = n*a(n-1) - a(n-2).
%Y Cf. A222470: a(n) = n*a(n-1) - 2*a(n-2), without 0.
%Y Cf. A222472: a(n) = n*a(n-1) + 3*a(n-2), without 0.
%Y Cf. A221913.
%K nonn
%O 0,3
%A _Bruno Berselli_, Apr 20 2018