A211278 a(n) is the number of n-lettered words in the alphabet {1, 2, 3} with as many occurrences of the substring (consecutive subword) [1, 1] as of [2, 3].
1, 3, 7, 16, 38, 95, 248, 668, 1838, 5131, 14470, 41112, 117475, 337203, 971515, 2807744, 8136090, 23630215, 68768210, 200481036, 585381973, 1711647959, 5011157073, 14687848012, 43095321203, 126565380735, 372030471493, 1094437253428, 3221999290418, 9492019319771, 27981390048004
Offset: 0
Keywords
Links
- Shalosh B. Ekhad and Doron Zeilberger, Automatic Solution of Richard Stanley's Amer. Math. Monthly Problem #11610 and ANY Problem of That Type, arXiv preprint arXiv:1112.6207 [math.CO], 2011. See subpages for rigorous derivations of g.f., recurrence, asymptotics for this sequence.
Programs
-
Maple
gf := (1 + sqrt((1 + x) / (1 - 3*x))) / (1 - x)^2 / 2: A211278 := n -> coeff(series(gf, x, n+1), x, n): seq(A211278(n), n = 0 .. 30); # Mélika Tebni, Mar 20 2025
-
Python
from math import comb as C def a(n): return sum(C(n+1, k+1)*abs(sum((-1)**j*C(k, j) for j in range(k//2+1))) for k in range(n+1)) print([a(n) for n in range(31)]) # Mélika Tebni, Mar 20 2025
Formula
Conjecture: n*a(n) - 4*n*a(n-1) +2*(n+3)*a(n-2) + 4*(n-3)*a(n-3) + 3*(-n+2)*a(n-4) = 0. - R. J. Mathar, Jun 09 2013
From Mélika Tebni, Mar 20 2025: (Start)
G.f.: (1 + sqrt((1 + x) / (1 - 3*x))) / (1 - x)^2 / 2.
a(n) = Sum_{k=0..n} binomial(n+1, k+1)*abs(Sum_{j=0..floor(k/2)} (-1)^j*binomial(k, j)).
E.g.f.: (g(x) + Integral_{x=-oo..oo} g(x) dx)*exp(x) where g(x) = Integral_{x=-oo..oo} BesselI(0, 2*x) dx + (1 + BesselI(0, 2*x)) / 2. (End)
Comments