Contents
Kummer.lean
Statement index · Original Lean file
1
import Thesis.ZetaValues23/-!4# Kummer's congruence (Theorem A): integrality and predicate-transfer layer5-/67namespace Thesis89open scoped BigOperators1011variable {p : ℕ} [Fact p.Prime]1213/-- The norm of a rational number in `ℂ_[p]` is its `p`-adic norm. -/14lemma norm_ratCast_complex (q : ℚ) : ‖((q : ℚ_[p]) : ℂ_[p])‖ = (padicNorm p q : ℝ) := by15 rw [PadicComplex.norm_extends', Padic.eq_padicNorm]1617/-- Integers are `p`-adically integral. -/18lemma padicIntegral_rat_intCast (z : ℤ) : PadicIntegral p (((z : ℚ) : ℚ_[p]) : ℂ_[p]) := by19 rw [PadicIntegral, norm_ratCast_complex]20 exact_mod_cast padicNorm.of_int z2122/-- A rational number whose denominator is prime to `p` has `p`-adic norm at most one. -/23lemma padicNorm_rat_le_one (q : ℚ) (hq : ¬ p ∣ q.den) : padicNorm p q ≤ 1 := by24 have hq' : q = (q.num : ℚ) / (q.den : ℚ) := (Rat.num_div_den q).symm25 rw [hq', padicNorm.div]26 have hden : padicNorm p ((q.den : ℚ)) = 1 := by27 rw [padicNorm.nat_eq_one_iff]28 exact hq29 rw [hden, div_one]30 exact padicNorm.of_int q.num3132/-- A rational number whose denominator is prime to `p` is `p`-adically integral. -/33lemma padicIntegral_rat_of_not_dvd_den (q : ℚ) (hq : ¬ p ∣ q.den) :34 PadicIntegral p ((q : ℚ_[p]) : ℂ_[p]) := by35 rw [PadicIntegral, norm_ratCast_complex]36 exact_mod_cast padicNorm_rat_le_one q hq3738/-- Integrality transfers backwards along a residue congruence. -/39lemma padicIntegral_of_residueModEq {x y : ℂ_[p]} (h : ResidueModEq p x y)40 (hy : PadicIntegral p y) : PadicIntegral p x := by41 have key : ‖x‖ ≤ max ‖x - y‖ ‖y‖ := by42 have := PadicComplex.isNonarchimedean p (x - y) y43 rwa [sub_add_cancel] at this44 exact key.trans (max_le (le_of_lt h) hy)4546/-- On `ℚ` the `p`-adic norm only takes powers of `p`, so a strict inequality47with `1` upgrades to `≤ p⁻¹`. -/48lemma padicNorm_le_inv_of_lt_one {c : ℚ} (hc : padicNorm p c < 1) :49 padicNorm p c ≤ (p : ℚ)⁻¹ := by50 rcases eq_or_ne c 0 with rfl | hc051 · simp52 obtain ⟨z, hz⟩ := padicNorm.values_discrete hc053 rw [hz] at hc ⊢54 have hp1 : (1 : ℚ) < p := by exact_mod_cast (Fact.out : p.Prime).one_lt55 have hzpos : 1 ≤ z := by56 by_contra h57 have h0 : z ≤ 0 := by omega58 have hle : (p : ℚ) ^ (0 : ℤ) ≤ (p : ℚ) ^ (-z) :=59 zpow_le_zpow_right₀ hp1.le (by omega)60 simp only [zpow_zero] at hle61 linarith62 calc (p : ℚ) ^ (-z) ≤ (p : ℚ) ^ (-1 : ℤ) := zpow_le_zpow_right₀ hp1.le (by omega)63 _ = (p : ℚ)⁻¹ := by simp6465/-- Dividing by `p` restores integrality of a rational with norm `< 1`. -/66lemma padicNorm_div_p_le_one {c : ℚ} (hc : padicNorm p c < 1) : padicNorm p (c / p) ≤ 1 := by67 have hp1 : (1 : ℚ) < p := by exact_mod_cast (Fact.out : p.Prime).one_lt68 rw [padicNorm.div, padicNorm.padicNorm_p_of_prime, div_inv_eq_mul]69 calc padicNorm p c * (p : ℚ) ≤ (p : ℚ)⁻¹ * p :=70 mul_le_mul_of_nonneg_right (padicNorm_le_inv_of_lt_one hc) (by positivity)71 _ = 1 := by field_simp7273/-- For rational values the strict residue congruence upgrades to congruence modulo `p`. -/74lemma padicModEq_one_of_residueModEq_rat {a b : ℚ}75 (h : ResidueModEq p ((a : ℚ_[p]) : ℂ_[p]) ((b : ℚ_[p]) : ℂ_[p])) :76 PadicModEq p 1 ((a : ℚ_[p]) : ℂ_[p]) ((b : ℚ_[p]) : ℂ_[p]) := by77 have hsub : ((a : ℚ_[p]) : ℂ_[p]) - ((b : ℚ_[p]) : ℂ_[p]) =78 (((a - b : ℚ) : ℚ_[p]) : ℂ_[p]) := by79 push_cast80 ring81 have hc : padicNorm p (a - b) < 1 := by82 have h' := h83 rw [ResidueModEq, hsub, norm_ratCast_complex] at h'84 exact_mod_cast h'85 have hpnorm : ‖((p : ℕ) : ℂ_[p])‖ = ((p : ℚ)⁻¹ : ℝ) := by86 have e : ((p : ℕ) : ℂ_[p]) = (((p : ℚ) : ℚ_[p]) : ℂ_[p]) := by87 push_cast88 ring89 rw [e, norm_ratCast_complex, padicNorm.padicNorm_p_of_prime]90 norm_num91 have hpnormpos : (0 : ℝ) < ‖((p : ℕ) : ℂ_[p])‖ := by92 rw [hpnorm]93 have hp0 : (0 : ℚ) < p := by exact_mod_cast (Fact.out : p.Prime).pos94 exact_mod_cast inv_pos.mpr hp095 rw [PadicModEq, pow_one, PadicIntegral, norm_div, hsub, norm_ratCast_complex,96 div_le_one hpnormpos, hpnorm]97 have hle := padicNorm_le_inv_of_lt_one hc98 exact_mod_cast hle99100101/-- `p = 2` is excluded by the hypothesis `¬ (p - 1) ∣ M`. -/102lemma prime_ne_two_of_not_dvd_pred {M : ℕ} (hM : ¬ (p - 1) ∣ M) : p ≠ 2 := by103 rintro rfl104 exact hM (by simp)105106/-- von Staudt–Clausen: `B_M` is `p`-integral unless `p - 1 ∣ M`. -/107lemma padicIntegral_bernoulli_of_not_dvd (M : ℕ) (hM : ¬ (p - 1) ∣ M) :108 PadicIntegral p ((bernoulli M : ℚ_[p]) : ℂ_[p]) := by109 have hp2 : p ≠ 2 := prime_ne_two_of_not_dvd_pred hM110 rcases Nat.eq_zero_or_pos M with rfl | hpos111 · rw [bernoulli_zero]112 simp [PadicIntegral]113 rcases eq_or_ne M 1 with rfl | hM1114 · rw [bernoulli_one]115 refine padicIntegral_rat_of_not_dvd_den (-1 / 2) ?_116 have hden : ((-1 / 2 : ℚ)).den = 2 := by norm_num117 rw [hden]118 intro hd119 have hle : p ≤ 2 := Nat.le_of_dvd (by norm_num) hd120 have hge : 2 ≤ p := (Fact.out : p.Prime).two_le121 exact hp2 (by omega)122 have h2 : 2 ≤ M := by omega123 rcases Nat.even_or_odd M with hev | hod124 · obtain ⟨k, hk⟩ := hev125 have hMk : M = 2 * k := by omega126 subst hMk127 obtain ⟨z, hz⟩ := Bernoulli.vonStaudt_clausen k128 set S : ℚ := ∑ q ∈ (Finset.range (2 * k + 2)).filter (fun q ↦ q.Prime ∧ q - 1 ∣ 2 * k),129 (1 : ℚ) / q with hS130 have hB : bernoulli (2 * k) = (z : ℚ) - S := by131 rw [hS] at hz132 linarith133 have hcop : Nat.Coprime p (∏ q ∈ (Finset.range (2 * k + 2)).filter134 (fun q ↦ q.Prime ∧ q - 1 ∣ 2 * k), q) := by135 apply Nat.Coprime.prod_right136 intro q hq137 simp only [Finset.mem_filter, Finset.mem_range] at hq138 obtain ⟨-, hqp, hqd⟩ := hq139 have hpq : p ≠ q := by140 intro h141 exact hM (h ▸ hqd)142 exact (Nat.coprime_primes Fact.out hqp).mpr hpq143 have hdenS : ¬ p ∣ S.den := by144 intro hdvd145 have h1 : S.den ∣ ∏ q ∈ (Finset.range (2 * k + 2)).filter146 (fun q ↦ q.Prime ∧ q - 1 ∣ 2 * k), q := by147 rw [hS]148 have hprod : (∏ i ∈ (Finset.range (2 * k + 2)).filter149 (fun q ↦ q.Prime ∧ q - 1 ∣ 2 * k), ((1 : ℚ) / (i : ℚ)).den) =150 ∏ i ∈ (Finset.range (2 * k + 2)).filter (fun q ↦ q.Prime ∧ q - 1 ∣ 2 * k), i := by151 apply Finset.prod_congr rfl152 intro i hi153 simp only [Finset.mem_filter, Finset.mem_range] at hi154 simp [hi.2.1.ne_zero]155 have hkey := Finset.Rat.den_sum_dvd_prod_den156 ((Finset.range (2 * k + 2)).filter (fun q ↦ q.Prime ∧ q - 1 ∣ 2 * k))157 (fun q : ℕ ↦ (1 : ℚ) / q)158 rw [hprod] at hkey159 simpa using hkey160 have h2 : p ∣ ∏ q ∈ (Finset.range (2 * k + 2)).filter161 (fun q ↦ q.Prime ∧ q - 1 ∣ 2 * k), q := hdvd.trans h1162 have h3 : p = 1 := Nat.Coprime.eq_one_of_dvd hcop h2163 exact (Fact.out : p.Prime).ne_one h3164 have hdenB : ¬ p ∣ (bernoulli (2 * k)).den := by165 intro hdvd166 have hsub : (bernoulli (2 * k)).den ∣ ((z : ℚ)).den * S.den := by167 rw [hB]168 exact Rat.sub_den_dvd _ _169 rw [Rat.den_intCast, one_mul] at hsub170 exact hdenS (hdvd.trans hsub)171 exact padicIntegral_rat_of_not_dvd_den _ hdenB172 · rw [bernoulli_eq_zero_of_odd hod (by omega)]173 simpa using padicIntegral_zero p174175176/-- Congruence modulo `p` is preserved by simultaneous negation. -/177lemma padicModEq_neg_neg {k : ℕ} {x y : ℂ_[p]} :178 PadicModEq p k (-x) (-y) ↔ PadicModEq p k x y := by179 have e : (-x) - (-y) = -(x - y) := by ring180 rw [PadicModEq, PadicModEq, e, neg_div, PadicIntegral, PadicIntegral, norm_neg]181182/-- `B_M / M` is `p`-integral when `p ∤ M` and `p - 1 ∤ M`. -/183lemma padicIntegral_bernoulli_div_of_not_dvd (M : ℕ) (hM : ¬ (p - 1) ∣ M)184 (hMp : ¬ p ∣ M) : PadicIntegral p (((bernoulli M / M : ℚ) : ℚ_[p]) : ℂ_[p]) := by185 have hM0 : M ≠ 0 := by rintro rfl; exact hMp (dvd_zero p)186 rw [PadicIntegral, norm_ratCast_complex]187 have hB : padicNorm p (bernoulli M) ≤ 1 := by188 have h := padicIntegral_bernoulli_of_not_dvd M hM189 rw [PadicIntegral, norm_ratCast_complex] at h190 exact_mod_cast h191 have hMn : padicNorm p ((M : ℕ) : ℚ) = 1 := by192 rw [padicNorm.nat_eq_one_iff]193 exact hMp194 rw [padicNorm.div, hMn, div_one]195 exact_mod_cast hB196197/-- The value `B_M / M` of Theorem A, written as a rational cast. -/198noncomputable def bernValue (M : ℕ) : ℂ_[p] := (((bernoulli M / M : ℚ) : ℚ_[p]) : ℂ_[p])199200lemma padicIntegral_neg_iff {x : ℂ_[p]} : PadicIntegral p (-x) ↔ PadicIntegral p x := by201 rw [PadicIntegral, PadicIntegral, norm_neg]202203/-- `B_M / M` is `p`-integral when `p ∤ M` and `p - 1 ∤ M`. -/204lemma padicIntegral_bernValue_of_not_dvd (M : ℕ) (hM : ¬ (p - 1) ∣ M) (hMp : ¬ p ∣ M) :205 PadicIntegral p (bernValue M) := by206 have h := padicIntegral_bernoulli_div_of_not_dvd M hM hMp207 simpa [bernValue] using h208209/-- A good companion index: congruent to `M` mod `p - 1` but not divisible by `p`. -/210lemma exists_good_index (M : ℕ) (hM2 : 2 ≤ M) (hev : Even M) (hM : ¬ (p - 1) ∣ M) :211 ∃ N : ℕ, 2 ≤ N ∧ Even N ∧ ¬ (p - 1) ∣ N ∧ ¬ p ∣ N ∧212 Int.ModEq ((p - 1 : ℕ) : ℤ) (M : ℤ) (N : ℤ) := by213 have hp2 : p ≠ 2 := prime_ne_two_of_not_dvd_pred hM214 have hpodd : Odd p := (Fact.out : p.Prime).odd_of_ne_two hp2215 refine ⟨M + (p - 1) * (M + 1), by omega, ?_, ?_, ?_, ?_⟩216 · obtain ⟨k, hk⟩ := hev217 obtain ⟨j, hj⟩ := hpodd218 have hsub : p - 1 = j + j := by omega219 refine ⟨k + j * (M + 1), ?_⟩220 rw [hk, hsub]221 ring222 · intro hd223 have hdm : ((p - 1 : ℕ) : ℤ) ∣ ((p - 1 : ℕ) : ℤ) * ((M : ℤ) + 1) := dvd_mul_right _ _224 have hd' : ((p - 1 : ℕ) : ℤ) ∣ (M : ℤ) + ((p - 1 : ℕ) : ℤ) * ((M : ℤ) + 1) := by225 exact_mod_cast hd226 have h2 : ((p - 1 : ℕ) : ℤ) ∣ (M : ℤ) := by227 have h3 := dvd_sub hd' hdm228 simpa using h3229 exact hM (by exact_mod_cast h2)230 · intro hd231 have hN1 : M + (p - 1) * (M + 1) + 1 = (M + 1) * p := by232 obtain ⟨j, hj⟩ := hpodd233 have hsub : p - 1 = j + j := by omega234 rw [hsub, hj]235 ring236 have h1 : p ∣ M + (p - 1) * (M + 1) + 1 := ⟨M + 1, by rw [hN1, Nat.mul_comm]⟩237 have h2 : p ∣ 1 := by238 have hsub2 : M + (p - 1) * (M + 1) + 1 - (M + (p - 1) * (M + 1)) = 1 := by omega239 have h3 : p ∣ M + (p - 1) * (M + 1) + 1 - (M + (p - 1) * (M + 1)) :=240 Nat.dvd_sub h1 hd241 rwa [hsub2] at h3242 have hle := Nat.le_of_dvd (by norm_num) h2243 have hge := (Fact.out : p.Prime).two_le244 omega245 · rw [Int.modEq_iff_dvd]246 have he : (((M + (p - 1) * (M + 1) : ℕ)) : ℤ) - (M : ℤ) =247 ((p - 1 : ℕ) : ℤ) * ((M : ℤ) + 1) := by248 push_cast249 ring250 rw [he]251 exact dvd_mul_right _ _252253/-- The classical Kummer congruence in residue form, for even indices and254`(p - 1) ∤ M`. -/255def KummerResidue (p : ℕ) [Fact p.Prime] : Prop :=256 ∀ M N : ℕ, Even M → 2 ≤ M → ¬ (p - 1) ∣ M →257 Int.ModEq ((p - 1 : ℕ) : ℤ) (M : ℤ) (N : ℤ) →258 ResidueModEq p (bernValue M) (bernValue N)259260/-- The integrality half of Kummer's congruence follows from its congruence half261and von Staudt–Clausen: transfer integrality from a companion index prime to `p`. -/262lemma padicIntegral_bernValue_of_kummer (hK : KummerResidue p) (M : ℕ) (hev : Even M)263 (hM2 : 2 ≤ M) (hM : ¬ (p - 1) ∣ M) : PadicIntegral p (bernValue M) := by264 obtain ⟨N, hN2, hNe, hNd, hNp, hmod⟩ := exists_good_index M hM2 hev hM265 exact padicIntegral_of_residueModEq (hK M N hev hM2 hM hmod)266 (padicIntegral_bernValue_of_not_dvd N hNd hNp)267268/-- The value `B_M / M` as an element of `ℂ_[p]`. -/269lemma bernoulli_div_cast (M : ℕ) :270 (((bernoulli M / M : ℚ) : ℚ_[p]) : ℂ_[p]) = (bernoulli M : ℂ_[p]) / (M : ℂ_[p]) := by271 have e1 : (((bernoulli M / M : ℚ) : ℚ_[p]) : ℂ_[p]) = ((bernoulli M / M : ℚ) : ℂ_[p]) :=272 (IsScalarTower.algebraMap_apply ℚ ℚ_[p] ℂ_[p] (bernoulli M / M)).symm273 rw [e1, Rat.cast_div]274 push_cast275 ring276277278/-- **Theorem A (Kummer) reduced to its classical congruence form.**279The project's statement of Kummer's congruence follows from `KummerResidue`, the280classical `p - 1`-congruence of `B_M / M` for even `M`, together with281von Staudt–Clausen integrality. The integrality conjuncts are *derived* (they are282not extra hypotheses) by transferring integrality from a companion index `N ≡ M`283with `p ∤ N`. -/284theorem kummer_congruence_of_classical (hK : KummerResidue p) :285 ∀ {m n : ℕ} (hm : 0 < m) (hn : 0 < n) (hmo : Odd m) (hno : Odd n)286 (hmn : Int.ModEq ((p - 1 : ℕ) : ℤ) m n)287 (hmr : ¬ Int.ModEq ((p - 1 : ℕ) : ℤ) m (-1)),288 PadicIntegral p (riemannBernoulliValue p m) ∧289 PadicIntegral p (riemannBernoulliValue p n) ∧290 PadicModEq p 1 (riemannBernoulliValue p m) (riemannBernoulliValue p n) := by291 intro m n hm hn hmo hno hmn hmr292 have hMe : Even (m + 1) := hmo.add_odd odd_one293 have hNe : Even (n + 1) := hno.add_odd odd_one294 have hM2 : 2 ≤ m + 1 := by omega295 have hN2 : 2 ≤ n + 1 := by omega296 have hMnd : ¬ (p - 1) ∣ (m + 1) := by297 intro hd298 apply hmr299 rw [Int.modEq_iff_dvd]300 have h2 : ((p - 1 : ℕ) : ℤ) ∣ ((m : ℤ) + 1) := by exact_mod_cast hd301 have he : (-1 : ℤ) - (m : ℤ) = -((m : ℤ) + 1) := by ring302 rw [he]303 exact dvd_neg.mpr h2304 have hNnd : ¬ (p - 1) ∣ (n + 1) := by305 intro hd306 apply hMnd307 have h1 : ((p - 1 : ℕ) : ℤ) ∣ (n : ℤ) - (m : ℤ) := (Int.modEq_iff_dvd).mp hmn308 have h2 : ((p - 1 : ℕ) : ℤ) ∣ ((n : ℤ) + 1) := by exact_mod_cast hd309 have he : ((n : ℤ) + 1) - ((n : ℤ) - (m : ℤ)) = ((m : ℤ) + 1) := by ring310 have h3 : ((p - 1 : ℕ) : ℤ) ∣ ((m : ℤ) + 1) := by311 rw [← he]312 exact dvd_sub h2 h1313 exact_mod_cast h3314 have hMN : Int.ModEq ((p - 1 : ℕ) : ℤ) ((m + 1 : ℕ) : ℤ) ((n + 1 : ℕ) : ℤ) := by315 rw [Int.modEq_iff_dvd]316 have h1 : ((p - 1 : ℕ) : ℤ) ∣ (n : ℤ) - (m : ℤ) := (Int.modEq_iff_dvd).mp hmn317 have he : ((n + 1 : ℕ) : ℤ) - ((m + 1 : ℕ) : ℤ) = (n : ℤ) - (m : ℤ) := by318 push_cast319 ring320 rw [he]321 exact h1322 have hcong : ResidueModEq p (bernValue (p := p) (m + 1)) (bernValue (p := p) (n + 1)) :=323 hK (m + 1) (n + 1) hMe hM2 hMnd hMN324 have hintM : PadicIntegral p (bernValue (p := p) (m + 1)) :=325 padicIntegral_bernValue_of_kummer hK (m + 1) hMe hM2 hMnd326 have hintN : PadicIntegral p (bernValue (p := p) (n + 1)) :=327 padicIntegral_bernValue_of_kummer hK (n + 1) hNe hN2 hNnd328 have hmod : PadicModEq p 1 (bernValue (p := p) (m + 1)) (bernValue (p := p) (n + 1)) :=329 padicModEq_one_of_residueModEq_rat hcong330 have eM : riemannBernoulliValue p m = -(bernValue (p := p) (m + 1)) := by331 unfold riemannBernoulliValue bernValue332 rw [bernoulli_div_cast]333 push_cast334 rw [neg_div]335 have eN : riemannBernoulliValue p n = -(bernValue (p := p) (n + 1)) := by336 unfold riemannBernoulliValue bernValue337 rw [bernoulli_div_cast]338 push_cast339 rw [neg_div]340 refine ⟨?_, ?_, ?_⟩341 · rw [eM]342 exact padicIntegral_neg_iff.mpr hintM343 · rw [eN]344 exact padicIntegral_neg_iff.mpr hintN345 · rw [eM, eN]346 exact padicModEq_neg_neg.mpr hmod347348349/-- Unconditional half of Theorem A: if `p ∤ (m + 1)` (and `p - 1 ∤ (m + 1)`), the350negative odd zeta value `ζ(1 - m) = -B_{m+1}/(m+1)` is `p`-adically integral. -/351theorem padicIntegral_riemannBernoulliValue_of_not_dvd (m : ℕ) (hodd : Odd m)352 (hM : ¬ (p - 1) ∣ (m + 1)) (hMp : ¬ p ∣ (m + 1)) :353 PadicIntegral p (riemannBernoulliValue p m) := by354 have e : riemannBernoulliValue p m = -(bernValue (p := p) (m + 1)) := by355 unfold riemannBernoulliValue bernValue356 rw [bernoulli_div_cast]357 push_cast358 rw [neg_div]359 rw [e]360 exact padicIntegral_neg_iff.mpr (padicIntegral_bernValue_of_not_dvd (m + 1) hM hMp)361362363/-- `KummerResidue` is unchanged if the values `B_M / M` are written in `ℂ_[p]` as364`(B_M : ℂ_[p]) / (M : ℂ_[p])` rather than as rational casts. -/365lemma kummerResidue_iff_div_form :366 KummerResidue p ↔367 ∀ M N : ℕ, Even M → 2 ≤ M → ¬ (p - 1) ∣ M →368 Int.ModEq ((p - 1 : ℕ) : ℤ) (M : ℤ) (N : ℤ) →369 ResidueModEq p ((bernoulli M : ℂ_[p]) / (M : ℂ_[p]))370 ((bernoulli N : ℂ_[p]) / (N : ℂ_[p])) := by371 constructor372 · intro hK M N hM hM2 hMnd hMN373 rw [← bernoulli_div_cast M, ← bernoulli_div_cast N]374 exact hK M N hM hM2 hMnd hMN375 · intro hK M N hM hM2 hMnd hMN376 unfold bernValue377 rw [bernoulli_div_cast M, bernoulli_div_cast N]378 exact hK M N hM hM2 hMnd hMN379380/-- At `p = 3` the hypotheses of Theorem A are contradictory: `m` odd already381forces `m ≡ -1 (mod p - 1)`. So the printed statement carries no content at382`p = 3`, and isolating `KummerResidue` loses nothing there. -/383theorem kummer_hypotheses_vacuous_at_three (m : ℕ) (hm : Odd m) :384 Int.ModEq ((3 - 1 : ℕ) : ℤ) (m : ℤ) (-1) := by385 have h2 : (2 : ℤ) ∣ (m : ℤ) + 1 := by386 have := hm387 obtain ⟨k, hk⟩ := hm388 have : (m : ℤ) + 1 = 2 * ((k : ℤ) + 1) := by389 push_cast [Nat.cast_add, hk]390 ring391 rw [this]392 exact dvd_mul_right _ _393 rw [Int.modEq_iff_dvd]394 have he : (-1 : ℤ) - (m : ℤ) = -((m : ℤ) + 1) := by ring395 rw [he]396 exact dvd_neg.mpr h2397398end Thesis