Module Type NLcmProp
(Import A : NAxiomsSig')
(Import B : NSubProp A)
(Import C : NDivProp A B)
(Import D : NGcdProp A B).
(** Divibility and modulo *)
(** Gcd of divided elements, for exact divisions *)
(** The following equality is crucial for Euclid algorithm *)
(** We now define lcm thanks to gcd:  lcm a b = a * (b / gcd a b) = (a / gcd a b) * b = (a*b) / gcd a b  Nota: [lcm 0 0] should be 0, which isn't guarantee with the third equation above. *)
Definition lcm a b := a*(b/gcd a b).
Instance lcm_wd : Proper (eq==>eq==>eq) lcm.

Lemma divide_div : forall a b c, a~=0 -> (a|b) -> (b|c) -> (b/a|c/a).