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

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A140670 a(n) = 1 if n is odd; otherwise, a(n) = 2^k - 1 where 2^k is the largest power of 2 that divides n. 5
1, 1, 1, 3, 1, 1, 1, 7, 1, 1, 1, 3, 1, 1, 1, 15, 1, 1, 1, 3, 1, 1, 1, 7, 1, 1, 1, 3, 1, 1, 1, 31, 1, 1, 1, 3, 1, 1, 1, 7, 1, 1, 1, 3, 1, 1, 1, 15, 1, 1, 1, 3, 1, 1, 1, 7, 1, 1, 1, 3, 1, 1, 1, 63, 1, 1, 1, 3, 1, 1, 1, 7, 1, 1, 1, 3, 1, 1, 1, 15, 1, 1, 1, 3, 1, 1, 1, 7, 1, 1, 1, 3, 1, 1, 1, 31, 1, 1, 1, 3, 1, 1 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,4

LINKS

Antti Karttunen, Table of n, a(n) for n = 1..16384

FORMULA

a(n) is multiplicative with a(2^e) = 2^e - 1 if e > 0, a(p^e) = 1 if p > 2.

a(2*n + 1) = 1. a(-n) = a(n). a(2*n) = 2 * a(n) + (-1)^n unless n=0.

Dirichlet g.f.: zeta(s)*(1+2^(1-2s)-2^(1-s))/(1-2^(1-s)). - R. J. Mathar, Feb 07 2011

a(n) = (2*A160467(n))-1. - Antti Karttunen, Nov 18 2017

PROG

(PARI) {a(n) = if(n==0, 0, if(n%2, 1, 2^valuation(n, 2) - 1))}

CROSSREFS

Cf. A006519, A135481, A160467.

Sequence in context: A276996 A102480 A157964 * A293682 A276651 A185587

Adjacent sequences:  A140667 A140668 A140669 * A140671 A140672 A140673

KEYWORD

nonn,mult

AUTHOR

Michael Somos, May 21 2008

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