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.

A141305 Primes p such that q=(p-1)/2 is also prime and 2 is a primitive root mod q; that is, q is in A001122.

Original entry on oeis.org

7, 11, 23, 59, 107, 167, 263, 347, 359, 587, 839, 887, 983, 1019, 1307, 1319, 2039, 2459, 2903, 2999, 3467, 3803, 3863, 3947, 4139, 4283, 4679, 4919, 5099, 5387, 5399, 5483, 5639, 5879, 5927, 6599, 6827, 6983, 7079, 7559, 7607, 7703, 8039, 8699, 8747
Offset: 1

Views

Author

T. D. Noe, Jun 24 2008

Keywords

Comments

These primes are a subset of the safe primes, A005385. These primes produce the longest possible cycles, (p-3)/2, in the squaring mod p map. See A037178.

Crossrefs

Programs

  • Mathematica
    Select[Range[10^4], PrimeQ[#] && PrimeQ[(q = (# - 1)/2)] && PrimitiveRoot[q] == 2 &] (* Amiram Eldar, Oct 09 2021 *)
  • PARI
    isok(p) = isprime(p) && (p%2) && isprime(q=(p-1)/2) && (q%2) && (znorder(Mod(2, q))==(q-1)); \\ Michel Marcus, Jan 30 2016

Extensions

Incorrect term 5 removed by Michel Marcus, Jan 30 2016