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.

Previous Showing 41-50 of 84 results. Next

A331028 Partition the terms of the harmonic series into groups sequentially so that the sum of each group is equal to or minimally greater than 1; then a(n) is the number of terms in the n-th group.

Original entry on oeis.org

1, 3, 8, 22, 60, 163, 443, 1204, 3273, 8897, 24184, 65739, 178698, 485751, 1320408, 3589241, 9756569, 26521104, 72091835, 195965925, 532690613, 1448003214, 3936080824, 10699376979, 29083922018, 79058296722, 214902731368, 584166189564, 1587928337892, 4316436745787
Offset: 1

Views

Author

Keywords

Comments

a(n) is equal to A024581(n) through a(10), and grows very similarly for n > 10.
Let b(n) = Sum_{j=1..n} a(n); then for n >= 2 it appears that b(n) = round((b(n-1) + 1/2)*e). Cf. A331030. - Jon E. Schoenfield, Jan 14 2020

Examples

			a(1)=1 because 1 >= 1,
a(2)=3 because 1/2 + 1/3 + 1/4 = 1.0833... >= 1, etc.
		

Crossrefs

Some sequences in the same spirit as this: A002387, A004080, A055980, A115515.

Programs

  • PARI
    default(realprecision, 10^5); e=exp(1);
    lista(nn) = {my(r=1); print1(r); for(n=2, nn, print1(", ", -r+(r=floor(e*r+(e+1)/2+(e-1/e)/(24*(r+1/2)))))); } \\ Jinyuan Wang, Mar 31 2020
  • Python
    x = 0.0
    y = 0.0
    for i in range(1,100000000000000000000000):
      y += 1
      x = x + 1/i
      if x >= 1:
        print(y)
        y = 0
        x = 0
    

Formula

a(n) = min(p): Sum_{b=r+1..p+r} 1/b >= 1, r = Sum_{k=1..n-1} a(k), a(1) = 1.

Extensions

a(20)-a(21) from Giovanni Resta, Jan 14 2020
More terms from Jinyuan Wang, Mar 31 2020

A004796 Numbers k such that if 2 <= j < k then the fractional part of the k-th partial sum of the harmonic series is < the fractional part of the j-th partial sum of the harmonic series.

Original entry on oeis.org

4, 11, 83, 616, 1674, 4550, 12367, 33617, 91380, 248397, 1835421, 4989191, 13562027, 36865412, 272400600, 740461601, 2012783315, 5471312310, 40427833596, 298723530401, 812014744422, 2207284924203, 6000022499693
Offset: 1

Views

Author

Keywords

Comments

Numbers k such that H(k) sets a new record for being a tiny bit greater than an integer, where H(k) = Sum_{m=1..k} 1/m. For proofs that H(k) is non-integral and almost always a non-terminating decimal see Havil reference.
Assuming that H(k) ~= log(k) + gamma + 1/(2k), the next several terms should be 2012783315, 5471312310 and 40427833596; 14872568831 and 109894245429 are not included. - Robert G. Wilson v, Aug 14 2003

Examples

			a(2)=11 because H(11) = 3.0198773...; a(3)=83 because H(83) = 5.0020682...
		

References

  • Julian Havil, "Gamma: Exploring Euler's Constant", Princeton University Press, Princeton and Oxford, 2003, pp. 24-25.

Crossrefs

Subset of A002387.

