|
|
A002535
|
|
a(n) = 2*a(n-1) + 9*a(n-2), with a(0)=a(1)=1.
(Formerly M4786 N2043)
|
|
11
|
|
|
1, 1, 11, 31, 161, 601, 2651, 10711, 45281, 186961, 781451, 3245551, 13524161, 56258281, 234234011, 974792551, 4057691201, 16888515361, 70296251531, 292589141311, 1217844546401, 5068991364601, 21098583646811, 87818089575031, 365523431971361, 1521409670118001, 6332530227978251
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,3
|
|
COMMENTS
|
Binomial transform of [1, 0, 10, 0, 100, 0, 1000, 0, 10000, 0, ...]=: powers of 10 (A011557) with interpolated zeros. Inverse binomial transform of A084132. - Philippe Deléham, Dec 02 2008
a(n) is the number of compositions of n when there are 1 type of 1 and 10 types of other natural numbers. - Milan Janjic, Aug 13 2010
|
|
REFERENCES
|
N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
A. Tarn, Approximations to certain square roots and the series of numbers connected therewith, Mathematical Questions and Solutions from the Educational Times, 1 (1916), 8-12.
|
|
LINKS
|
|
|
FORMULA
|
a(n) = ((1+sqrt(10))^n + (1-sqrt(10))^n)/2.
G.f.: (1-x)/(1-2*x-9*x^2).
E.g.f.: exp(x)*cosh(sqrt(10)*x). (End)
If p[1]=1, and p[i]=10,(i>1), and if A is Hessenberg matrix of order n defined by: A[i,j]=p[j-i+1], (i<=j), A [i,j]=-1, (i=j+1), and A[i,j]=0 otherwise. Then, for n>=1, a(n)=det A. - Milan Janjic, Apr 29 2010
|
|
MAPLE
|
|
|
MATHEMATICA
|
a[n_] := Simplify[((1 + Sqrt[10])^n + (1 - Sqrt[10])^n)/2]; Array[a, 30, 0] (* Or *)
CoefficientList[Series[(1+9x)/(1-2x-9x^2), {x, 0, 30}], x] (* Or *)
|
|
PROG
|
(Magma) [Ceiling((1+Sqrt(10))^n/2+(1-Sqrt(10))^n/2): n in [0..30]]; // Vincenzo Librandi, Aug 15 2011
(Magma) I:=[1, 1]; [n le 2 select I[n] else 2*Self(n-1)+9*Self(n-2): n in [1..30]]; // G. C. Greubel, Aug 02 2019
(PARI) my(x='x+O('x^30)); Vec((1-x)/(1-2*x-9*x^2)) \\ G. C. Greubel, Aug 02 2019
(PARI) my(p=Mod('x, 'x^2-2*'x-9)); a(n) = vecsum(Vec(lift((p^n)))); \\ Kevin Ryde, Jan 28 2023
(Sage) ((1-x)/(1-2*x-9*x^2)).series(x, 30).coefficients(x, sparse=False) # G. C. Greubel, Aug 02 2019
(GAP) a:=[1, 1];; for n in [3..30] do a[n]:=2*a[n-1]+9*a[n-2]; od; a; # G. C. Greubel, Aug 02 2019
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,easy
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|