proposition: Lemma EnumSplit: forall U (P Q R: Ensemble U), (forall x, P x -> {Q x} + {R x}) -> Prop_join Q R P -> Enumerable U P -> Enumerable U Q * Enumerable U R.
proof: Proof. intros U P Q R ? [? ?] ?. split. + apply EnumStrengthen with P; auto. - intros x HH; specialize (X x HH); specialize (H x); specialize (H0 x). apply sumbool_weaken_right with (R x); auto. - intros x; simpl; specialize (H x); tauto. + apply EnumStrengthen with P; auto. - intros x HH; specialize (X x HH); specialize (H x); specialize (H0 x). apply swap_sumbool. apply sumbool_weaken_left with (Q x); auto. - intros x; simpl; specialize (H x); tauto. Qed.
imports: Coq.Sorting.Permutation Coq.Classes.EquivDec CertiGraph.lib.Coqlib CertiGraph.lib.List_ext CertiGraph.lib.Ensembles_ext Coq.Lists.List