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!)
A086498 Rearrangement of primes such that every (2n)-th partial sum is a prime. Every (2n+1)-st term is the smallest prime which has not been included earlier. 4
2, 3, 5, 7, 11, 13, 17, 31, 19, 23, 29, 37, 41, 43, 47, 61, 53, 67, 59, 73, 71, 97, 79, 83, 89, 103, 101, 109, 107, 127, 113, 151, 131, 139, 137, 163, 149, 199, 157, 173, 167, 181, 179, 271, 191, 229, 193, 257, 197, 277, 211, 239, 223, 263, 227, 313, 233, 241, 251 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
LINKS
MAPLE
N:= 100: # to get all terms before the first term > Prime(N).
Primes:= [seq(ithprime(i), i=2..N)]: nP:= N-1: S:= 2: R:= 2:
do
found:= false;
for j from 1 to nP do
if isprime(S+Primes[j]) then
R:= R, Primes[j];
S:= S + Primes[j];
Primes:= subsop(j=NULL, Primes);
nP:= nP-1;
found:= true;
break
fi
od;
if not found or nP = 0 then break fi;
R:= R, Primes[1];
S:= S + Primes[1];
Primes:= Primes[2..-1];
nP:= nP-1;
od:
R; # Robert Israel, Aug 04 2020
CROSSREFS
Sequence in context: A103144 A105909 A197187 * A211655 A359138 A061461
KEYWORD
nonn
AUTHOR
Amarnath Murthy, Jul 28 2003
EXTENSIONS
More terms from Ray Chandler, Sep 17 2003
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 April 19 21:09 EDT 2024. Contains 371798 sequences. (Running on oeis4.)