Definition gcd (a b : nat) := proj1_sig (gcd_ex a b).

(* Specifications: *)
Lemma gcd_correct : forall a b : nat, gcd_spec a b (gcd a b).
Lemma gcd_spec_uniq : forall a b r1 r2 : nat, gcd_spec a b r1 -> gcd_spec a b r2 -> r1 = r2.
Lemma gcd_correct2 : forall a b r : nat, gcd_spec a b r -> gcd a b = r.
Lemma gcd_def0l : forall x : nat, gcd 0 x = x.
Lemma gcd_def0r : forall x : nat, gcd x 0 = x.
Lemma gcd_def1 : forall x : nat, gcd x x = x.
Lemma gcd_def2 : forall a b : nat, gcd a b = gcd a (b + a).
Lemma gcd_def3 : forall a b : nat, gcd a b = gcd (a + b) b.
Lemma gcd_is_gcd : forall a b : nat, is_gcd a b (gcd a b).
Lemma preEuclid : forall a b c m : nat, divides c (m * a) -> divides c (m * b) -> divides c (m * gcd a b).
Theorem L_Euclides : forall x a b : nat, is_gcd x a 1 -> divides x (a * b) -> divides x b.
Lemma L_Euclides1 : forall p a b : nat, prime p -> divides p (a * b) -> ~ divides p a -> divides p b.
Lemma L_Euclides2 : forall p a b : nat, prime p -> divides p (a * b) -> divides p a \/ divides p b.
Theorem div_power_prime : forall p w n : nat, prime p -> divides p (power w n) -> divides p w.