This site is supported by donations to The OEIS Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A210448 Total number of different letters summed over all ternary words of length n. 3
 0, 3, 15, 57, 195, 633, 1995, 6177, 18915, 57513, 174075, 525297, 1582035, 4758393, 14299755, 42948417, 128943555, 387027273, 1161475035, 3485211537, 10457207475, 31374768153, 94130595915, 282404370657, 847238277795, 2541765165033, 7625396158395, 22876389801777, 68629572058515 (list; graph; refs; listen; history; text; internal format)
 OFFSET 0,2 COMMENTS These are the numbers d(n,3) studied by J. L. Martin. - N. J. A. Sloane, Sep 13 2014 For n >= 0, the number of ternary sequences of length n+1, that contain at least one pair of same consecutive digits. - Armend Shabani, Apr 10 2019 LINKS Philippe Flajolet and Robert Sedgewick, Combinatorial Parameters and MGFs, lecture slides Analytic Combinatorics, 2012 J. L. Martin, The slopes determined by n points in the plane. Martin, Jeremy L. The slopes determined by n points in the plane arXiv:math/0302106 [math.AG], 2003-2006; Duke Math. J. 131 (2006), no. 1, 119-165. See table of d(n,k), but beware errors. Index entries for linear recurrences with constant coefficients, signature (5,-6). FORMULA E.g.f.: 3*exp(3x) - 3*exp(2x).   See Mathematica code for a more transparent version of the e.g.f.   Generally for an m-ary word of length n: m*exp(m*x) - m*exp((m-1)*x) From Alois P. Heinz, Jan 20 2013: (Start) a(n) = 3*(3^n-2^n) = 3*A001047(n). G.f.: 3*x/((3*x-1)*(2*x-1)). (End) a(n) = A217764(n,5). - Ross La Haye, Mar 27 2013 EXAMPLE a(2) = 15 because the length 2 words on alphabet {0,1,2} are: 00, 01, 02, 10, 11, 12, 20, 21, 22 and we sum respectively 1 + 2 + 2 + 2 + 1 + 2 + 2 + 2 + 1 = 15. MAPLE a:= n-> 3*(3^n-2^n): seq(a(n), n=0..30);  # Alois P. Heinz, Jan 20 2013 MATHEMATICA nn=28; Range[0, nn]!CoefficientList[Series[D[(1+y(Exp[x]-1))^3, y]/.y->1, {x, 0, nn}], x] (* Second program: *) LinearRecurrence[{5, -6}, {0, 3}, 30] (* Jean-François Alcover, Jan 09 2019 *) CROSSREFS Cf. A000918, A001047, A217764. A diagonal of the triangle in A079268. Sequence in context: A049187 A049161 A118048 * A284699 A218657 A218804 Adjacent sequences:  A210445 A210446 A210447 * A210449 A210450 A210451 KEYWORD nonn,easy AUTHOR Geoffrey Critzer, Jan 20 2013 STATUS approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

Last modified September 16 18:24 EDT 2019. Contains 327116 sequences. (Running on oeis4.)