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!)
A266386 Sum over all Motzkin paths of length n of products over all peaks p of (x_p+n*y_p)/y_p, where x_p and y_p are the coordinates of peak p. 2
1, 1, 4, 11, 62, 243, 1575, 7721, 54985, 316407, 2427309, 15798261, 129072167, 927577835, 8008756470, 62499194297, 567017727805, 4747097031375, 45051331382395, 400942371431173, 3965769826314532, 37252002703698003, 382848953452815450, 3774255187367667473 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,3
LINKS
Wikipedia, Motzkin number
FORMULA
a(n) = A258306(n,n).
MAPLE
b:= proc(x, y, t, k) option remember; `if`(y>x or y<0, 0,
`if`(x=0, 1, b(x-1, y-1, false, k)*`if`(t, (x+k*y)/y, 1)
+b(x-1, y, false, k) +b(x-1, y+1, true, k)))
end:
a:= n-> b(n, 0, false, n):
seq(a(n), n=0..30);
MATHEMATICA
b[x_, y_, t_, k_] := b[x, y, t, k] = If[y > x || y < 0, 0, If[x == 0, 1, b[x - 1, y - 1, False, k]*If[t, (x + k*y)/y, 1] + b[x - 1, y, False, k] + b[x - 1, y + 1, True, k]]];
a[n_] := b[n, 0, False, n];
Table[a[n], {n, 0, 30}] (* Jean-François Alcover, Jun 10 2017, translated from Maple *)
CROSSREFS
Main diagonal of A258306.
Sequence in context: A242749 A303955 A114053 * A134823 A000880 A006551
KEYWORD
nonn
AUTHOR
Alois P. Heinz, Dec 28 2015
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 May 9 12:21 EDT 2024. Contains 372350 sequences. (Running on oeis4.)