cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A241857 Number of primes p less than prime(n)-1, such that adding prime(n)-1 and p in binary does not require any carry.

This page as a plain text file.
%I A241857 #20 Mar 14 2020 15:29:55
%S A241857 0,0,2,0,1,2,6,2,0,2,0,5,7,2,1,3,1,2,8,2,9,1,4,5,11,5,1,2,4,6,0,14,16,
%T A241857 7,9,3,4,6,3,6,3,5,0,18,8,2,4,0,4,5,7,1,6,1,54,10,15,5,16,18,7,14,6,3,
%U A241857 10,5,6,16,2,4,17,2,1,6,1,0,15,8,19,10,6,9
%N A241857 Number of primes p less than prime(n)-1, such that adding prime(n)-1 and p in binary does not require any carry.
%C A241857 Or the number of primes less than prime(n)-1, such that
%C A241857 A000120(prime(n)+p-1) = A000120(p) + A000120(prime(n)-1).
%H A241857 Peter J. C. Moses, <a href="/A241857/b241857.txt">Table of n, a(n) for n = 1..1000</a>
%F A241857 For Mersenne prime(n), a(n)=0; for Fermat prime(n)>3, a(n)= n-1.
%e A241857 Let n=12. Prime(12)-1=37-1=36. There are only 5 primes less than 36 the adding of which with 36 does not require any carry: 2,3,11,17,19. So a(12)=5.
%o A241857 (Sage)
%o A241857 def count(x):
%o A241857     c = 0
%o A241857     for y in prime_range(x):
%o A241857         if binomial(y+x-1,y) % 2:
%o A241857             c += 1
%o A241857     return c
%o A241857 [count(i) for i in primes_first_n(100)] # - _Tom Edgar_, May 01 2014
%Y A241857 Cf. A241756, A241758.
%K A241857 nonn
%O A241857 1,3
%A A241857 _Vladimir Shevelev_, Apr 30 2014
%E A241857 More terms from _Peter J. C. Moses_, Apr 30 2014