login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A227200 a(n) = a(n-1) + a(n-2) - 2^(n-1) with a(0)=a(2)=0, a(1)=-a(3)=1, a(4)=-5. 1
0, 1, 0, -1, -5, -14, -35, -81, -180, -389, -825, -1726, -3575, -7349, -15020, -30561, -61965, -125294, -252795, -509161, -1024100, -2057549, -4130225, -8284926, -16609455, -33282989, -66669660, -133507081, -267285605, -535010414, -1070731475 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,5

LINKS

Vincenzo Librandi, Table of n, a(n) for n = 0..1000

C. N. Phadte and S. P. Pethe, On Second Order Non-homogeneous recurrence relation, Annales Mathematicae et informaticae, 41 (2013), pp. 205-210.

Index entries for linear recurrences with constant coefficients, signature (3,-1,-2).

FORMULA

G.f.: x*(1-3*x)/((1-2*x)*(1-x-x^2)).

a(n) = -(-1)^n*A142585(n+1) = A000032(n+1) - 2^n. [Bruno Berselli, Oct 03 2013]

a(n) = 3*a(n-1) -a(n-2) -2*a(n-3). [Bruno Berselli, Oct 03 2013]

MATHEMATICA

Table[LucasL[n + 1] - 2^n, {n, 0, 30}] (* Bruno Berselli, Oct 03 2013 *)

CoefficientList[Series[x (1 - 3 x)/((1 - 2 x) (1 - x - x^2)), {x, 0, 40}], x](* Vincenzo Librandi, Oct 05 2013 *)

PROG

(Basic)

LET N=0

LET L=0

LET M=1

PRINT L

PRINT M

FOR I=1 TO 30

LET N=M+L-(2)^(I-1)

PRINT N

LET L=M

LET M=N

NEXT I

END

(MAGMA) m:=30; R<x>:=PowerSeriesRing(Integers(), m); [0] cat Coefficients(R!((1-3*x)/((1-2*x)*(1-x-x^2)))); // Bruno Berselli, Oct 03 2013

(PARI) a(n)=fibonacci(n)+fibonacci(n+2)-2^n \\ Charles R Greathouse IV, Oct 03 2013

(MAGMA) I:=[0, 1, 0, -1, -5]; [n le 5 select I[n] else Self(n-1)+Self(n-2)-2^(n-3): n in [1..35]]; // Vincenzo Librandi, Oct 05 2013

CROSSREFS

Cf. versions with different signs: A027974, A142585.

Cf. A000032, A000045.

Sequence in context: A076858 A001215 A066767 * A027974 A027983 A142585

Adjacent sequences:  A227197 A227198 A227199 * A227201 A227202 A227203

KEYWORD

sign,easy

AUTHOR

Chandrakant N Phadte, Sep 18 2013

EXTENSIONS

More terms from Bruno Berselli, Oct 03 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.

License Agreements, Terms of Use, Privacy Policy. .

Last modified November 20 17:09 EST 2019. Contains 329337 sequences. (Running on oeis4.)