(MAGMAMagma) [1] cat [9*8^(n-1): n in [1..25]]; // Vincenzo Librandi, Dec 11 2012
(MAGMAMagma) [1] cat [9*8^(n-1): n in [1..25]]; // Vincenzo Librandi, Dec 11 2012
proposed
approved
editing
proposed
GExpansion of g.f.: (1+x)/(1-8*x).
a(n) = Sum_{ 0<=k<=0..n } A029653(n, k)*x^k for x = 7. - Philippe Deléham, Jul 10 2005
E.g.f.: (9*exp(8*x) -1)/8. - G. C. Greubel, Sep 24 2019
k := 9; seq(`if `(n = 0 then , 1 else , k*(k-1)^(n-1); fi), n = 0..25); # modified by _G. C. Greubel_, Sep 24 2019
q = 9; Join[{a = 1}, Table[If[n != 0, a = q*a - a, a = q*a], {n, 0, 25}]] (* and *) Join[{1}, 9*8^Range[0, 25]] (* Vladimir Joseph Stephan Orlovsky, Jul 11 2011 *)
CoefficientList[Series[(1 + x)/(1 - 8*x), {x, 0, 4025}], x] (* Vincenzo Librandi, Dec 10 2012 *)
(MAGMA) [1] cat [9*8^(n-1): n in [1..2025]]; // Vincenzo Librandi, Dec 11 2012
(Sage) k=9; [1]+[k*(k-1)^(n-1) for n in (1..25)] # G. C. Greubel, Sep 24 2019
(GAP) k:=9;; Concatenation([1], List([1..25], n-> k*(k-1)^(n-1) )); # G. C. Greubel, Sep 24 2019
Cf. A003945.
approved
editing
proposed
approved
editing
proposed
For n>=1, a(n) equals the numbers number of words of length n on alphabet {0,1,...,8} with no two adjacent letters identical. - Milan Janjic, Jan 31 2015 [Corrected by David Nacin, May 31 2017]
proposed
editing
editing
proposed
For n>=1, a(n) equals the numbers of words of length n-1 on alphabet {0,1,...,8} with no two adjacent letters identical. - Milan Janjic, Jan 31 2015 [Corrected by _David Nacin_, May 31 2017]
approved
editing
INRIA Algorithms Project, <a href="http://algoecs.inria.fr/ecsservices/ecsstructure?searchType=1&service=Search&searchTermsnbr=310">Encyclopedia of Combinatorial Structures 310</a>