Programs

  • Mathematica
    s = 0; a = 1; Do[ s = N[s + 1/n, 50]; If[ FractionalPart[s] < a, a = FractionalPart[s]; Print[n]], {n, 2, 1378963718}]
  • PARI
    H(n) = sum(k=1,n,1/k)+0.; { hr(m)=local(rec); rec=0.5; for(n=2,m,if(frac(H(n))
    				

Extensions

Edited and extended by Jason Earls, Jun 30 2003
Extended by Robert G. Wilson v, Aug 14 2003
More terms from Jon E. Schoenfield, Mar 26 2010

A074467 Least k such that Sum_{i=1..k} 1/phi(i) >= n.

Original entry on oeis.org

1, 2, 4, 8, 13, 22, 38, 63, 105, 177, 296, 495, 828, 1386, 2318, 3879, 6489, 10854, 18158, 30375, 50811, 84998, 142187, 237853, 397885, 665589, 1113411, 1862534, 3115683, 5211973, 8718687, 14584783, 24397699, 40812930, 68272636, 114207749, 191048868, 319590137
Offset: 1

Views

Author

Labos Elemer, Aug 29 2002

Keywords

References

  • J.-M. De Koninck, Ces nombres qui nous fascinent, Entry 177, p. 55, Ellipses, Paris 2008.
  • E. Landau, Uber die Zahlentheoretische Function ϕ(n) und ihre Beziehung zum Goldbachschen satz, Nachrichten der Koniglichten Gesel lschaft der Wissenschaften zu Göttingen mathematisch Physikalische klasse, Jahrgang (1900), pp. 177-186.

Crossrefs

Programs

  • Mathematica
    {s=0, s1=0}; Do[s=s+(1/EulerPhi[n]); If[Greater[Floor[s], s1], s1=Floor[s]; Print[{n, Floor[s]}]], {n, 1, 1000000}]
  • PARI
    a(n)=my(s,k);while(sCharles R Greathouse IV, Jan 29 2013

Formula

a(n) ~ k exp(cn) for c = zeta(6)/zeta(2)/zeta(3) = A068468 and k = exp(-gamma + A085609) = 1.0316567993311528...; see Montgomery or Koninck. - Charles R Greathouse IV, Jan 29 2013

Extensions

More terms from Ryan Propper, Jul 09 2005
a(32)-a(38) from Donovan Johnson, Aug 21 2011

A074468 Least number m such that the Sigma-Harmonic sequence Sum_{k=1..m} 1/sigma(k) >= n.

Original entry on oeis.org

1, 7, 29, 129, 571, 2525, 11167, 49372, 218295, 965177, 4267457, 18868240, 83424514, 368855252, 1630865929, 7210751807, 31881800153
Offset: 1

Views

Author

Labos Elemer, Aug 29 2002

Keywords

References

  • Jean-Marie De Koninck, Ces nombres qui nous fascinent, Entry 129, p. 44, Ellipses, Paris, 2008.

Crossrefs

Programs

  • Mathematica
    {s=0, s1=0}; Do[s=s+(1/DivisorSigma[1, n]); If[Greater[Floor[s], s1], s1=Floor[s]; Print[{n, Floor[s]}]], {n, 1, 1000000}]

Formula

Limit_{n->oo} a(n+1)/a(n) = exp(1/c) = 4.42142525588146107878... where c = A308039. - Amiram Eldar, May 05 2024

Extensions

2 more terms from Lekraj Beedassy, Jul 14 2008
a(11)-a(15) from Donovan Johnson, Aug 22 2011
a(16)-a(17) from Amiram Eldar, May 05 2024

A091462 a(n) is the smallest j such that 1/3 + 1/6 + 1/9 + ... + 1/j exceeds n.

Original entry on oeis.org

3, 33, 681, 13650, 274140, 5506263, 110596236, 2221384803, 44617706493, 896170591203, 18000067499079, 361541020372644, 7261745513941683, 145856057647068072, 2929597231340774769, 58842533360163495285, 1181883876459465987195, 23738772239546776075803, 476805986328559173414774
Offset: 0

Views

Author

Robert G. Wilson v, Jan 12 2004

Keywords

Crossrefs

Programs

  • Mathematica
    s = 0; k = 3; Do[ While[s = N[s + 1/k, 24]; s <= n, k += 3]; Print[k]; k += 3, {n, 1, 12}]

Formula

a(n) = 3*A002387(3n).
The next term is approximately the previous term * e^3.

Extensions

a(0) prepended and more terms added by Max Alekseyev, Sep 01 2023

A092267 Values 2m_0+1 = 1, 2m_1, 2m_2+1, ... associated with divergent series T shown below.

Original entry on oeis.org

1, 454, 45891, 547208496, 3013267310449, 1961694770407970734, 589785633779065944213245, 20963601300674244910397534828794, 344117353602393170461608383214200982125
Offset: 0

Views

Author

N. J. A. Sloane, Feb 16 2004

Keywords

Comments

T = 1
- (1/2 + 1/4 + 1/6 + ... + 1/(2m_1))
+ (1/3 + 1/5 + 1/7 + ... + 1/(2m_2+1))
- (1/(2m_1+2) + 1/(2m_1+4) + ... + 1/(2m_3)
+ (1/(2m_2+3) + 1/(2m_2+5) + ... + 1/(2m_4+1))
- (1/(2m_3+2) + 1/(2m_3+4) + ... + 1/(2m_5)
+ (1/(2m_4+3) + 1/(2m_4+5) + ... + 1/(2m_6+1))
- ...
where the partial sums of the terms from 1 through the end of rows 0, 1, ... are respectively 1, just < -2, just > 3, just < -4, just > 5, etc.
Every positive number appears exactly once as a denominator in T.
The series T is a divergent rearrangement of the conditionally convergent series Sum_{ j>=1} (-1)^j/j which has the entire real number system as its set of limit points.

Examples

			1 - (1/2 + 1/4 + 1/6 + ... + 1/454) = -2.002183354..., which is just less than -2; so a(1) = 2m_1 = 454.
1 - (1/2 + 1/4 + 1/6 + ... + 1/454) + (1/3 + 1/5 + ... + 1/45891) = 3.000021113057..., which is just greater than 3; so a(1) = 2m_2 + 1 = 45891.
		

References

  • B. R. Gelbaum and J. M. H. Olmsted, Counterexamples in Analysis, Holden-Day, San Francisco, 1964; see p. 55.

Crossrefs

Cf. A092324 (essentially the same), A002387, A056053, A092318, A092317, A092315.
Cf. A092273.

Extensions

a(2) and a(3) from Hugo Pfoertner, Feb 17 2004
a(4) onwards from Hans Havermann, Feb 18 2004

A092324 Values m_0 = 0, m_1, m_2, ... associated with divergent series T shown below.

Original entry on oeis.org

0, 227, 22945, 273604248, 1506633655224, 980847385203985367, 294892816889532972106622, 10481800650337122455198767414397, 172058676801196585230804191607100491062
Offset: 0

Views

Author

N. J. A. Sloane, Feb 16 2004

Keywords

Comments

T = 1
- (1/2 + 1/4 + 1/6 + ... + 1/(2m_1))
+ (1/3 + 1/5 + 1/7 + ... + 1/(2m_2+1))
- (1/(2m_1+2) + 1/(2m_1+4) + ... + 1/(2m_3)
+ (1/(2m_2+3) + 1/(2m_2+5) + ... + 1/(2m_4+1))
- (1/(2m_3+2) + 1/(2m_3+4) + ... + 1/(2m_5)
+ (1/(2m_4+3) + 1/(2m_4+5) + ... + 1/(2m_6+1))
- ...
where the partial sums of the terms from 1 through the end of rows 0, 1, ... are respectively 1, just < -2, just > 3, just < -4, just > 5, etc.
Every positive number appears exactly once as a denominator in T.
The series T is a divergent rearrangement of the conditionally convergent series Sum_{j>=1} (-1)^j/j which has the entire real number system as its set of limit points.
Comment from Hans Havermann: I calculated these with Mathematica. I used NSum[1/(2i), {i, 1, x}] for the even denominators, where I had to adjust the options to obtain maximal accuracy and N[(EulerGamma + Log[4] - 2)/2 + PolyGamma[0, 3/2 + y]/2, precision] for the odd denominators. The precision needed for the last term shown was around 45 digits.

Examples

			1 - (1/2 + 1/4 + 1/6 + ... + 1/454) = -2.002183354..., which is just less than -2; so a(1) = m_1 = 227.
1 - (1/2 + 1/4 + 1/6 + ... + 1/454) + (1/3 + 1/5 + ... + 1/45891) = 3.000021113057..., which is just greater than 3; so a(2) = m_2 = 22945.
		

References

  • B. R. Gelbaum and J. M. H. Olmsted, Counterexamples in Analysis, Holden-Day, San Francisco, 1964; see p. 55.

Crossrefs

Cf. A092267 (essentially the same), A002387, A056053, A092318, A092317, A092315.
Cf. A092273.

Extensions

a(2) and a(3) from Hugo Pfoertner, Feb 17 2004
a(4) onwards from Hans Havermann, Feb 18 2004

A096005 For k >= 1, let b(k) = ceiling( Sum_{i=1..k} 1/i ); a(n) = number of b(k) that are equal to n.

Original entry on oeis.org

0, 1, 2, 7, 20, 52, 144, 389, 1058, 2876, 7817, 21250, 57763, 157017, 426817, 1160207, 3153770, 8572836, 23303385, 63345169, 172190019, 468061001, 1272321714, 3458528995, 9401256521, 25555264765, 69466411833, 188829284972
Offset: 0

Views

Author

W. Neville Holmes, Jul 29 2004

Keywords

Examples

			The ceilings of the first several partial sums of the reciprocal of the positive integers are 1 2 2 3 3 3 3 3 3 3 4 4 and the series is monotonically increasing, so a(0) = 0 (there being no zero), a(1) = 1 (there being but one 1) and a(3) = 7 (there being seven 3s).
		

Crossrefs

Programs

  • C
    int A096005(int k)
    {    if(k<3) return k;
        double sum = 0, n = 1; int ceiling = 2, cnt = 0;
        for(;;) {
            sum += 1/n++;
            if(sum < ceiling) { cnt++; continue; }
            if(ceiling++ == k) return cnt; else cnt = 1; }
    } /* Oskar Wieland, May 01 2014 */
  • Mathematica
    fh[0] = 0; fh[1] = 1; fh[k_] := Module[{tmp}, If[ Floor[tmp = Log[k + 1/2] + EulerGamma] == Floor[tmp + 1/(24k^2)], Floor[tmp], UNKNOWN]]; a[0] = 1; a[1] = 2; a[n_] := Module[{val}, val = Round[Exp[n - EulerGamma]]; If[fh[val] == n && fh[val - 1] == n - 1, val, UNKNOWN]]; Table[ a[n + 1] - a[n], {n, 0, 27}] (* Robert G. Wilson v, Aug 05 2004 *)

Formula

a(n+1)/a(n) approaches e = exp(1) = 2.71828...
First differences of A002387. - Vladeta Jovovic, Jul 30 2004

Extensions

More terms from Robert G. Wilson v, Aug 05 2004

A331030 Divide the terms of the harmonic series into groups sequentially so that the sum of each group is minimally greater than 1. a(n) is the number of terms in the n-th group.

Original entry on oeis.org

2, 5, 13, 36, 98, 266, 723, 1965, 5342, 14521, 39472, 107296, 291661, 792817, 2155100, 5858169, 15924154, 43286339, 117664468, 319845186, 869429357, 2363354022, 6424262292, 17462955450, 47469234471, 129034757473, 350752836478, 953445061679, 2591732385596
Offset: 1

Views

Author

Keywords

Comments

a(n) = A046171(n+1) through a(5), and grows similarly for n > 5.
Let b(n) = Sum_{j=1..n} a(n); then for n >= 2 it appears that b(n) = round((b(n-1) + 1/2)*e). Verified through n = 10000 (using the approximation Sum_{j=1..k} 1/j = log(k) + gamma + 1/(2*k) - 1/(12*k^2) + 1/(120*k^4) - 1/(252*k^6) + 1/(240*k^8) - ..., where gamma is the Euler-Mascheroni constant, A001620). Cf. A081881. - Jon E. Schoenfield, Jan 10 2020

Examples

			a(1)=2 because 1 + 1/2 = 1.5 > 1,
a(2)=5 because 1/3 + 1/4 + 1/5 + 1/6 + 1/7 = 1.0928... > 1,
etc.
		

Crossrefs

Programs

  • PARI
    lista(lim=oo)={my(s=0, p=0); for(i=1, lim, s+=1/i; if(s>1, print1(i-p, ", "); s=0; p=i))} \\ Andrew Howroyd, Jan 08 2020
  • Python
    x = 0.0
    y = 0.0
    z = 0.0
    for i in range(1,100000000000000000000000):
      y += 1
      x = x + 1/i
      z = z + 1/i
      if x > 1:
        print(y)
        y = 0
        x = 0
    

Formula

a(1)=2, a(n) = (min(p) : Sum_{s=r..p} 1/s > 1)-r+1, r=Sum_{k=1..n-1} a(k).

Extensions

a(25)-a(29) from Jon E. Schoenfield, Jan 10 2020

A385328 The number of people in a variation of the Josephus problem when the first person is freed and the elimination process is to skip the number of people equaling the number of letters in consecutive numbers, then eliminate the next person.

Original entry on oeis.org

1, 2, 5, 26, 50, 82, 857, 1114, 3340, 3733, 3777, 11023, 12960, 17992, 47253, 329414, 367572, 382265
Offset: 1

Views

Author

Tanya Khovanova, Nathan Sheffield, and the MIT PRIMES STEP junior group, Jun 25 2025, Jun 25 2025, Jul 06 2025

Keywords

Comments

This sequence uses the US spelling. [Specifically, A005589. - Michael S. Branicky, Jul 23 2025]
This sequence can be used in magic tricks with SpellUnderDown dealing pattern. The first three people are skipped, corresponding to three letters in O-N-E, and the next person is eliminated. Then, three people are skipped corresponding to three letters in T-W-O, and the next person is eliminated. Then, 5 people are skipped, corresponding to 5 letters in T-H-R-E-E.
The deck sizes in this sequence guarantee that after the dealing, the last card is the one that was initially on top.
A naive probabilistic argument predicts the probability that A380204(k) = 1 is 1/k and expects this sequence to be infinite and distributed roughly as A002387. - Michael S. Branicky, Jul 23 2025

Examples

			Suppose there are 5 people in a circle. After three people are skipped (for O-N-E), the person number 4 is eliminated. The leftover people are 5,1,2,3 in order. Then three people are skipped (for T-W-O), and person number 3 is eliminated. The leftover people are 5,1,2 in order. Then 5 people are skipped (for T-H-R-E-E), and person 2 is eliminated. The leftover people are 5,1 in order. Then 4 people are skipped (for F-O-U-R), and person number 5 is eliminated. Person 1 is freed. Thus, 5 is in this sequence.
		

Crossrefs

Formula

{k | A380204(k) = 1}. - Michael S. Branicky, Jul 23 2025

Extensions

a(15)-a(18) from Michael S. Branicky, Jul 23 2025
Previous Showing 41-50 of 84 results. Next