A378639 a(n) = sum of all m such that phi(m) divides n, where phi is the Euler totient function (A000010).
3, 16, 3, 51, 3, 64, 3, 156, 3, 49, 3, 265, 3, 16, 3, 387, 3, 202, 3, 302, 3, 85, 3, 991, 3, 16, 3, 138, 3, 190, 3, 968, 3, 16, 3, 1058, 3, 16, 3, 1240, 3, 340, 3, 419, 3, 157, 3, 2736, 3, 49, 3, 210, 3, 445, 3, 620, 3, 193, 3, 1723, 3, 16, 3, 2283, 3, 334, 3, 51, 3, 262
Offset: 1
Keywords
Links
- Paolo Xausa, Table of n, a(n) for n = 1..1000
Programs
-
Maple
f:= proc(n) local d; if n::odd then return 3 fi; 3+add(convert(numtheory:-invphi(d),`+`), d = select(type,numtheory:-divisors(n),even)) end proc: map(f, [$1..100]); # Robert Israel, Dec 05 2024
-
Mathematica
With[{nmax = 100}, Table[If[OddQ[n], 3, Total[PositionIndex[Divisible[n, #[[;; Max[n^2, 6]]]]][True]]], {n, nmax}] & [EulerPhi[Range[nmax^2]]]]
-
PARI
a(n) = vecsum(select(x->!(n % eulerphi(x)), [1..max(n^2, 6)])); \\ Michel Marcus, Dec 05 2024
Formula
a(2*k+1) = 3, for k >= 0.