is bounded by a sum over common divisors
ProvedDivisorSums.sqrt_gcd_le_sum_sqrt_common_divisorsThe square root of a gcd is dominated by the sum over all common divisors.
For and any ,
The greatest common divisor is itself one of the common divisors of and — it divides
, so it belongs to n.divisors, and it divides , so it survives the filter. Its
contribution is therefore one term of a sum whose every term is
non-negative, which gives the bound.
The value of the inequality is that it linearises the gcd. A weight depends on and jointly and resists interchange of summation; replacing it by a sum over common divisors turns it into a double sum whose inner variable can be summed first. That manoeuvre is routine in bounding Kloosterman-type sums and in sieve estimates where gcd weights appear after grouping residues by their common factor with the modulus.
Formalization note. n.divisors is empty when , which is why is assumed;
the filter selects those divisors of that also divide .
import Mathlib
namespace DivisorSums
theorem sqrt_gcd_le_sum_sqrt_common_divisors (n m : ℕ) (hn : n ≠ 0) :
Real.sqrt (Nat.gcd n m) ≤ ∑ d ∈ n.divisors.filter (· ∣ m), Real.sqrt d := by sorry
end DivisorSums