OFFSET
0,3
COMMENTS
The Dyck step set is U=(1,1) and D=(1,-1). A meander is a path starting at (0,0) and never crossing the x-axis, i.e., staying at nonnegative altitude.
LINKS
Andrei Asinowski, Cyril Banderier, and Valerie Roitner, Generating functions for lattice paths with several forbidden patterns, preprint, 2019.
FORMULA
G.f.: (1 - t - t^2 - t^3 + t^4 + t^5 - (1+t)*sqrt(t^8-2*t^6-t^4-2*t^2+1))/(2*t*(t^2+t-1)).
D-finite with recurrence: (n+1)*a(n) +(n-2)*a(n-1) -2*n*a(n-2) +(-2*n+3)*a(n-3) +(-n+2)*a(n-4) +(-n+4)*a(n-5) +(-2*n+13)*a(n-6) +2*(-n+9)*a(n-7) +(n-10)*a(n-8) +(n-11)*a(n-9)=0. - R. J. Mathar, Jan 27 2020
EXAMPLE
a(5)=4 since we have 4 meanders of length 5, namely UUUUU, UUUUD, UUUDD and UUDDU.
MATHEMATICA
CoefficientList[Series[(1 - x - x^2 - x^3 + x^4 + x^5 - (1 + x)*Sqrt[x^8 - 2 x^6 - x^4 - 2 x^2 + 1])/(2 x (x^2 + x - 1)), {x, 0, 43}], x] (* Michael De Vlieger, Dec 16 2019 *)
PROG
(PARI) Vec((1 - x - x^2 - x^3 + x^4 + x^5 - (1+x)*sqrt(x^8-2*x^6-x^4-2*x^2+1+O(x^40)))/(2*x*(x^2+x-1))) \\ Andrew Howroyd, Dec 20 2019
CROSSREFS
KEYWORD
nonn,walk
AUTHOR
Valerie Roitner, Dec 16 2019
STATUS
approved