A070179 Primes p such that x^2 = 2 has a solution mod p, but x^(2^2) = 2 has no solution mod p.
17, 41, 97, 137, 193, 241, 313, 401, 409, 433, 449, 457, 521, 569, 641, 673, 761, 769, 809, 857, 929, 953, 977, 1009, 1129, 1297, 1321, 1361, 1409, 1489, 1657, 1697, 1873, 1993, 2017, 2081, 2137, 2153, 2161, 2297, 2377, 2417, 2521, 2609, 2617, 2633, 2713
Offset: 1
Links
- Bruno Berselli, Table of n, a(n) for n = 1..1000
Programs
-
Magma
[p: p in PrimesUpTo(3000) | not exists{x: x in ResidueClassRing(p) | x^4 eq 2} and exists{x: x in ResidueClassRing(p) | x^2 eq 2}]; // Vincenzo Librandi, Sep 21 2012
-
Maple
select(p -> isprime(p) and 2 &^((p-1)/4) mod p = p-1, [8*k+1$k=1..10000]); # Robert Israel, Jul 06 2014
-
PARI
forprime(p=2,2720,x=0; while(x
-
PARI
{a(n) = local(m, c, x); if( n<1, 0, c = 0; m = 1; while( c
Michael Somos, Mar 22 2008 */ -
PARI
ok(p, r, k1, k2)={ if ( Mod(r,p)^((p-1)/gcd(k1,p-1))!=1, return(0) ); if ( Mod(r,p)^((p-1)/gcd(k2,p-1))==1, return(0) ); return(1); } forprime(p=2,10^4, if (ok(p,2,2,2^2),print1(p,", "))); /* Joerg Arndt, Sep 21 2012 */
-
PARI
is(n)=n%8==1 && Mod(2,n)^(n\4)==-1 && isprime(n) \\ Charles R Greathouse IV, Nov 10 2017
Formula
Primes of the form 8*k + 1 but not x^2 + 64*y^2. - Michael Somos, Mar 22 2008
a(n) ~ 8n log n. - Charles R Greathouse IV, Nov 10 2017
Comments