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.

A386591 Number of divisors of n that are not balanced numbers.

Original entry on oeis.org

0, 0, 0, 1, 1, 0, 1, 2, 1, 2, 1, 1, 1, 1, 1, 3, 1, 2, 1, 4, 2, 2, 1, 3, 2, 2, 2, 3, 1, 2, 1, 4, 2, 2, 2, 4, 1, 2, 2, 6, 1, 2, 1, 4, 3, 2, 1, 5, 2, 4, 2, 4, 1, 4, 3, 4, 2, 2, 1, 5, 1, 2, 4, 5, 3, 4, 1, 4, 2, 3, 1, 7, 1, 2, 3, 4, 3, 3, 1, 8, 3, 2, 1, 5, 3, 2, 2, 6, 1, 6, 3, 4, 2, 2, 3, 7, 1, 3, 4, 7
Offset: 1

Views

Author

Wesley Ivan Hurt, Jul 26 2025

Keywords

Comments

Number of divisors d of n such that phi(d) does not divide sigma(d).
Inverse Möbius transform of 1 - c(n), where c = A351114.

Crossrefs

Cf. A000005 (tau), A000010 (phi), A000203 (sigma), A020492 (balanced numbers), A351112, A351114.

Programs

  • Maple
    g:= proc(n) option remember; numtheory:-sigma(n) mod numtheory:-phi(n) <> 0 end proc:
    f:= n -> nops(select(g,numtheory:-divisors(n))):
    map(f, [$1..100]); # Robert Israel, Aug 26 2025
  • Mathematica
    Table[Sum[Ceiling[DivisorSigma[1, d]/EulerPhi[d]] - Floor[DivisorSigma[1, d]/EulerPhi[d]], {d, Divisors[n]}], {n, 100}]
  • PARI
    a(n) = sumdiv(n, d, sigma(d)%eulerphi(d) != 0); \\ Michel Marcus, Aug 26 2025

Formula

a(n) = Sum_{d|n} (1 - c(d)), where c = A351114.
a(n) = A000005(n) - A351112(n).