This site is supported by donations to The OEIS Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A023421 Generalized Catalan Numbers. 5

%I

%S 1,1,1,1,1,2,4,8,16,32,65,133,274,568,1184,2481,5223,11042,23434,

%T 49908,106633,228505,490999,1057683,2283701,4941502,10713941,23272929,

%U 50642017,110377543,240944076,526717211,1152996206,2527166334,5545804784,12184053993

%N Generalized Catalan Numbers.

%H Seiichi Manyama, <a href="/A023421/b023421.txt">Table of n, a(n) for n = 0..2795</a>

%p A023421 := proc(n)

%p option remember;

%p if n = 0 then

%p 1;

%p else

%p end if;

%p end proc: # _R. J. Mathar_, May 01 2015

%t a[0]=1; a[n_]:= a[n]=a[n-1] + Sum[a[k]*a[n-2-k], {k,3,n-2}]; Table[a[n], {n,0,30}] (* modified by _G. C. Greubel_, Jan 01 2018 *)

%o (PARI) {a(n) = if(n==0,1, a(n-1) + sum(k=3,n-2, a(k)*a(n-k-2)))};

%o for(n=0,30, print1(a(n), ", ")) \\ _G. C. Greubel_, Jan 01 2018

%Y Cf. A000108, A001006, A004148, A004149, A023422, A023423.

%Y Fourth row of A064645.

%K nonn,easy

%O 0,6