A072225 Numbers k such that prime(k) + prime(k+1) + prime(k+2) is prime.
3, 4, 5, 7, 8, 9, 10, 11, 13, 16, 18, 19, 20, 22, 23, 26, 29, 34, 35, 37, 38, 45, 47, 50, 58, 60, 61, 62, 64, 68, 69, 70, 75, 77, 79, 80, 83, 87, 88, 90, 91, 94, 95, 97, 101, 113, 116, 119, 120, 121, 126, 128, 132, 133, 134
Offset: 1
Examples
9 is in the sequence because prime(9) + prime(10) + prime(11) = 23 + 29 + 31 = 83 is a prime.
Links
- Robert Israel, Table of n, a(n) for n = 1..10000
- Carlos Rivera, Puzzle 798. A nice puzzle by Kamenetski, The Prime Puzzles & Problems Connection.
Programs
-
Magma
[n: n in [0..600]| IsPrime(NthPrime(n)+NthPrime(n+1)+NthPrime(n+2))]; // Vincenzo Librandi, Apr 06 2011
-
Maple
a:=proc(n) if isprime(ithprime(n)+ithprime(n+1)+ithprime(n+2))=true then n else fi end: seq(a(n),n=1..150); # Emeric Deutsch, Apr 24 2006
-
Mathematica
Select[Range[10^4], PrimeQ[Prime[ # ] + Prime[ # + 1] + Prime[ # + 2]] &]
-
PARI
isok(n)=isprime(prime(n)+prime(n+1)+prime(n+2)) \\ Anders Hellström, Aug 20 2015
Comments