login
A374835
Number of ternary paths of length 3*n having exactly 1 hill.
1
0, 1, 0, 4, 14, 72, 370, 1995, 11064, 62774, 362614, 2125479, 12610410, 75584363, 457000668, 2783991972, 17071362986, 105287143740, 652687596388, 4064618917998, 25416557913498, 159523021737403, 1004594882114020, 6345859437931884, 40198433775513524
OFFSET
0,4
LINKS
Naiomi Cameron and J. E. McLeod, Returns and Hills on Generalized Dyck Paths, Journal of Integer Sequences, Vol. 19, 2016, #16.6.1.
FORMULA
a(n) = Sum_{k=0..n-1} (-1)^k * (k+1)*(k+2)/(2*n-k) * binomial(3*n-2-2*k,n-1-k).
G.f.: x * (g/(1 + x*g))^2, where g = 1 + x*g^3.
PROG
(PARI) a(n) = sum(k=0, n-1, (-1)^k*(k+1)*(k+2)/(2*n-k)*binomial(3*n-2-2*k, n-1-k));
CROSSREFS
Column k=1 of A101371.
Sequence in context: A322700 A167144 A159483 * A088127 A242739 A007282
KEYWORD
nonn
AUTHOR
Seiichi Manyama, Jul 21 2024
STATUS
approved