login
a(0) = 1 and a(n) = A005169(n) - A005169(n-1).
3

%I #27 Nov 14 2020 08:34:36

%S 1,0,0,1,1,2,4,6,11,19,33,57,99,172,298,518,898,1559,2706,4696,8151,

%T 14147,24554,42617,73969,128384,222831,386759,671282,1165118,2022251,

%U 3509944,6092077,10573790,18352530,31853801,55287454,95960372,166554844,289083043

%N a(0) = 1 and a(n) = A005169(n) - A005169(n-1).

%H Seiichi Manyama, <a href="/A289080/b289080.txt">Table of n, a(n) for n = 0..4179</a>

%H A. M. Odlyzko and H. S. Wilf, <a href="http://www.jstor.org/stable/2322898">The editor's corner: n coins in a fountain</a>, Amer. Math. Monthly, 95 (1988), 840-843.

%F G.f.: (1-x)/(1-x/(1-x^2/(1-x^3/(1-x^4/(1-x^5/(...)))))).

%p b:= proc(n, i) option remember; `if`(n=0, 1,

%p add(b(n-j, j), j=1..min(i+1, n)))

%p end:

%p a:= n-> b(n, 0) -b(n-1, 0):

%p seq(a(n), n=0..50); # _Alois P. Heinz_, Sep 02 2017

%t b[n_, i_] := b[n, i] = If[n==0, 1, Sum[b[n-j, j], {j, 1, Min[i+1, n]}]];

%t a[n_] := b[n, 0] - b[n-1, 0];

%t a /@ Range[0, 50] (* _Jean-François Alcover_, Nov 14 2020, after _Alois P. Heinz_ *)

%Y Column 2 of A288267 (except a(0)).

%Y Cf. A005169.

%K nonn

%O 0,6

%A _Seiichi Manyama_, Sep 02 2017