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!)
A098977 Triangle read by rows: counts ordered trees by number of edges and position of first edge that terminates at a vertex of outdegree 1. 0
1, 1, 1, 2, 2, 1, 4, 5, 3, 2, 9, 14, 9, 6, 4, 21, 42, 28, 19, 13, 9, 51, 132, 90, 62, 43, 30, 21, 127, 429, 297, 207, 145, 102, 72, 51, 323, 1430, 1001, 704, 497, 352, 250, 178, 127, 835, 4862, 3432, 2431, 1727, 1230, 878, 628, 450, 323, 2188, 16796, 11934, 8502 (list; table; graph; refs; listen; history; text; internal format)
OFFSET
1,4
COMMENTS
T(n,k) = number of ordered trees on n edges whose k-th edge (in preorder or "walk around from root" order) is the first one that terminates at a vertex of outdegree 1 (k=0 if there is no such edge). The first column and the main diagonal (after initial entry) are Motzkin numbers (A001006). Each interior entry is the sum of its North and East neighbors.
LINKS
FORMULA
G.f. for column k=0 is (1 - z - (1-2*z-3*z^2)^(1/2))/(2*z^2) = Sum_{n>=1}T(n, 0)z^n. G.f. for columns k>=1 is (t*(1 - (1 - 4*z)^(1/2) - 2*z))/ (1 - t + t*(1 - 4*z)^(1/2) + t*z + (1 - 2*t*z - 3*t^2*z^2)^(1/2)) = Sum_{n>=2, 1<=k<=n-1}T(n, k)z^n*t^k.
EXAMPLE
Table begins
\ k 0, 1, 2, ...
n
1 | 1
2 | 1, 1
3 | 2, 2, 1
4 | 4, 5, 3, 2
5 | 9, 14, 9, 6, 4
6 | 21, 42, 28, 19, 13, 9
7 | 51, 132, 90, 62, 43, 30, 21
8 |127, 429, 297, 207, 145, 102, 72, 51
T(4,2)=3 counts the following ordered trees (drawn down from root).
..|..../\..../|\..
./.\....|.....|...
.|......|.........
MATHEMATICA
Clear[v] MotzkinNumber[n_]/; IntegerQ[n] && n>=0 := If[0<=n<=1, 1, Module[{x = 1, y = 1}, Do[temp = ((2*i + 1)*y + 3*(i - 1)*x)/(i + 2); x = y; y = temp, {i, 2, n}]; y]]; v[n_, 0]/; n>=1 := MotzkinNumber[n-1]; v[n_, k_]/; k>=n := 0; v[n_, k_]/; n>=2 && k==n-1 := MotzkinNumber[n-2]; v[n_, k_]/; n>=3 && 1<=k<=n-2 := v[n, k] = v[n, k+1]+v[n-1, k]; TableForm[Table[v[n, k], {n, 10}, {k, 0, n-1}]]
CROSSREFS
Column k=1 is A000108 (apart from first term), k=2 is A000245, k=3 is A026012.
Sequence in context: A273897 A330792 A063415 * A247311 A113547 A218580
KEYWORD
nonn,tabl
AUTHOR
David Callan, Oct 24 2004
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 April 24 05:36 EDT 2024. Contains 371918 sequences. (Running on oeis4.)