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

Numbers k such that 7 divides prime(1) + ... + prime(k).
11

%I #11 May 14 2024 03:58:55

%S 5,8,13,22,33,40,47,50,56,63,72,84,86,104,106,110,115,126,128,139,148,

%T 150,154,157,160,180,184,186,188,200,209,220,228,230,232,236,238,240,

%U 244,253,270,274,300,302,305,322,324,331,339,354,367,371,384,415,417,420,428,433

%N Numbers k such that 7 divides prime(1) + ... + prime(k).

%H Amiram Eldar, <a href="/A111321/b111321.txt">Table of n, a(n) for n = 1..10000</a> (terms 1..1000 from Harvey P. Dale)

%t Position[Accumulate[Prime[Range[500]]],_?(Divisible[#,7]&)]//Flatten (* _Harvey P. Dale_, Oct 06 2017 *)

%o (PARI) lista(pmax) = {my(s = 0, k = 0); forprime(p = 2, pmax, k++; s += p; if(!(s % 7), print1(k, ", ")));} \\ _Amiram Eldar_, May 14 2024

%Y Cf. A007504, A103208, A111318, A111319, A111320, A111322, A111323, A111324, A111325, A111326, A111327.

%K nonn

%O 1,1

%A _N. J. A. Sloane_, Nov 05 2005