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.

Showing 1-2 of 2 results.

A058302 Primes p such that p | ((p-1)/2)! -1.

Original entry on oeis.org

3, 23, 31, 59, 71, 83, 107, 139, 151, 167, 211, 223, 239, 251, 271, 283, 307, 311, 331, 359, 379, 439, 463, 467, 487, 499, 547, 587, 643, 647, 659, 719, 751, 811, 827, 859, 883, 907, 911, 919, 967, 971, 983, 1031, 1039, 1063, 1103, 1163, 1171, 1223
Offset: 1

Views

Author

Robert G. Wilson v, Dec 08 2000

Keywords

Comments

p | (p-1)! +1 iff p is a prime (Wilson's theorem). All of the above primes are congruent to 3 (mod 4).
Primes p such that p | ((p-3)/2)! +2. - Davide Rotondo, Jun 03 2024

References

  • J. B. Cosgrave, A Mersenne-Wieferich Odyssey, Manuscript, May 2022. See Section 18.5.

Crossrefs

Programs

  • Magma
    [p: p in PrimesInInterval(3,1230) | IsDivisibleBy(Factorial((p-1) div 2)-1, p)];  // Bruno Berselli, Apr 13 2011
  • Mathematica
    Select[ Range[ 1225 ], PrimeQ[ # ] && Mod[ ((# - 1)/2)! - 1, # ] == 0 & ]
    Select[Prime[Range[200]],Divisible[((#-1)/2)!-1,#]&] (* Harvey P. Dale, Aug 29 2022 *)
  • PARI
    forprime(p=3,10^4,if( Mod(((p-1)/2)!,p)==1,print1(p,", "))); /* Joerg Arndt, Apr 12 2011 */
    
  • PARI
    is(p)=isprime(p) && p%4==3 && if(p>9, qfbclassno(-p)%4, p)==3 \\ Charles R Greathouse IV, Nov 04 2013
    

A152217 Primes p == 1 (mod 3) such that ((p-1)/3)! == 1 (mod p).

Original entry on oeis.org

3571, 4219, 13669, 25117, 55897, 89269, 102121, 170647, 231019, 246247, 251431
Offset: 1

Views

Author

Francois Brunault (brunault(AT)gmail.com), Nov 29 2008, Nov 30 2008

Keywords

Comments

The Wilson theorem states that p is prime if and only if (p-1)! = -1 (mod p). If p = 3 (mod 4) then ((p-1)/2)! = +/- 1 (mod p).

Examples

			For n = 1 the prime a(1) = 3571 divides 1190! - 1.
		

References

  • J. B. Cosgrave, A Mersenne-Wieferich Odyssey, Manuscript, May 2022. See Section 18.2.

Crossrefs

Seems to be a subsequence of A002407 and therefore of A003215 (differences of consecutive cubes). See also A058302 and A055939 for the sequences corresponding to ((p-1)/2)! = +/- 1 (mod p).

Programs

  • PARI
    forprime(p=2,30000,if(p%3==1 & ((p-1)/3)!%p==1,print(p)))
Showing 1-2 of 2 results.