OFFSET
2,1
EXAMPLE
2 is in this sequence because A005117(2+1) - A005117(2-1) = 3 - 1 = 2, where A005117(2) = 2 is prime for k = 2.
3 is in this sequence because A005117(3+1) - A005117(3-1) = 5 - 2 = 3, where A005117(3) = 3 is prime for k = 3.
7 is in this sequence because A005117(6+1) - A005117(6-1) = 10 - 6 = 4, where A005117(6) = 7 is prime for k = 6.
47 is in this sequence because A005117(31+1) - A005117(31-1) = 51 - 46 = 5, where A005117(31) = 47 is prime for k = 31.
97 is in this sequence because A005117(61+1) - A005117(61-1) = 101 - 95 = 6, where A005117(61) = 97 is prime for k = 61.
MATHEMATICA
s = Select[Range[10^6], SquareFreeQ]; Table[k = 1; While[Nand[PrimeQ@ Set[p, s[[k]]], s[[k + 1]] - s[[k - 1]] == n], k++]; p, {n, 2, 10}] (* Michael De Vlieger, Mar 18 2017 *)
CROSSREFS
KEYWORD
nonn,more
AUTHOR
Juri-Stepan Gerasimov, Mar 17 2017
EXTENSIONS
a(10) from Michael De Vlieger, Mar 18 2017
a(11)-a(15) from Giovanni Resta, Mar 22 2017
STATUS
approved