%I #44 Sep 08 2022 08:45:20
%S 0,1,1,4,9,31,91,309,1009,3481,11956,42065,148655,532039,1915369,
%T 6950452,25357233,93034813,342888250,1269246437,4715945712,
%U 17583623988,65766726906,246694006971,927801717255,3497918129001,13217196871126,50046561077947
%N G.f.: C - Z; where C is the g.f. for the Catalan numbers (A000108) and Z is the g.f. for A055113 with offset 0.
%C Expressible in terms of ballot numbers.
%C Number of positive walks with n steps {-2,-1,1,2} starting at the origin, ending at altitude 2, and staying strictly above the x-axis. - _David Nguyen_, Dec 16 2016
%H T. D. Noe, <a href="/A111160/b111160.txt">Table of n, a(n) for n=0..200</a>
%H C. Banderier, C. Krattenthaler, A. Krinik, D. Kruchinin, V. Kruchinin, D. Nguyen, and M. Wallner, <a href="https://arxiv.org/abs/1609.06473">Explicit formulas for enumeration of lattice paths: basketball and the kernel method</a>, arXiv preprint arXiv:1609.06473 [math.CO], 2016.
%H Jean-Luc Baril and José L. Ramírez, <a href="http://jl.baril.u-bourgogne.fr/knight.pdf">Knight's paths towards Catalan numbers</a>, Univ. Bourgogne Franche-Comté (2022).
%H D. G. Rogers, <a href="/A111160/a111160.txt">Comments on A111160, A055113 and A006013</a>
%F Let C := (1 - sqrt(1 - 4*x)) / (2*x), Z := (- 1/4 - (1/4)*(1 - 4*x)^(1/2) + (1/4)*(2 + 2*(1 - 4*x)^(1/2) + 12*x)^(1/2))/x; g.f. is W := C - Z.
%F G.f.: -((-3 + sqrt(1 - 4x) + sqrt(2)*sqrt(1 + sqrt(1 - 4x) + 6x))/(4x)).
%F a(n) = sum(j=0..n+1, binomial(n+2*j-1,j)*(-1)^(n+j+1)*binomial(2*n+1,j+n))/(2*n+1). [_Vladimir Kruchinin_, Feb 15 2013]
%F a(n) ~ (1+1/sqrt(5))*2^(2*n-1)/(sqrt(Pi)*n^(3/2)). - _Vaclav Kotesovec_, Aug 13 2013
%F Recurrence: 2*n*(n+1)*(2*n+1)*(5*n-8)*a(n) = n*(115*n^3 - 344*n^2 + 299*n - 82)*a(n-1) + 4*(2*n-3)*(5*n^3 + 27*n^2 - 74*n + 30)*a(n-2) - 36*(n-2)*(2*n-5)*(2*n-3)*(5*n-3)*a(n-3). - _Vaclav Kotesovec_, Aug 13 2013
%F a(n) = Sum_{j=0..(n+1)/2}(binomial(n-j,n-2*j+1)*binomial(2*n+1,j))/(2*n+1). - _Vladimir Kruchinin_, Oct 05 2015
%F a(n) = (-1)^(n+1)*C(2*n+1,n)*hypergeom([-n-1,n/2+1/2,n/2],[n,n+1],4)/(2*n+1) for n>0. - _Peter Luschny_, Oct 06 2015
%p a := n -> (-1)^(n+1)*binomial(2*n+1,n)*hypergeom([-n-1,n/2+1/2,n/2],[n,n+1],4)/ (2*n+1);
%p [0, op([seq(round(evalf(a(n),32)), n=1..27)])]; # _Peter Luschny_, Oct 06 2015
%t CoefficientList[ Series[ -((-3 + Sqrt[1 - 4*x] + Sqrt[2]*Sqrt[1 + Sqrt[1 - 4x] + 6x])/(4x)), {x, 0, 10}], x] (* _Robert G. Wilson v_ *)
%o (PARI) a(n) = if(n==0, 0, sum(k=0, (n+1)/2, binomial(n-k,n-2*k+1)*binomial(2*n+1,k))/(2*n+1)); \\ _Altug Alkan_, Oct 05 2015
%o (Magma) I:=[1,1,4]; [0] cat [n le 3 select I[n] else (n*(115*n^3 - 344*n^2 + 299*n - 82)*Self(n-1) + 4*(2*n-3)*(5*n^3 + 27*n^2 - 74*n + 30)*Self(n-2) - 36*(n-2)*(2*n-5)*(2*n-3)*(5*n-3)*Self(n-3))/(2*n*(n+1)*(2*n+1)*(5*n-8)): n in [1..30]]; // _Vincenzo Librandi_, Oct 06 2015
%Y Cf. A000108, A055113, A006013, A187430, A276901, A306668.
%K nonn
%O 0,4
%A _N. J. A. Sloane_, Oct 22 2005