Ramanujan sums over the divisors give the complete sum
ProvedVino.sum_divisors_ramanujananalytic-number-theorycircle-methodnumber-theoryramanujan-sums
For every and every integer ,
Every residue belongs to exactly one class , and each class contributes ; summing over therefore recovers the complete exponential sum , which orthogonality evaluates.
This is the divisor-sum relation from which Kluyver's formula for follows by Möbius inversion. It also exhibits as the Möbius transform of the elementary function , which is where the multiplicativity in ultimately comes from.
Preamble
import Definitions.Def_Vino_ramanujan import Mathlib.NumberTheory.Divisors import Mathlib.NumberTheory.ArithmeticFunction.Moebius import Mathlib.Data.Nat.Totient open Finset
Formal statement
namespace Vino
theorem sum_divisors_ramanujan {q : ℕ} (hq : 0 < q) (n : ℤ) :
∑ d ∈ q.divisors, ramanujan d n = if (q : ℤ) ∣ n then (q : ℂ) else 0 := by sorry
end VinoSource
G. H. Hardy and E. M. Wright, An Introduction to the Theory of Numbers, 6th ed., Oxford University Press, 2008, Section 16.6, Theorem 271 (Ramanujan's sum c_q(n) = sum over d | gcd(q,n) of d * mu(q/d)); J. C. Kluyver, Some formulae concerning the integers less than n and prime to n, Proc. Royal Netherlands Academy 9 (1906), 408-414.