OFFSET
1,3
COMMENTS
The harmonic residue is the remainder when n*d(n) is divided by sigma(n), where d(n) is the number of divisors of n and sigma(n) is the sum of the divisors of n. If n is perfect, the harmonic residue of n is 0.
LINKS
Reinhard Zumkeller, Table of n, a(n) for n = 1..10000
FORMULA
MAPLE
A106315 := proc(n)
modp(n*numtheory[tau](n), numtheory[sigma](n)) ;
end proc:
seq(A106315(n), n=1..100) ; # R. J. Mathar, Jan 25 2017
MATHEMATICA
HarmonicResidue[n_]=Mod[n*DivisorSigma[0, n], DivisorSigma[1, n]]; HarmonicResidue[ Range[ 80]]
PROG
(Haskell)
a106315 n = n * a000005 n `mod` a000203 n -- Reinhard Zumkeller, Apr 06 2014
CROSSREFS
KEYWORD
nonn
AUTHOR
George J. Schaeffer (gschaeff(AT)andrew.cmu.edu), Apr 29 2005
EXTENSIONS
Mathematica program completed by Harvey P. Dale, Feb 29 2024
STATUS
approved