A382669 Even numbers m such that both p = m^2 + 1 and q = (p^2 + 1)/2 are primes.
2, 10, 150, 160, 230, 270, 400, 890, 910, 920, 1060, 1430, 1550, 1970, 2700, 2960, 3280, 3290, 3520, 3660, 4140, 4330, 4510, 4700, 4780, 4850, 4920, 5180, 5360, 5500, 5560, 5620, 5880, 5960, 6220, 6460, 6980, 7160, 7190, 7520, 7550, 7820, 9630, 9760, 9900
Offset: 1
Keywords
Examples
10 is a term because both 10^2 + 1 = 101 and (101^2 + 1)/2 = 5101 are primes.
Links
- Robert Israel, Table of n, a(n) for n = 1..10000
Programs
-
Maple
filter:= proc(m) local p; p:= m^2 + 1; isprime(p) and isprime((p^2+1)/2) end proc: select(filter, [2,seq(i,i=10..10000,10)]); # Robert Israel, May 02 2025
-
Mathematica
Select[2*Range[5000], PrimeQ[#^2 + 1] && PrimeQ[#^4/2 + #^2 + 1] &] (* Amiram Eldar, Apr 24 2025 *)
-
Python
from sympy import isprime for n in range(2, 10000, 2): x = n*n + 1; ct = 0; print(n, end = ', ') if isprime(x) and isprime((x*x + 1)//2) else 0
-
Python
from itertools import count, islice from sympy import isprime def A382669_gen(): # generator of terms yield 2 yield from filter(lambda m: isprime(p:=m**2+1) and isprime(p+(m**4>>1)),(10*k for k in count(1))) A382669_list = list(islice(A382669_gen(),45)) # Chai Wah Wu, May 02 2025
Comments