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!)
A211298 a(n) = number of n-lettered words in the alphabet {1, 2, 3} with as many occurrences of the substring (consecutive subword) [1, 2, 1] as of [2, 1, 2]. 1
1, 3, 9, 25, 73, 209, 603, 1737, 5013, 14479, 41867, 121181, 351103, 1018259, 2955967, 8589139, 24980429, 72717883, 211867481, 617816561, 1803089251, 5266565421, 15395024547, 45036636735, 131848195503, 386273704299, 1132449675153, 3322275767287, 9752944355363, 28649005746629, 84206904178073 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,2
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, 2011. See subpages for rigorous derivations of g.f., recurrence, asymptotics for this sequence.
MAPLE
a:= proc(n) option remember; `if`(n<8,
[1, 3, 9, 25, 73, 209, 603, 1737][n+1],
((7*n-5)*a(n-1) -(14*n-26)*a(n-2) -(n+24)*a(n-3)
+(29*n-69)*a(n-4) -(20*n-112)*a(n-5) -(20*n-68)*a(n-6)
+(20*n-108)*a(n-7) +(12*n-60)*a(n-8))/n)
end:
seq(a(n), n=0..30); # Alois P. Heinz, Oct 30 2013
MATHEMATICA
a[n_] := a[n] = If[n<8, {1, 3, 9, 25, 73, 209, 603, 1737}[[n+1]], ((7*n-5)*a[n-1] - (14*n-26)*a[n-2] - (n+24)*a[n-3] + (29*n-69)*a[n-4] - (20*n-112)*a[n-5] - (20*n-68)*a[n-6] + (20*n-108)*a[n-7] + (12*n-60)*a[n-8])/n]; Table[a[n], {n, 0, 30}] (* Jean-François Alcover, Mar 07 2014, after Alois P. Heinz *)
CROSSREFS
Sequence in context: A265940 A309104 A211282 * A138574 A101499 A004665
KEYWORD
nonn
AUTHOR
N. J. A. Sloane, Apr 07 2012
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 13:58 EDT 2024. Contains 371960 sequences. (Running on oeis4.)