The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A108867 a(1) = 1; a(n) = sum of previous terms a(k) such that a(k) + n is prime. 0

%I #8 Apr 09 2014 10:15:17

%S 1,1,0,2,2,2,0,0,6,2,14,2,6,0,24,2,62,2,24,0,76,2,74,0,88,0,242,2,396,

%T 2,88,0,164,0,1018,2,532,0,1122,2,1462,2,1638,0,1652,2,2348,0,2808,0,

%U 3950,2,7254,0,9560,0,5720,2,18298,2,4292,0,22068,0,28528,2,8194,0,76236,2

%N a(1) = 1; a(n) = sum of previous terms a(k) such that a(k) + n is prime.

%e Among the first 10 terms, a(3)+11, a(4)+11, a(5)+11, a(6)+11, a(7)+11, a(8)+11, a(9)+11 and a(10)+11 are primes. So a(11) = a(3)+a(4)+a(5)+a(6)+a(7)+a(8)+a(9)+a(10) = 14.

%o (PARI) {m=70;v=[1];for(n=2,m,c=0;for(j=1,length(v),if(isprime(v[j]+n),c=c+v[j])); v=concat(v,c));for(j=1,m,print1(v[j],","))}

%K nonn

%O 1,4

%A _Leroy Quet_, Jul 30 2005

%E More terms and PARI code from _Klaus Brockhaus_, Aug 04 2005

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 May 28 04:02 EDT 2024. Contains 372900 sequences. (Running on oeis4.)