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

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A088556 Numbers of the form (4^n + 4^(n-1) + ... + 1) + (n mod 2). 2
6, 21, 86, 341, 1366, 5461, 21846, 87381, 349526, 1398101, 5592406, 22369621, 89478486, 357913941, 1431655766, 5726623061, 22906492246, 91625968981, 366503875926, 1466015503701, 5864062014806, 23456248059221, 93824992236886, 375299968947541, 1501199875790166 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

LINKS

Colin Barker, Table of n, a(n) for n = 1..1000

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

FORMULA

If n is even, then 4^n + ... + 1 = (4^(n+1) - 1)/3 = (2^(n+1) - 1)(2^n+1) + 1)/3. - R. K. Guy, Nov 17 2003

a(n) = 4*a(n-1) + a(n-2) - 4*a(n-3). -  Colin Barker, Apr 02 2012

G.f.: x*(6-3*x-4*x^2) / ((1-x)*(1+x)*(1-4*x)). -  Colin Barker, Apr 02 2012

MATHEMATICA

LinearRecurrence[{4, 1, -4}, {6, 21, 86}, 50] (* Vincenzo Librandi, Jun 14 2015 *)

PROG

(PARI) trajpolypn(n1) = { for(x1=1, n1, y1 = polypn(4, x1); print1(y1", ") ) }

polypn(n, p) = { x=n; if(p%2, y=2, y=1); for(m=1, p, y=y+x^m; ); return(y) }

(PARI) Vec(x*(6-3*x-4*x^2)/((1-x)*(1+x)*(1-4*x)) + O(x^30)) \\ Colin Barker, Jun 13 2015

(MAGMA) I:=[6, 21, 86]; [n le 3 select I[n] else 4*Self(n-1)+Self(n-2)-4*Self(n-3): n in [1..30]]; // Vincenzo Librandi, Jun 14 2015

CROSSREFS

Sequence in context: A219596 A182251 A191597 * A316105 A137966 A304187

Adjacent sequences:  A088553 A088554 A088555 * A088557 A088558 A088559

KEYWORD

nonn,easy

AUTHOR

Cino Hilliard, Nov 17 2003

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 October 15 09:22 EDT 2019. Contains 328026 sequences. (Running on oeis4.)