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.

Showing 1-4 of 4 results.

A374663 Lexicographically earliest sequence of positive integers a(1), a(2), a(3), ... such that for any n > 0, Sum_{k = 1..n} 1 / (k*a(k)) < 1.

Original entry on oeis.org

2, 2, 2, 4, 10, 201, 34458, 1212060151, 1305857607493406801, 1534737681943564047120326770001682121, 2141290683979549415450148346297540185977813099483710032048213090481251382
Offset: 1

Views

Author

Rémy Sigrist, Aug 04 2024

Keywords

Comments

The harmonic series, Sum_{k > 0} 1/k, diverges. We divide each of its terms in such a way as to have a series bounded by 1.

Examples

			The initial terms, alongside the corresponding sums, are:
  n  a(n)        Sum_{k=1..n} 1/(k*a(k))
  -  ----------  -----------------------------------------
  1           2  1/2
  2           2  3/4
  3           2  11/12
  4           4  47/48
  5          10  1199/1200
  6         201  241199/241200
  7       34458  9696481199/9696481200
  8  1212060151  11752718467440661199/11752718467440661200
...
The denominators are in A375516.
		

References

  • Rémy Sigrist and N. J. A. Sloane, Dampening Down a Divergent Series, Manuscript in preparation, September 2024.

Crossrefs

