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!)
A258312 Sum over all Motzkin paths of length n of products over all peaks p of x_p/y_p, where x_p and y_p are the coordinates of peak p. 3
1, 1, 2, 5, 14, 43, 141, 490, 1785, 6789, 26809, 109632, 462755, 2012441, 8997402, 41297927, 194306557, 936082502, 4612095475, 23219012907, 119328025012, 625545408219, 3342370197206, 18190297736313, 100768960522871, 567886743369378, 3253833477309093 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,3
LINKS
Wikipedia, Motzkin number
MAPLE
b:= proc(x, y, t) option remember; `if`(y>x or y<0, 0,
`if`(x=0, 1, b(x-1, y-1, false) *`if`(t, x/y, 1)
+b(x-1, y, false)+b(x-1, y+1, true)))
end:
a:= n-> b(n, 0, false):
seq(a(n), n=0..30);
MATHEMATICA
b[x_, y_, t_] := b[x, y, t] = If[y>x || y<0, 0, If[x == 0, 1, b[x-1, y-1, False]*If[t, x/y, 1] + b[x-1, y, False] + b[x-1, y+1, True]]];
a[n_] := b[n, 0, False];
Table[a[n], {n, 0, 30}] (* Jean-François Alcover, Jun 10 2017, translated from Maple *)
CROSSREFS
Column k=0 of A258306 and A258307.
Sequence in context: A029889 A307787 A221586 * A123020 A005317 A126566
KEYWORD
nonn
AUTHOR
Alois P. Heinz, May 25 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 March 19 07:36 EDT 2024. Contains 370957 sequences. (Running on oeis4.)