cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A129749 Numbers k that divide the sum of the first k nonprimes.

This page as a plain text file.
%I A129749 #11 Jan 04 2024 17:45:07
%S A129749 1,8,32,44,577,5066,5669,8615,39787,59689,109752,146328,15451380,
%T A129749 22173220,28558717,332573533,1837410366,3289933379,19053646133,
%U A129749 370648112641
%N A129749 Numbers k that divide the sum of the first k nonprimes.
%C A129749 A variant of A045345 and A053781.
%C A129749 a(21) > 10^12. - _Donovan Johnson_, May 20 2010
%e A129749 The sum of the first 44 nonprimes is 1452 = 33*44.
%p A129749 np:=proc(j) if isprime(j)=false then j else fi end: NP:=[seq(np(j),j=1..50000)]: a:=proc(n) if type(add(NP[j],j=1..n)/n,integer)=true then n else fi end: seq(a(n),n=1..nops(NP)); # _Emeric Deutsch_, May 16 2007
%t A129749 Module[{nn=150000,np},np=Accumulate[Select[Range[nn],!PrimeQ[#]&]];Select[Thread[ {np,Range[Length[np]]}],Mod[#[[1]],#[[2]]]==0&]][[;;,2]] (* The program generates the first 11 terms of the sequence. To generate more, increase the nn constant. *) (* _Harvey P. Dale_, Jan 04 2024 *)
%Y A129749 Cf. A045345 (n divides sum of first n primes), A053781 (n divides sum of first n composites), A018252 (nonprimes), A051349 (sum of first n nonprimes).
%K A129749 nonn,more
%O A129749 1,2
%A A129749 _J. M. Bergot_, May 14 2007
%E A129749 Edited and a(5) to a(18) added by _Klaus Brockhaus_, May 17 2007
%E A129749 a(19) from _Donovan Johnson_, Sep 19 2009
%E A129749 a(20) from _Donovan Johnson_, May 20 2010