login
3 and -3 are both 4th powers (one implies other) mod these primes p=1 mod 8.
3

%I #23 May 02 2024 17:33:11

%S 193,313,433,577,601,673,769,937,1201,1297,1321,1657,1801,1993,2137,

%T 2473,2521,2593,2833,2953,3169,3529,3673,3697,3769,3889,4057,4129,

%U 4153,4297,4441,4513,4561,4801,4969,5113,5209,5233,5281,5449,5521

%N 3 and -3 are both 4th powers (one implies other) mod these primes p=1 mod 8.

%H Robert Israel, <a href="/A014755/b014755.txt">Table of n, a(n) for n = 1..10000</a>

%p filter:= proc(p) isprime(p) and [msolve(x^4=3, p)] <> [] end proc:

%p select(filter, [seq(i,i=1..10^4, 8)]); # _Robert Israel_, May 07 2019

%t okQ[p_] := PrimeQ[p] && Solve[x^4 == 3, x, Modulus -> p] != {};

%t Select[Range[1, 10000, 8], okQ] (* _Jean-François Alcover_, Feb 08 2023 *)

%o (PARI) forprime(p=1,9999,p%8==1&&ispower(Mod(3,p),4)&&print1(p",")) \\ _M. F. Hasler_, Feb 18 2014

%o (PARI) is_A014755(p)={p%8==1&&ispower(Mod(3,p),4)&&isprime(p)} \\ _M. F. Hasler_, Feb 18 2014

%o (Python)

%o from itertools import count, islice

%o from sympy import nextprime, is_nthpow_residue

%o def A014755_gen(startvalue=2): # generator of terms >= startvalue

%o p = max(nextprime(startvalue-1),2)

%o while True:

%o if p&7==1 and is_nthpow_residue(3,4,p) and is_nthpow_residue(-3,4,p):

%o yield p

%o p = nextprime(p)

%o A014755_list = list(islice(A014755_gen(),20)) # _Chai Wah Wu_, May 02 2024

%Y Cf. A007519.

%K nonn

%O 1,1

%A _Warren D. Smith_

%E Offset changed from 0 to 1 by _Bruno Berselli_, Feb 20 2014