login
a(2*n+2) = 8*a(2*n+1), a(2*n+1) = 8*a(2*n) - 7^n*A000108(n), a(0)=1.
4

%I #6 Nov 09 2022 19:17:56

%S 1,7,56,441,3528,28126,225008,1798349,14386792,115060722,920485776,

%T 7363180314,58905442512,471228010428,3769824083424,30158239367445,

%U 241265914939560,1930119075851050,15440952606808400,123527424655229966

%N a(2*n+2) = 8*a(2*n+1), a(2*n+1) = 8*a(2*n) - 7^n*A000108(n), a(0)=1.

%C Hankel transform is 7^C(n+1,2).

%H G. C. Greubel, <a href="/A156362/b156362.txt">Table of n, a(n) for n = 0..1000</a>

%F a(n) = Sum_{k=0..n} A120730(n,k) * 7^k.

%F a(n) = ( 8*(n+1)*a(n-1) + 28*(n-2)*a(n-2) - 224*(n-2)*a(n-3) )/(n+1). - _G. C. Greubel_, Nov 09 2022

%t a[n_]:= a[n]= If[n==0, 1, If[OddQ[n], 8*a[n-1] -7^((n-1)/2)*CatalanNumber[(n-1)/2], 8*a[n-1]]]; Table[a[n], {n, 0, 30}] (* _G. C. Greubel_, Nov 09 2022 *)

%o (Magma) [n le 3 select Factorial(n+5)/720 else (8*n*Self(n-1) + 28*(n-3)*Self(n-2) - 224*(n-3)*Self(n-3))/n: n in [1..30]]; // _G. C. Greubel_, Nov 09 2022

%o (SageMath)

%o def a(n): # a = A156362

%o if (n==0): return 1

%o elif (n%2==1): return 8*a(n-1) - 7^((n-1)/2)*catalan_number((n-1)/2)

%o else: return 8*a(n-1)

%o [a(n) for n in (0..30)] # _G. C. Greubel_, Nov 09 2022

%Y Cf. A000108, A001405, A151162, A156195, A151254, A151281, A156266, A156361.

%K nonn

%O 0,2

%A _Philippe Deléham_, Feb 08 2009