login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A270191
Numbers n for which (prime(n+1)-prime(n)) mod 3 = 1.
5
1, 4, 6, 8, 12, 14, 19, 22, 25, 27, 29, 31, 34, 38, 42, 44, 48, 50, 53, 59, 61, 63, 65, 68, 70, 75, 78, 80, 82, 85, 88, 90, 93, 95, 101, 106, 112, 115, 117, 122, 125, 127, 131, 134, 136, 138, 141, 143, 145, 147, 149, 151, 153, 155, 157, 159, 163, 169, 172, 175, 177, 181, 183, 189, 191, 193, 198, 204, 207, 211, 213, 217, 222
OFFSET
1,2
LINKS
EXAMPLE
1 is present as prime(2)-prime(1) = 3-2 = 1 = 1 mod 3.
4 is present as prime(5)-prime(4) = 11-7 = 4 = 1 mod 3.
MATHEMATICA
Select[Range@ 222, Mod[Prime[# + 1] - Prime@ #, 3] == 1 &] (* Michael De Vlieger, Mar 17 2016 *)
PROG
(Scheme, with Antti Karttunen's IntSeq-library)
(define A270191 (MATCHING-POS 1 1 (lambda (n) (= 1 (A137264 n)))))
(PARI) isok(n) = ((prime(n+1) - prime(n)) % 3) == 1; \\ Michel Marcus, Mar 17 2016
CROSSREFS
Subsequence of A270189.
Positions of ones in A137264.
Sequence in context: A141096 A089257 A113451 * A029709 A046458 A096629
KEYWORD
nonn
AUTHOR
Antti Karttunen, Mar 16 2016
STATUS
approved