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.

Showing 1-4 of 4 results.

A351112 Number of balanced numbers dividing n.

Original entry on oeis.org

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

Views

Author

Wesley Ivan Hurt, Jan 31 2022

Keywords

Comments

A balanced number k is a number such that phi(k) | sigma(k).
Inverse Möbius transform of the characteristic function of balanced numbers (A351114). - Wesley Ivan Hurt, Jun 23 2024

Examples

			a(4) = 2; the balanced divisors of 4 are 1 and 2.
a(5) = 1; 1 is the only balanced divisor of 5.
a(6) = 4; the balanced divisors of 6 are 1,2,3,6.
		

Crossrefs

Cf. A351113 (sum of the balanced numbers dividing n).
Cf. A000005 (tau), A000010 (phi), A000203 (sigma), A020492 (balanced numbers), A023897, A351114.

Programs

  • Maple
    f:= proc(n) uses numtheory;
      nops(select(t -> sigma(t) mod phi(t) = 0, divisors(n)))
    end proc:
    map(f, [$1..100]); # Robert Israel, Nov 28 2023
  • Mathematica
    a[n_] := DivisorSum[n, 1 &, Divisible[DivisorSigma[1, #], EulerPhi[#]] &]; Array[a, 100] (* Amiram Eldar, Feb 01 2022 *)
  • PARI
    a(n) = sumdiv(n, d, if (!(sigma(d) % eulerphi(d)), 1)); \\ Michel Marcus, Feb 01 2022

Formula

a(n) = Sum_{d|n, phi(d)|sigma(d)} 1.
a(n) = Sum_{d|n} A351114(d).
a(n) = tau(n) - Sum_{d|n} sign(sigma(d) mod phi(d)).
Conjecture: asymptotic mean: Limit_{m->oo} (1/m) * Sum_{k=1..m} a(k) = Sum_{k>=1} 1/A020492(k) = 2.4343... (assuming empirically that this sum of reciprocals converges). - Amiram Eldar, Dec 27 2024

A386592 Sum of the divisors of n that are not balanced numbers.

Original entry on oeis.org

0, 0, 0, 4, 5, 0, 7, 12, 9, 15, 11, 4, 13, 7, 5, 28, 17, 27, 19, 39, 28, 33, 23, 36, 30, 39, 36, 39, 29, 15, 31, 60, 44, 51, 12, 67, 37, 57, 52, 87, 41, 28, 43, 81, 59, 69, 47, 100, 56, 90, 68, 95, 53, 108, 71, 47, 76, 87, 59, 99, 61, 93, 100, 124, 83, 132, 67, 123, 92, 22, 71, 171, 73, 111, 105, 137, 95, 78, 79, 183, 117, 123, 83, 144, 107, 129, 116, 177
Offset: 1

Views

Author

Wesley Ivan Hurt, Jul 26 2025

Keywords

Comments

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

Crossrefs

Cf. A000010 (phi), A000203 (sigma), A351113, A351114, A387333.

Programs

  • Maple
    g:= proc(n) option remember; numtheory:-sigma(n) mod numtheory:-phi(n) <> 0 end proc:
    f:= n -> convert(select(g,numtheory:-divisors(n)),`+`):
    map(f, [$1..100]); # Robert Israel, Aug 26 2025
  • Mathematica
    Table[Sum[d (Ceiling[DivisorSigma[1, d]/EulerPhi[d]] - Floor[DivisorSigma[1, d]/EulerPhi[d]]), {d, Divisors[n]}], {n, 100}]

Formula

a(n) = Sum_{d|n} d * (1 - c(d)), where c = A351114.
a(n) = A000203(n) - A351113(n).

A362707 a(n) = Sum_{d|n, phi(d)|sigma(d)} (n-d).

Original entry on oeis.org

0, 1, 2, 5, 4, 12, 6, 13, 14, 17, 10, 36, 12, 25, 26, 29, 16, 60, 18, 37, 38, 41, 22, 96, 24, 49, 50, 67, 28, 123, 30, 61, 62, 65, 34, 156, 36, 73, 74, 77, 40, 184, 42, 85, 116, 89, 46, 216, 48, 97, 98, 101, 52, 204, 54, 151, 110, 113, 58, 351, 60, 121, 122, 125, 64, 252, 66, 133
Offset: 1

Views

Author

Wesley Ivan Hurt, Apr 30 2023

Keywords

Comments

Total distance from n to each balanced divisor of n (see example).

Examples

			a(12) = 36; 12 has 5 balanced divisors 1,2,3,6,12 and the sum of their distances to n is (12-1)+(12-2)+(12-3)+(12-6)+(12-12) = 36.
		

Crossrefs

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

Programs

  • Mathematica
    a[n_] := DivisorSum[n, (n - #) &, Divisible[DivisorSigma[1, #], EulerPhi[#]] &]; Array[a, 100]
  • PARI
    a(n) = sumdiv(n, d, if (!(sigma(d) % eulerphi(d)), n-d)); \\ Michel Marcus, Apr 30 2023

Formula

a(n) = Sum_{d|n} (n-d) * A351114(d).
a(n) = n*A351112(n) - A351113(n).

A386589 a(n) = Sum_{d|n} d^c(d), where c = A351114.

Original entry on oeis.org

1, 3, 4, 4, 2, 12, 2, 5, 5, 5, 2, 25, 2, 18, 20, 6, 2, 14, 2, 7, 6, 5, 2, 27, 3, 5, 6, 20, 2, 59, 2, 7, 6, 5, 38, 28, 2, 5, 6, 9, 2, 70, 2, 7, 22, 5, 2, 29, 3, 7, 6, 7, 2, 16, 4, 77, 6, 5, 2, 74, 2, 5, 8, 8, 4, 16, 2, 7, 6, 125, 2, 31, 2, 5, 22, 7, 4, 93, 2, 11, 7, 5, 2, 85, 4, 5, 6, 9, 2, 63, 4, 7, 6, 5, 4, 31, 2, 20, 8, 10
Offset: 1

Views

Author

Wesley Ivan Hurt, Jul 26 2025

Keywords

Comments

Inverse Möbius transform of n^c(n), where c = A351114.
For each divisor d of n, add d if d is a balanced number (A020492), else add 1.

Crossrefs

Cf. A000005 (tau), A020492 (balanced numbers), A351112, A351113, A351114.

Programs

  • Mathematica
    Table[Sum[d^(1 - Ceiling[DivisorSigma[1, d]/EulerPhi[d]] + Floor[DivisorSigma[1, d]/EulerPhi[d]]), {d, Divisors[n]}], {n, 100}]

Formula

a(n) = Sum_{d|n} 1 + (d - 1)*c(d), where c = A351114.
a(n) = A000005(n) + A351113(n) - A351112(n).
Showing 1-4 of 4 results.