login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A167486 Choose the prime sum of pair (n,n+1) otherwise choose n (see comments for details). 0
3, 7, 11, 7, 17, 10, 23, 13, 29, 16, 17, 37, 41, 22, 47, 25, 53, 28, 59, 31, 32, 67, 71, 37, 38, 79, 83, 43, 89, 46, 47, 97, 101, 52, 107, 55, 113, 58, 59, 60, 61, 62, 127, 131, 67, 137, 70, 71, 72, 73, 149, 76, 77, 157, 80, 163, 167, 85, 173, 88, 179, 91, 92, 93, 94, 191 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
COMMENTS
We start with the sequence of natural numbers A000027:
1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,...
Consider the first pair (1,2), it sums to prime, 3, hence a(1)=3, and we consider the next pair (3,4), again 3+4=7 is prime hence a(2)=7; and also, 5+6=11 is prime hence a(3)=11; now the next pair (7,8) sums to 15 which is not prime, hence a(4)=7, and next pair under consideration is (8,9) which gives a(5)=8+9=17; 10+11 is not pair hence a(6)=10; 11+12=23 is prime hence a(7)=23, etc.
In short, if the current pair sums to prime we take this sum as the next term of the sequence, otherwise the lesser member of pair is taken as the next term of the sequence.
LINKS
MATHEMATICA
n=1; s=Reap[Do[If[PrimeQ[p=2n+1], b=p; n=n+2, b=n; n=n+1]; Sow[b], {20}]][[2, 1]]
CROSSREFS
Sequence in context: A093931 A335980 A153788 * A260408 A261103 A262505
KEYWORD
nonn
AUTHOR
Zak Seidov, Nov 04 2009
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified March 28 13:42 EDT 2024. Contains 371254 sequences. (Running on oeis4.)