|
|
A007484
|
|
a(n) = 3*a(n-1) + 2*a(n-2), with a(0)=2, a(1)=7.
(Formerly M1767)
|
|
8
|
|
|
2, 7, 25, 89, 317, 1129, 4021, 14321, 51005, 181657, 646981, 2304257, 8206733, 29228713, 104099605, 370756241, 1320467933, 4702916281, 16749684709, 59654886689, 212464029485, 756701861833, 2695033644469, 9598504657073, 34185581260157, 121753753094617
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,1
|
|
COMMENTS
|
Number of subsequences of [1,...,2n+1] in which each even number has an odd neighbor.
Same as Pisot sequence E(2,7) (see A008776).
Conjecture verified using generating functions. - Robert Israel, Jul 12 2018
a(n) = sum of the elements of the matrix M^n, where M = {{1, 2}, {2, 2}}. - Griffin N. Macris, Mar 25 2016
a(3) = 25 is the only composite among the first 8 terms, but then the density of primes decreases, dropping below 50% at the 27th term. - M. F. Hasler, Jul 12 2018
a(n) is also the number of dominating sets in the (2n+1)-triangular snake graph for n > 0. - Eric W. Weisstein, Jun 09 2019
|
|
REFERENCES
|
N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
|
|
LINKS
|
|
|
FORMULA
|
a(n) = nearest integer to (and converges rapidly to) (1+4/sqrt(17))*((3+sqrt(17))/2)^n. - N. J. A. Sloane, Jul 30 2016
If p[i] = Fibonacci(i+2) and if A is the 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-1)= det A. - Milan Janjic, May 08 2010
G.f.: (2 + x)/(1 - 3*x - 2*x^2). - M. F. Hasler, Jul 12 2018
a(n) = (i*sqrt(2))^(n-1)*( i*2*sqrt(2)*ChebyshevU(n, -3*i/(2*sqrt(2))) + ChebyshevU(n-1, -3*i/(2*sqrt(2))) ).
a(n) = Sum_{k=0..floor(n/2)} binomial(n-k, k)*((7*n-8*k)/(n-k))*2^k*3^(n-2*k-1) with a(0) = 2. (End)
If we extend the definition of A007483(m) to negative m by using the recurrence, then a(n) = A007483(-3-n)*(-2)^n holds for all n in Z. - Michael Somos, Jul 19 2021
|
|
EXAMPLE
|
G.f. = 2 + 7*x + 25*x^2 + 89*x^3 + 317*x^4 + 1129*x^5 + ... - Michael Somos, Jul 19 2021
|
|
MAPLE
|
A007484 := proc(n) option remember; if n=0 then 2; elif n=1 then 7; else 3*A007484(n-1)+2*A007484(n-2); fi; end;
|
|
MATHEMATICA
|
LinearRecurrence[{3, 2}, {2, 7}, 40] (* Harvey P. Dale, Apr 24 2012 *)
Table[(2^-n ((3 - Sqrt[17])^n (-4 + Sqrt[17]) + (3 + Sqrt[17])^n (4 + Sqrt[17])))/Sqrt[17], {n, 0, 20}] // Expand (* Eric W. Weisstein, Jun 09 2019 *)
CoefficientList[Series[(2+x)/(1 -3x -2x^2), {x, 0, 20}], x] (* Eric W. Weisstein, Jun 09 2019 *)
a[ n_] := MatrixPower[{{1, 2}, {2, 2}}, n]//Flatten//Total; (* Michael Somos, Jul 19 2021 *)
|
|
PROG
|
(Haskell)
a007484 n = a007484_list !! n
a007484_list = 2 : 7 : zipWith (+)
(map (* 3) $ tail a007484_list) (map (* 2) a007484_list)
(Sage) [(i*sqrt(2))^(n-1)*( i*2*sqrt(2)*chebyshev_U(n, -3*i/(2*sqrt(2))) + chebyshev_U(n-1, -3*i/(2*sqrt(2))) ) for n in (0..30)] # G. C. Greubel, Jul 18 2021
|
|
CROSSREFS
|
See A008776 for definitions of Pisot sequences.
|
|
KEYWORD
|
easy,nonn,nice
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|