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.

A109926 Least k such that k-2^r is prime for n values of r. Index of the first occurrence of n in A109925.

Original entry on oeis.org

1, 3, 4, 15, 21, 45, 75, 465, 1095, 2145, 4935, 14955, 80685, 229845, 1295325, 1575285, 9700575, 20435415, 15054105, 53999715, 2282745465
Offset: 0

Views

Author

Amarnath Murthy, Jul 17 2005

Keywords

Comments

It appears that 3 and 5 divide a(n) for n>4. Note that a(18)T. D. Noe, Jul 19 2005
Conjecture: a(n)==0 (mod 3) for n > 2. Then n-2^k is not == 0 (mod 3) and a prime is more probable. - Robert G. Wilson v, Jul 21 2005
Conjecture: a(n+15)==0 (mod 30) for n > 4. - Robert G. Wilson v, Jul 21 2005
a(n) > 10^10 for n >= 21. - Donovan Johnson, Jan 21 2009

Examples

			a(4) = 21, 21-2 =19, 21-4 = 17, 21-8 = 13, 21-16 = 5, 21 is the smallest number that gives four such primes.
		

Crossrefs

Cf. A109925.

Programs

  • Mathematica
    t=Table[cnt=0; r=1; While[rRobert G. Wilson v *)
  • Python
    from itertools import count
    from sympy import isprime
    def A109926(n):
        for m in count(1):
            c = 0
            for k in range(m.bit_length()):
                if isprime(m-(1<n:
                    break
            if c == n:
                return m # Chai Wah Wu, Feb 23 2025

Extensions

Edited, corrected and extended by T. D. Noe and Robert G. Wilson v, Jul 19 2005
a(20) from Donovan Johnson, Jan 21 2009