login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A329666 Number of excursions of length n with Motzkin-steps avoiding the consecutive steps UU and HH. 6
1, 1, 1, 3, 4, 7, 15, 26, 50, 102, 196, 392, 800, 1609, 3290, 6786, 13973, 28998, 60469, 126295, 264945, 557594, 1176004, 2487485, 5274110, 11204631, 23854581, 50881939, 108715072, 232671125, 498724913, 1070525053, 2301048452, 4952319218, 10671175097, 23020363339 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,4
COMMENTS
The Motzkin step set is U=(1,1), H=(1,0) and D=(1,-1). An excursion is a path starting at (0,0), ending on the x-axis and never crossing the x-axis, i.e., staying at nonnegative altitude.
a(n) also counts excursions avoiding the consecutive steps HH and DD. This can easily be seen by time reversal.
a(n) also counts excursions avoiding the consecutive steps HH and DU.
LINKS
FORMULA
G.f.: (1/2)*(1 - t^3 - t^2 - sqrt(t^6 + 2*t^5 - 3*t^4 - 6*t^3 - 2*t^2 + 1))/t^3.
a(0) = a(1) = a(2) = 1; a(n) = a(n-2) + a(n-3) + Sum_{k=0..n-3} a(k) * a(n-k-3). - Ilya Gutkovskiy, Nov 09 2021
D-finite with recurrence (n+3)*a(n) +2*-n*a(n-2) +3*(-2*n+3)*a(n-3) +3*(-n+3)*a(n-4) +(2*n-9)*a(n-5) +(n-6)*a(n-6)=0. - R. J. Mathar, Jan 25 2023
EXAMPLE
a(3)=3 as there are 3 excursions of length 3, namely: UDH, UHD and HUD.
MATHEMATICA
CoefficientList[Series[(1/2)*(1 - x^3 - x^2 - Sqrt[x^6 + 2*x^5 - 3*x^4 - 6*x^3 - 2*x^2 + 1])/x^3, {x, 0, 40}], x] (* Michael De Vlieger, Oct 24 2023 *)
CROSSREFS
See also A329667, A329668, A329669, which count meanders with the same step set and forbidden consecutive steps "UU and HH", "HH and DU" as well as "HH and DD" respectively.
Sequence in context: A070035 A219277 A024368 * A187493 A027020 A130755
KEYWORD
nonn,walk
AUTHOR
Valerie Roitner, Nov 19 2019
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified June 30 06:39 EDT 2024. Contains 373861 sequences. (Running on oeis4.)