OFFSET
1,1
LINKS
Seiichi Manyama, Table of n, a(n) for n = 1..1000
G. Everest et al., Primes generated by recurrence sequences, Amer. Math. Monthly, 114 (No. 5, 2007), 417-431.
Index entries for linear recurrences with constant coefficients, signature (2,2,-2,-1).
FORMULA
G.f.: 2*x*(1+x^2)/((x^2+2*x-1)*(-1+x)*(1+x)).
From Peter Bala, Mar 19 2015: (Start)
a(n) = -det(I - M^n) where I is the 2X2 identity matrix and M = [2, 1; 1, 0]. Cf. A001350.
a(n) = 2*A113224(n-1).
This is divisibility sequence, that is, if n | m then a(n) | a(m).
exp( Sum_{n >= 1} a(n)*x^n/n ) = 1 + 2*Sum_{n >= 1} Pell(n) *x^n. (End)
a(n) = 2*a(n-1) + 2*a(n-2) - 2*a(n-3) - a(n-4) for n > 4. - Seiichi Manyama, Jun 07 2018
MAPLE
u:=1+sqrt(2): v:=1-sqrt(2): a:=n->expand(-(u^n-1)*(v^n-1)): seq(a(n), n=1..33); # Emeric Deutsch, May 13 2007
MATHEMATICA
Table[Simplify[ -((1 + Sqrt[2])^n - 1)*((1 - Sqrt[2])^n - 1)], {n, 1, 30}] (* Stefan Steinerberger, May 15 2007 *)
PROG
(PARI) w = quadgen(8); vector(30, n, -((1+w)^n-1)*((1-w)^n-1)) \\ Michel Marcus, Mar 21 2015
(PARI) Vec(2*x*(1+x^2)/((x^2+2*x-1)*(-1+x)*(1+x))+O(x^99)) \\ Charles R Greathouse IV, Nov 13 2015
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
N. J. A. Sloane, May 13 2007
EXTENSIONS
More terms from Emeric Deutsch and Stefan Steinerberger, May 13 2007
STATUS
approved