Congruence mod p gives divisibility of the absolute difference
Provedgpy_prime_dvd_natAbs_diff_of_modEqnumber-theory
A congruence a congruent to b modulo a prime p implies p divides the absolute value of the integer difference a - b, proved by cases on the order of a and b. Pure Mathlib statement.
Preamble
import Mathlib open Classical
Formal statement
theorem gpy_prime_dvd_natAbs_diff_of_modEq {p : ℕ} (_hp : Nat.Prime p)
{a b : ℕ} (hcong : a ≡ b [MOD p]) :
p ∣ Int.natAbs ((a : ℤ) - (b : ℤ)) := by sorrySource
GPY defect control: exact characterizations and exact sum identities for the compatible-but-not-good (defect) pairs