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.

A335361 Prime numbers p such that p!*i + 1 is composite for i = 1..p.

Original entry on oeis.org

67, 157, 269, 379, 419, 443, 449, 509, 541, 577, 743, 769, 859, 863, 929, 937, 1009, 1087, 1163, 1213, 1217, 1367, 1381, 1481, 1579, 1733, 1747, 1753, 1783, 1787, 1877, 1901, 1997, 2153
Offset: 1

Views

Author

Chai Wah Wu, Jun 10 2020

Keywords

Comments

Primes in A335233.

Crossrefs

Programs

  • Mathematica
    Select[Prime@ Range@ 100, (f = #!; NoneTrue[f*Range[#] + 1, PrimeQ ]) &] (* Robert Price, Sep 14 2020 *)
  • PARI
    is(p) = if(isprime(p), for(i=1, p, if(ispseudoprime(i*p!+1), return(0))); 1, 0); \\ Jinyuan Wang, Jun 21 2020
  • Python
    from sympy import isprime, nextprime, factorial
    A335361_list, p = [], 2
    while p < 500:
        f, g = factorial(p), 1
        for i in range(1,p+1):
            g += f
            if isprime(g):
                break
        else:
            A335361_list.append(p)
        p = nextprime(p)
    

Extensions

a(34) from Jinyuan Wang, Jun 21 2020