OFFSET
1,1
LINKS
Michel Lagneau, a(n)==54 (mod 100)
FORMULA
For n>1, a(n) == 54 (mod 100) (see proof above).
For n > 1, a(n) mod 400 = 54; a(n) mod 1200 = 54 or 454; a(n) mod 2000 = 54, 454, or 1254; a(n) mod 54, 454, 1254, or 2454. - Jon E. Schoenfield, Feb 04 2022
EXAMPLE
a(3) = 454 because A096012(3) = 14, 14^2+1 = 197, (14+2)^2+1 = 257, and 197 + 257 = 454.
MAPLE
nn:=3000:
for n from 2 by 2 to nn do:
p1:=n^2+1:p2:=(n+2)^2+1:
if isprime(p1) and isprime(p2)
then
s:=p1+p2:printf(`%d, `, s):
else
fi:
od:
MATHEMATICA
f[n_] := 2*n^2 + 4*n + 6; f /@ Select[Range[3000], And @@ PrimeQ[{#^2 + 1, (# + 2)^2 + 1}] &] (* Amiram Eldar, Feb 04 2022 *)
PROG
(PARI) lista(nn) = {for (m=1, nn, if (isprime(m^2+1) && isprime(m^2+4*m+5), print1(2*m^2+4*m+6, ", ")); ); } \\ Michel Marcus, Feb 04 2022
CROSSREFS
KEYWORD
nonn
AUTHOR
Michel Lagneau, Feb 04 2022
STATUS
approved