login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A351116
Sum of the balanced numbers <= n.
1
1, 3, 6, 6, 6, 12, 12, 12, 12, 12, 12, 24, 24, 38, 53, 53, 53, 53, 53, 53, 53, 53, 53, 53, 53, 53, 53, 53, 53, 83, 83, 83, 83, 83, 118, 118, 118, 118, 118, 118, 118, 160, 160, 160, 160, 160, 160, 160, 160, 160, 160, 160, 160, 160, 160, 216, 216, 216, 216, 216, 216, 216
OFFSET
1,2
COMMENTS
A balanced number k is a number such that phi(k) | sigma(k).
LINKS
FORMULA
a(n) = Sum_{k<=n, phi(k)|sigma(k)} k.
a(n) = Sum_{k=1..n} k * c(k), where c is the characteristic function of balanced numbers (A351114).
EXAMPLE
a(15) = 53; the sum of the balanced numbers <= 15 is 1+2+3+6+12+14+15 = 53.
MATHEMATICA
f[n_] := n * Boole[Divisible[DivisorSigma[1, n], EulerPhi[n]]]; Accumulate @ Array[f, 100] (* Amiram Eldar, Feb 01 2022 *)
Accumulate[Table[If[Divisible[DivisorSigma[1, n], EulerPhi[n]], n, 0], {n, 70}]] (* Harvey P. Dale, May 09 2022 *)
PROG
(PARI) a(n) = sum(k=1, n, if (!(sigma(k) % eulerphi(k)), k)); \\ Michel Marcus, Feb 01 2022
CROSSREFS
Cf. A000010 (phi), A000203 (sigma), A020492 (balanced numbers), A351114, A351115.
Sequence in context: A358548 A155067 A094011 * A295558 A295559 A161645
KEYWORD
nonn
AUTHOR
Wesley Ivan Hurt, Jan 31 2022
STATUS
approved