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.

A158341 a(n) = A013928(A002110(n)).

Original entry on oeis.org

0, 1, 4, 18, 128, 1404, 18261, 310346, 5896727, 135624239, 3933101823, 121926157640, 4511267827531, 184961980943492, 7953365180610400, 373808163488684049, 19811832664899731265, 1168898127229083969892
Offset: 0

Views

Author

Mats Granvik, Mar 16 2009

Keywords

Crossrefs

Programs

  • Mathematica
    Table[-1 + Sum[MoebiusMu[k]*Floor[#/(k^2)], {k, Floor[Sqrt[#]]}] &[Product[Prime[i], {i, n}]], {n, 0, 12}] (* Michael De Vlieger, Jan 24 2025 *)
  • PARI
    a(n) = my(t=vecprod(primes(n))-1); sum(i=1, sqrtint(t), t\i^2*moebius(i)); \\ Jinyuan Wang, Jan 24 2025
    
  • Python
    from math import isqrt
    from sympy import primorial, mobius
    def A158341(n):
        if n == 0: return 0
        m = primorial(n)-1
        return sum(mobius(k)*(m//k**2) for k in range(1,isqrt(m)+1)) # Chai Wah Wu, Jan 25 2025

Formula

a(n) = -1 + Sum_{i=1..floor(sqrt(A002110(n)))} moebius(i)*floor(A002110(n)/i^2). - Jinyuan Wang, Jan 24 2025

Extensions

Extended and offset corrected by Max Alekseyev, Sep 13 2009
a(15) from Michael De Vlieger, Jan 24 2025
a(16)-a(17) from Chai Wah Wu, Jan 25 2025