%I #15 Jan 25 2023 12:39:53
%S 1,1,1,1,2,4,11,31,86,230,608,1588,4151,10925,29083,78373,213702,
%T 588366,1631906,4550346,12736029,35746763,100561622,283486702,
%U 800798659,2266802139,6429960961,18276530005,52051825058,148520257620,424507695627
%N Number of Motzkin excursions of length n with an even number of humps and an even number of peaks.
%C A Motzkin excursion is a lattice path with steps from the set {D=-1, H=0, U=1} that starts at (0,0), never goes below the x-axis, and terminates at the altitude 0.
%C A peak is an occurrence of the pattern UD.
%C A hump is an occurrence of the pattern UHH...HD (the number of Hs in the pattern is not fixed, and can be 0).
%H Andrei Asinowski, Axel Bacher, Cyril Banderier, Bernhard Gittenberger, <a href="https://lipn.univ-paris13.fr/~banderier/Papers/patterns2019.pdf">Analytic combinatorics of lattice paths with forbidden patterns, the vectorial kernel method, and generating functions for pushdown automata</a>, Algorithmica (2019).
%F G.f.: (4*(1-2*t+2*t^2) - sqrt((1-2*t-3*t^2)*(1-t)^2) - sqrt((1-t-4*t^3)*(1-t)^3) - sqrt((1+t^2)*(1-4*t+5*t^2)) - sqrt((1-2*t)*(1-2*t-t^2)*(1-t^2+2*t^3)) ) / (8*t^2*(1-t)).
%F a(n) ~ 3^(n + 3/2) / (8*sqrt(Pi)*n^(3/2)). - _Vaclav Kotesovec_, Jul 03 2019
%F conjecture: a(n)+A325924(n) = A307557(n). - _R. J. Mathar_, Jan 25 2023
%e For n=3 the a(5)=4 paths are HHHHH, UDUDH, UDHUD, HUDUD.
%t CoefficientList[Series[(4 (1 - 2 x + 2 x^2) - Sqrt[(1 - 2 x - 3 x^2) (1 - x)^2] - Sqrt[(1 - x - 4 x^3) (1 - x)^3] - Sqrt[(1 + x^2) (1 - 4 x + 5 x^2)] - Sqrt[(1 - 2 x) (1 - 2 x - x^2) (1 - x^2 + 2 x^3)]) / (8 x^2 (1 - x)), {x, 0, 30}], x] (* _Vincenzo Librandi_, Jun 30 2019 *)
%Y Cf. A325921.
%K nonn
%O 0,5
%A _Andrei Asinowski_, Jun 27 2019
|