Programs

  • Maple
    s:= proc(n) s(n):= `if`(n=0, 0, s(n-1)+1/(n*a(n))) end:
    a:= proc(n) a(n):= 1+floor(1/((1-s(n-1))*n)) end:
    seq(a(n), n=1..11);  # Alois P. Heinz, Oct 18 2024
  • Mathematica
    s[n_] := s[n] = If[n == 0, 0, s[n - 1] + 1/(n*a[n])];
    a[n_] := 1 + Floor[1/((1 - s[n - 1])*n)];
    Table[a[n], {n, 1, 11}] (* Jean-François Alcover, Jan 09 2025, after Alois P. Heinz *)
  • PARI
    { t = 0; for (n = 1, 11, for (v = ceil(1/(n*(1-t))), oo, if (t + 1/(n*v) < 1, t += 1/(n*v); print1 (v", "); break;););); }
    
  • Python
    from itertools import count, islice
    from math import gcd
    def A374663_gen(): # generator of terms
        p, q = 0, 1
        for k in count(1):
            yield (m:=q//(k*(q-p))+1)
            p, q = p*k*m+q, k*m*q
            p //= (r:=gcd(p,q))
            q //= r
    A374663_list = list(islice(A374663_gen(),11)) # Chai Wah Wu, Aug 28 2024

Formula

The ratios a(n)^2/a(n+1) are very close to the values 2, 2, 1, 8/5, 1/2, 7/6, 48/49, 9/8, 10/9, 11/10, 24/11^2, 13/12, 56/13^2, ... So it seems that often (but not always), a(n+1) is very close to (n/(n+1))*a(n)^2. - N. J. A. Sloane, Sep 08 2024

A375516 a(n) is the denominator of Sum_{k = 1..n} 1 / (k*A374663(k)).

Original entry on oeis.org

1, 2, 4, 12, 48, 1200, 241200, 9696481200, 11752718467440661200, 15347376819435640471203267700016821200, 23554197523775043569951631809272942045755944094320810352530343995293765200
Offset: 0

Views

Author

N. J. A. Sloane, Aug 19 2024

Keywords

Comments

In fact a(n) = A374983(n) + 1 (see the proof in A374983), but this was unproved when this sequence was created, and in any case the prime factors of A374983(n) and a(n) are both of interest, so both sequences are included in the OEIS. Both sequences grow doubly exponentially. See also A375791.
One might be led to conjecture that the last 4 digits of the numbers from a(5) onwards are always 1200, but Rémy Sigrist has observed that this does not hold for a(10) = 23554197523775043569951631809272942045755944094320810352530343995293765200.

Crossrefs

See A375517 for a(n)/n and A375791 for a(n+1)/a(n).

Programs

  • Maple
    s:= proc(n) s(n):= `if`(n=0, 0, s(n-1)+1/(n*b(n))) end:
    b:= proc(n) b(n):= 1+floor(1/((1-s(n-1))*n)) end:
    a:= n-> denom(s(n)):
    seq(a(n), n=0..10);  # Alois P. Heinz, Oct 18 2024
  • Mathematica
    s[n_] := s[n] = If[n == 0, 0, s[n-1] + 1/(n*b[n])];
    b[n_] := b[n] = 1 + Floor[1/((1 - s[n-1])*n)];
    a[n_] := Denominator[s[n]];
    Table[a[n], {n, 0, 14}] (* Jean-François Alcover, Dec 10 2024, after Alois P. Heinz *)
  • Python
    from itertools import count, islice
    from math import gcd
    def A375516_gen(): # generator of terms
        p, q = 0, 1
        for k in count(1):
            yield q
            m = q//(k*(q-p))+1
            p, q = p*k*m+q, k*m*q
            p //= (r:=gcd(p,q))
            q //= r
    A375516_list = list(islice(A375516_gen(),11)) # Chai Wah Wu, Aug 28 2024

A374983 a(n) is the numerator of Sum_{k = 1..n} 1 / (k*A374663(k)).

Original entry on oeis.org

0, 1, 3, 11, 47, 1199, 241199, 9696481199, 11752718467440661199, 15347376819435640471203267700016821199, 23554197523775043569951631809272942045755944094320810352530343995293765199
Offset: 0

Views

Author

Rémy Sigrist, Aug 04 2024

Keywords

Comments

For the denominators see A375516 and A375517.
For n = 1..36, Sum_{k = 1..n} 1 / (k*A374663(k)) = a(n) / (1 + a(n)). In fact this holds for all n >= 1.
Theorem: Let S_n = Sum_{k = 1..n} 1 / (k*A374663(k)) and let r_n = 1 - S_n. Then for n > 1, r_n is the inverse of a positive integer, say d_n; d_{n+1} is divisible by d_n; and d_n is divisible by all positive integers < n. (See Sigrist link for proof; d_n is given in A375516.)

Examples

			For n = 3: A374663(1) = A374663(2) = A374663(3) = 2, 1/(1*2) + 1/(2*2) + 1/(3*2) = 11/12, so a(3) = 11.
		

Crossrefs

Cf. A374663, A375516 (denominators), A375517.

Programs

  • Maple
    s:= proc(n) s(n):= `if`(n=0, 0, s(n-1)+1/(n*b(n))) end:
    b:= proc(n) b(n):= 1+floor(1/((1-s(n-1))*n)) end:
    a:= n-> numer(s(n)):
    seq(a(n), n=0..10);  # Alois P. Heinz, Oct 18 2024
  • Mathematica
    s[n_] := s[n] = If[n == 0, 0, s[n - 1] + 1/(n*b[n])];
    b[n_] := b[n] = 1 + Floor[1/((1 - s[n - 1])*n)];
    a[n_] := Numerator[s[n]];
    Table[a[n], {n, 0, 10}] (* Jean-François Alcover, Apr 22 2025, after Alois P. Heinz *)
  • PARI
    { print1 (0); t = 0; for (n = 1, 10, for (v = c=ceil(1/(n*(1-t))), oo, if (t + 1/(n*v) < 1, t += 1/(n*v); print1 (", " numerator(t)); break;););); }
    
  • Python
    from itertools import count, islice
    from math import gcd
    def A374983_gen(): # generator of terms
        p, q = 0, 1
        for k in count(1):
            yield p
            m = q//(k*(q-p))+1
            p, q = p*k*m+q, k*m*q
            p //= (r:=gcd(p,q))
            q //= r
    A374983_list = list(islice(A374983_gen(),11)) # Chai Wah Wu, Aug 28 2024

A375518 First differences of A375516.

Original entry on oeis.org

1, 2, 8, 36, 1152, 240000, 9696240000, 11752718457744180000, 15347376819435640459450549232576160000, 23554197523775043569951631809272942030408567274885169881327076295276944000
Offset: 0

Views

Author

N. J. A. Sloane, Aug 25 2024

Keywords

Comments

The terms of A375516 are not well-understood. The present sequence was suggested by the fact that, from a certain point on, the terms of A375516 end with the digits 1200. If powers of 2 and 3 are ignored, the terms of the present sequence appear to be perfect squares.

Crossrefs

Programs

  • Maple
    s:= proc(n) s(n):= `if`(n=0, 0, s(n-1)+1/(n*b(n))) end:
    b:= proc(n) b(n):= 1+floor(1/((1-s(n-1))*n)) end:
    a:= n-> denom(s(n+1))-denom(s(n)):
    seq(a(n), n=0..10);  # Alois P. Heinz, Oct 19 2024
  • Mathematica
    s[n_] := s[n] = If[n == 0, 0, s[n - 1] + 1/(n*b[n])];
    b[n_] := b[n] = 1 + Floor[1/((1 - s[n - 1])*n)];
    a[n_] := Denominator[s[n + 1]] - Denominator[s[n]];
    Table[a[n], {n, 0, 12}] (* Jean-François Alcover, Feb 14 2025, after Alois P. Heinz *)

Extensions

a(0)=1 prepended by Alois P. Heinz, Oct 19 2024
Showing 1-4 of 4 results.