login
Primes p such that the gap to the next prime is strictly less than floor(log_2(p)).
0

%I #19 Jun 07 2026 01:38:40

%S 11,17,29,37,41,43,59,67,71,79,97,101,103,107,109,127,131,137,149,151,

%T 157,163,167,173,179,191,193,197,223,227,229,233,239,251,257,263,269,

%U 271,277,281,307,311,313,331,347,349,353,367,373,379,383,397,419,431,433,439,443,457,461,463

%N Primes p such that the gap to the next prime is strictly less than floor(log_2(p)).

%C Terms are {p in primes | g < floor(log_2(p)) }, where g is the forward prime gap.

%e For p = 11: next prime is 13; gap = 2, floor(log_2(11)) = 3, 2 < 3 is true, so 11 is included.

%e For p = 13: next prime is 17; gap = 4, floor(log_2(13)) = 3, 4 < 3 is false, so 13 is excluded.

%t Select[Prime[Range[PrimePi[463]]],NextPrime[#]-#<Floor[Log2[#]]&] (* _James C. McMahon_, Jun 06 2026 *)

%o (Python)

%o from sympy import nextprime

%o def A000523(n): return n.bit_length() - 1

%o def sub_dimensional_primes(limit):

%o sub_primes = []

%o p = 11

%o while p < limit:

%o if nextprime(p) - p < A000523(p):

%o sub_primes.append(p)

%o p = nextprime(p)

%o return sub_primes

%o print(sub_dimensional_primes(500))

%Y Cf. A000040 (primes), A000523 (floor(log_2)), A151800 (next prime), A396203, A396279, A396282.

%K nonn

%O 1,1

%A _Sajid Hussain_, May 29 2026