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

 

Logo

Annual appeal: Please make a donation to keep the OEIS running! Over 6000 articles have referenced us, often saying "we discovered this result with the help of the OEIS".
Other ways to donate

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A168273 a(n) = 2*n + (-1)^n - 1. 6
0, 4, 4, 8, 8, 12, 12, 16, 16, 20, 20, 24, 24, 28, 28, 32, 32, 36, 36, 40, 40, 44, 44, 48, 48, 52, 52, 56, 56, 60, 60, 64, 64, 68, 68, 72, 72, 76, 76, 80, 80, 84, 84, 88, 88, 92, 92, 96, 96, 100, 100, 104, 104, 108, 108, 112, 112, 116, 116, 120, 120, 124, 124, 128, 128, 132 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,2

LINKS

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

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

FORMULA

From  R. J. Mathar, Jan 05 2011: (Start)

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

a(n) = 2*A052928(n).

a(n) = A008586(floor(n/2)). (End)

a(n) = 2*n - 2*(n mod 2). - Wesley Ivan Hurt, Jun 30 2013

E.g.f.: (1 + (2*x - 1)*exp(2*x))*exp(-x). - G. C. Greubel, Jul 16 2016

MATHEMATICA

CoefficientList[Series[4 x / ((1+x) (1-x)^2), {x, 0, 70}], x] (* Vincenzo Librandi, May 14 2013 *)

LinearRecurrence[{1, 1, -1}, {0, 4, 4}, 50] (* G. C. Greubel, Jul 16 2016 *)

PROG

(MAGMA) [2*n-1 + (-1)^n: n in [1..70]] // Vincenzo Librandi, May 14 2013

(PARI) a(n)=2*n-1+(-1)^n \\ Charles R Greathouse IV, Oct 07 2015

CROSSREFS

Cf. A052928, A008586.

Sequence in context: A053249 A071339 A146890 * A278933 A145447 A204989

Adjacent sequences:  A168270 A168271 A168272 * A168274 A168275 A168276

KEYWORD

nonn,easy

AUTHOR

Vincenzo Librandi, Nov 22 2009

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 | More pages
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy .

Last modified November 20 10:48 EST 2017. Contains 294963 sequences.