The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A361071 Let c1(p) be the number of primes <= p with an odd number of 1's in base 2, and let c2(p) be the number of primes <= p with an even number of 1's in base 2. a(n) is the least prime p such that abs(c1(p) - c2(p)) >= n. 0
2, 13, 41, 61, 67, 79, 109, 131, 137, 173, 179, 181, 191, 193, 211, 223, 227, 229, 233, 239, 241, 251, 587, 613, 617, 641, 653, 659, 661, 719, 727, 733, 761, 769, 829, 953, 967, 971, 1009, 1021, 1039, 1069, 1087, 1193, 1201, 1213, 1697, 1721, 1753, 1759, 1777, 1783, 1787 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
LINKS
EXAMPLE
a(1) = 2, because c1(2) = 1 and c2(2) = 0, so abs(c1(2) - c2(2)) = 1 >= 1, and no lesser prime satisfies this.
PROG
(PARI) { r = 0; n = 1; forprime (p = 2, 1787, r += (-1)^hammingweight(p); if (n==abs(r), print1 (p", "); n++; ); ); } \\ Rémy Sigrist, Mar 01 2023
CROSSREFS
Sequence in context: A264529 A263979 A042795 * A179925 A263980 A157185
KEYWORD
nonn,base
AUTHOR
Jean-Marc Rebert, Mar 01 2023
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 May 13 07:22 EDT 2024. Contains 372498 sequences. (Running on oeis4.)