(** we now show that gcd(a,b) exists for all a and b (we even have an algorithm) *)
Definition f (x:nat*nat) := (fst x)+(snd x).Definition R (x y:nat*nat) := (f x)<(f y).

(* Specifications: *)
Lemma Rwf : well_founded R.
Lemma gcd_exists_prod : forall (x:nat*nat),{d:nat | (is_gcd d (fst x) (snd x))}.
Theorem gcd_exists : forall (a b:nat),{d:nat | (is_gcd d a b)}.