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.

A384452 a(n) is the sum of squares of the unitary divisors of n!.

Original entry on oeis.org

1, 5, 50, 650, 16900, 547924, 27396200, 1746641000, 139773881000, 13460683752200, 1642203417768400, 236441876606410000, 40195119023089700000, 7723888546922636420000, 1735183690969722609168800, 444206919394766468845892000, 128820006624482275965308680000, 41737604550102658693597600532800
Offset: 1

Views

Author

DarĂ­o Clavijo, Jun 02 2025

Keywords

Crossrefs

Programs

  • Mathematica
    f[p_, e_] := p^(2*e)+1; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n!]; Array[a, 18] (* Amiram Eldar, Jun 02 2025 *)
  • PARI
    row(n) = {my(d = divisors(n)); select(x->(gcd(x, n/x)==1), d); } \\ A077610
    a(n) = norml2(row(n!)); \\ Michel Marcus, Jun 02 2025
  • Python
    from sympy import nextprime
    def f(n,p):
      if n==0: return 0
      return f(n//p,p) + n//p
    def a(n):
      s,p = 1, 2
      while p<=n:
        s *= p**(f(n,p)<<1)+1
        p = nextprime(p)
      return s
    print([a(n) for n in range(1, 19)])
    

Formula

a(n) = Sum_{d|n!} (d^2 if gcd(d,n!//d) = 1).
a(n) = Product_{p <= n, p prime} (p^(2*f(n,p)))+1 with f(n,p) = f(floor(n/p)) + floor(n/p) and f(0,p) = 0 where f(n,p) is equivalent to the Legendre formula.
a(n) = A034676(n!).