OFFSET
1,1
COMMENTS
The corresponding primes p are 5, 41, 1301, 2381, 26681, 38921, 47741, 110921, 134681, ... and are in A001359 (lesser of twin primes).
Property of the sequence: the primes p > 5 are congruent to 41 mod 180 => a(n)^2 == 9, 81 mod 180 for n>1.
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
EXAMPLE
3 is in the sequence because 3^2 + 1 = 2*5 and 2 + 5 = 7 is prime.
MAPLE
with(numtheory):
for n from 1 by 2 to 8000 do:
p:=n^2+1:
if isprime(p/2) and isprime(p/2+2)
then
printf(`%d, `, n):
else
fi:
od:
MATHEMATICA
Select[Range[7500], AllTrue[(#^2+1)/2+{0, 2}, PrimeQ]&] (* Harvey P. Dale, Apr 09 2023 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Michel Lagneau, Aug 24 2015
STATUS
approved