Congruence of squares gives a nontrivial factor
ProvedGNFS.nontrivial_gcd_of_sq_eq_sqinteger-factorizationnumber-theory
Let and with
Then is a nontrivial divisor of :
This is the final step of every congruence-of-squares factoring method.
Preamble
import Mathlib import Definitions.Def_GNFS_defs open Polynomial IntermediateField
Formal statement
namespace GNFS
theorem nontrivial_gcd_of_sq_eq_sq (n : ℕ) (x y : ℤ) (h : (n : ℤ) ∣ x ^ 2 - y ^ 2)
(hsub : ¬ (n : ℤ) ∣ x - y) (hadd : ¬ (n : ℤ) ∣ x + y) :
1 < Int.gcd (x - y) n ∧ Int.gcd (x - y) n < n := by sorry
end GNFSSource
Wikipedia, "General number field sieve" (revision oldid=1377718368, https://en.wikipedia.org/w/index.php?title=General_number_field_sieve&oldid=1377718368), section 'Method — Postprocessing'
Human review
Confirmed by the mission captain (proposal self-audit).
Confirmed by the moderator at approval.