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”).

A154485
a(n+1)-+a(n)=prime,a(1)=0,a(2)=3.
12
0, 3, 8, 11, 18, 23, 30, 37, 42, 47, 50, 53, 56, 75, 82, 85, 88, 91, 102, 109, 114, 119, 122, 129, 134, 137, 140, 143, 150, 157, 160, 171, 176, 183, 190, 193, 196, 201, 208, 211, 222, 227, 230, 233, 246, 253, 256, 267, 274, 297, 302, 305, 308, 311, 330, 343, 348
OFFSET
1,2
COMMENTS
Sum and difference of any of two consecutive numbers in current sequence are prime numbers : 8-3=5;8+3=11, 11-8=3;11+8=19, 18-11=7;18+11=29,...
MATHEMATICA
a=0; b=3; lst={a, b}; Do[If[PrimeQ[n-b]&&PrimeQ[n+b], AppendTo[lst, n]; a=b; b=n], {n, b+1, 7!}]; lst
CROSSREFS
Sequence in context: A262290 A184925 A294478 * A105410 A114548 A182759
KEYWORD
nonn
AUTHOR
EXTENSIONS
NAME adapted to offset. - R. J. Mathar, Jun 19 2021
STATUS
approved