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.

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