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

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A278907 a(n) = floor((n*2^(n+1)+2)/(2*n-(-1)^n+3)) - floor((n*2^(n+1)-2)/(2*n-(-1)^n+3)). 1
2, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 1, 1, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 0, 0, 1, 1, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 1 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,1

COMMENTS

If a(n) = b(n) - c(n), then

b(n) = 1, 1, 3, 5, 13, 23, 55, 99, 227, 419, 931, 1733, 3781, 7099, 15291, 28913, 61681, 117275, 248347, 474355, 998643, 1914791, 4011943, 7717519, 16106127, 31068918, 64623350, 124961333, 259179061, 502234079, 1039104991, ...

c(n) = -1, 0, 2, 4, 12, 22, 54, 99, 227, 418, 930, 1732, 3780, 7099, 15291, 28912, 61680, 117274, 248346, 474355, 998643, 1914790, 4011942, 7717519, 16106127, 31068918, 64623350, 124961332, 259179060, 502234078, 1039104990, ...

LINKS

G. C. Greubel, Table of n, a(n) for n = 0..1000

EXAMPLE

a(0) = b(0) - c(0) = 1 - (-1) = 2,

a(1) = b(1) - c(1) = 1 - 0 = 1,

a(2) = b(2) - c(2) = 3 - 2 = 1.

MATHEMATICA

a[n_] := Floor[(n*2^(n + 1) + 2)/(2*n - (-1)^n + 3)] - Floor[(n*2^(n + 1) - 2)/(2*n - (-1)^n + 3)]; Table[a[n], {n, 1, 50}] (* G. C. Greubel, Apr 20 2017 *)

PROG

(MAGMA) [((n*2^(n+1)+2) div (2*n-(-1)^n+3))-((n*2^(n+1)-2) div (2*n-(-1)^n+3)): n in [0..100]];

(PARI) for(n=0, 50, print1(floor((n*2^(n+1)+2)/(2*n-(-1)^n+3)) - floor((n*2^(n+1)-2)/(2*n-(-1)^n+3)), ", ")) \\ G. C. Greubel, Apr 20 2017

CROSSREFS

Cf. A002064 (Cullen numbers).

Sequence in context: A316864 A037820 A076493 * A037910 A162781 A056975

Adjacent sequences:  A278904 A278905 A278906 * A278908 A278909 A278910

KEYWORD

nonn,less

AUTHOR

Juri-Stepan Gerasimov, Nov 30 2016

EXTENSIONS

Definition corrected by R. J. Mathar, Dec 02 2016

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 20:04 EDT 2019. Contains 328037 sequences. (Running on oeis4.)