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.

A074631 a(n) is the smallest k such that the sum of the first k terms of the composite-harmonic series, Sum_{j=1..k} 1/(j-th composite), is > n.

This page as a plain text file.
%I A074631 #25 Jul 17 2024 12:34:07
%S A074631 9,44,168,587,1940,6192,19285,59010,178122,531923,1574706,4628338,
%T A074631 13521477,39299115,113712434,327752962,941457955,2696114317,
%U A074631 7700146599,21938239766
%N A074631 a(n) is the smallest k such that the sum of the first k terms of the composite-harmonic series, Sum_{j=1..k} 1/(j-th composite), is > n.
%F A074631 a(n) = Min { k : Sum_{j=1..k} 1/A002808(j) > n }.
%F A074631 Limit_{n->oo} a(n+1)/a(n) = e. - _Robert G. Wilson v_, Aug 28 2002
%F A074631 a(n) = A065855(A076751(n)). - _Amiram Eldar_, Jul 17 2024
%e A074631 1/4 + 1/6 + 1/8 + 1/9 + 1/10 + 1/12 + 1/14 + 1/15 + 1/16 = 1045/1008, but if 1/16 is not present, the sum is less than 1; 16 is the ninth composite number, so a(1) = 9.
%t A074631 NextComposite[n_] := Block[{k = n + 1}, While[PrimeQ[k], k++ ]; k]; s=0; k = 4; Do[While[s = s + 1/k; s < n, k = NextComposite[k]]; Print[k - PrimePi[k] - 1]; k = NextComposite[k], {n, 1, 20}]
%t A074631 Table[Position[Accumulate[1/Select[Range[5*10^6],CompositeQ]],_?(#>n&),1,1],{n,12}]//Flatten (* The program generates the first 12 terms of the sequence. *) (* _Harvey P. Dale_, Jan 22 2023 *)
%o A074631 (PARI) lista(cmax) = {my(n = 1, s = 0, k = 0); forcomposite(c = 1, cmax, k++; s += 1/c; if(s > n, print1(k, ", "); n++));} \\ _Amiram Eldar_, Jul 17 2024
%Y A074631 Cf. A002387, A002808, A004080, A016088, A046024, A065855, A076751.
%K A074631 nonn,nice,hard,more
%O A074631 1,1
%A A074631 _Labos Elemer_, Aug 27 2002
%E A074631 Edited by _Robert G. Wilson v_, Aug 28 2002
%E A074631 More terms from _Robert Gerbicz_, Aug 30 2002
%E A074631 2 more terms from _Robert G. Wilson v_, Sep 03 2002
%E A074631 Edited by _Jon E. Schoenfield_, Sep 13 2023
%E A074631 a(18)-a(20) from _Amiram Eldar_, Jul 17 2024