End CGAdd.
(*s Properties of the range of the graph *)
Definition cg_range := DMerge D.

(* Specifications: *)
Lemma cg_range_1 :
forall (cg : CGraph1) (x y : ad) (d : D),
CG_edge cg x y = Some d -> in_dom D y (cg_range cg) = true.
Lemma cg_range_2 :
forall (cg : CGraph1) (y : ad),
in_dom D y (cg_range cg) = true ->
{x : ad &  {d : D | CG_edge cg x y = Some d}}.
Lemma cg_range_4 :
forall (cg : CGraph1) (x y : ad) (d : D) (a : ad),
in_dom D a (cg_range (CG_add cg x y d)) =
Neqb a y || in_dom D a (cg_range cg).
Lemma cg_out_of_range_1 :
forall (cg : CGraph1) (y : ad),
in_dom D y (cg_range cg) = false -> forall x : ad, CG_edge cg x y = None.
Lemma cg_out_of_range_2 :
forall (cg : CGraph1) (y : ad),
in_dom D y (cg_range cg) = false ->
forall x : ad, Neqb x y = false -> ad_simple_path_dist cg x y = None.
Lemma cg_out_of_range_3 :
forall (cg : CGraph1) (y : ad),
in_dom D y (cg_range cg) = false ->
forall x : ad, Neqb x y = false -> CG_leq cg x y = false.
Lemma cg_add_out_of_range_1 :
forall (cg : CGraph1) (x y : ad) (d : D),
(forall (x0 : ad) (d0 : D) (l : list ad),
CG_path cg x0 d0 (x0 :: l) -> Dle Dz d0 = true) ->
in_dom D x (cg_range cg) = false ->
Neqb y x = false ->
forall (x0 : ad) (d0 : D) (l : list ad),
CG_path (CG_add cg x y d) x0 d0 (x0 :: l) -> Dle Dz d0 = true.
Lemma cg_add_dom_subset :
forall (cg : CGraph1) (x y : ad) (d : D),
MapSubset _ _ (MapDom _ cg) (MapDom _ (CG_add cg x y d)).