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

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A086341 a(n) = 2*2^floor(n/2) - (-1)^n. 5
1, 3, 3, 5, 7, 9, 15, 17, 31, 33, 63, 65, 127, 129, 255, 257, 511, 513, 1023, 1025, 2047, 2049, 4095, 4097, 8191, 8193, 16383, 16385, 32767, 32769, 65535, 65537, 131071, 131073, 262143, 262145, 524287, 524289, 1048575, 1048577, 2097151, 2097153 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,2
LINKS
FORMULA
E.g.f.: 2*cosh(sqrt(2)*x) + 2*sinh(sqrt(2)*x)/sqrt(2) - sinh(x) + cosh(x).
a(n) = (1 + 1/sqrt(2))*sqrt(2)^n + (1 - 1/sqrt(2))*(-sqrt(2))^n - (-1)^n.
G.f.: (1+2*x)^2/((1+x)*(1-2*x^2)). - Colin Barker, Aug 17 2012
a(n) = a(n-1) + 2*a(n-2) + 2*a(n-3); a(0)=1, a(1)=3, a(2)=3. - Harvey P. Dale, Mar 10 2013
From Amiram Eldar, Sep 14 2022: (Start)
Sum_{n>=0} 1/a(n) = A065442 + A323482 - 1/2.
Sum_{n>=0} (-1)^n/a(n) = 2 * A248721. (End)
MATHEMATICA
CoefficientList[Series[(1+2x)^2/((1+x)(1-2x^2)), {x, 0, 50}], x] (* or *) LinearRecurrence[ {-1, 2, 2}, {1, 3, 3}, 50] (* Harvey P. Dale, Mar 10 2013 *)
PROG
(Magma) [2*2^Floor(n/2)-(-1)^n: n in [0..40]]; // Vincenzo Librandi, Aug 16 2011
(PARI) vector(40, n, n--; 2^(floor(n/2)+1) - (-1)^n) \\ G. C. Greubel, Nov 08 2018
CROSSREFS
Cf. A016116 (2^floor(n/2)).
Sequence in context: A323430 A291941 A355225 * A176513 A128424 A129758
KEYWORD
easy,nonn
AUTHOR
Paul Barry, Jul 16 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 | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified February 27 15:42 EST 2024. Contains 370377 sequences. (Running on oeis4.)