OFFSET
1,1
COMMENTS
This sequence is similar to A128825, but also includes 2, and omits numbers like 20759 (see Example), which is a Sophie Germain prime in the interior of a run of more than two consecutive primes that are Sophie Germain primes.
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
EXAMPLE
2 is a Sophie Germain prime (since 2*2 + 1 = 5 is prime), 3 is a Sophie Germain prime (since 2*3 + 1 = 7 is prime), and 2 and 3 are consecutive primes, so 2 is a term of the sequence.
23 and 29 are consecutive primes, and both 23*2 + 1 = 47 and 29*2 + 1 = 59 are primes, so 23 is a term.
The three consecutive primes 20753, 20759, and 20771 are all Sophie Germain primes, and the primes immediately before 20753 and immediately after 20771 are not Sophie Germain primes, so {20753, 20759, 20771} forms a run of three consecutive primes that are Sophie Germain primes; 20753 is at the start of the run, so it is a term, but 20759 is not at the start of the run, so it is not a term.
MAPLE
P:= [seq(ithprime(i), i=1..10000)]:
SG:= map(t -> isprime(2*t+1), P):
P[select(j -> j=1 or SG[j-1..j+1]=[false, true, true], [$1..9999])]; # Robert Israel, Apr 28 2021
MATHEMATICA
Select[Prime@Range@3000, And@@PrimeQ[{2#+1, 2NextPrime@#+1}]&] (* Giorgos Kalogeropoulos, Apr 28 2021 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Jon E. Schoenfield, Apr 24 2021
STATUS
approved