The OEIS is supported by the many generous donors to the OEIS Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A087940 a(n) = Sum_{k=0..n} binomial(n+(-1)^k, k). 1
 1, 5, 9, 20, 39, 80, 159, 320, 639, 1280, 2559, 5120, 10239, 20480, 40959, 81920, 163839, 327680, 655359, 1310720, 2621439, 5242880, 10485759, 20971520, 41943039, 83886080, 167772159, 335544320, 671088639, 1342177280, 2684354559, 5368709120, 10737418239 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,2 LINKS Harvey P. Dale, Table of n, a(n) for n = 1..1000 Index entries for linear recurrences with constant coefficients, signature (2,1,-2). FORMULA For n>1 a(n) = 5*2^(n-2)-(1-(-1)^n)/2. From Colin Barker, Jun 26 2013: (Start) For n>4 a(n) = 2*a(n-1)+a(n-2)-2*a(n-3). G.f.: -x*(x^3+2*x^2-3*x-1) / ((x-1)*(x+1)*(2*x-1)). (End) MATHEMATICA Join[{1}, LinearRecurrence[{2, 1, -2}, {5, 9, 20}, 40]] (* Harvey P. Dale, Feb 03 2015 *) PROG (PARI) a(n) = sum(k=0, n, binomial(n+(-1)^k, k)); \\ Michel Marcus, Dec 06 2013 CROSSREFS Cf. A321643 (first differences). Sequence in context: A253951 A102172 A011983 * A092387 A340360 A323110 Adjacent sequences: A087937 A087938 A087939 * A087941 A087942 A087943 KEYWORD nonn,easy AUTHOR Benoit Cloitre, Oct 27 2003 EXTENSIONS Two more terms from Michel Marcus, Dec 06 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 | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

Last modified September 22 11:59 EDT 2023. Contains 365531 sequences. (Running on oeis4.)