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.

A385122 a(n) = d(phi(n)) - phi(d(n)) where d(n) = A000005(n) is the number of divisors and phi(n) = A000010(n) is the Euler totient function.

Original entry on oeis.org

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

Views

Author

Sean A. Irvine, Jun 18 2025

Keywords

Comments

First negative value is a(120) = -2.

Crossrefs

Programs

  • Mathematica
    A385122[n_] := DivisorSigma[0, EulerPhi[n]] - EulerPhi[DivisorSigma[0, n]];
    Array[A385122, 100] (* Paolo Xausa, Jun 19 2025 *)
  • PARI
    a(n) = numdiv(eulerphi(n)) - eulerphi(numdiv(n)); \\ Michel Marcus, Jun 19 2025

Formula

a(n) = A000005(A000010(n)) - A000010(A000005(n)).
a(n) = A062821(n) - A163109(n).