intros.
unfold indexed_intersection in |- *; simpl in |- *.
red in |- *; simpl in |- *; simpl in f.
intro a; split.
auto.
intros _ i; inversion_clear i.
simpl in subtype_prf.
contradiction.
Qed.
(** - Fully general intersections of (a set of) sets is introduced as follows: *)
Definition intersection :
forall A : Setoid, part_set (part_set A) -> part_set A.
intros A P.
simpl in |- *.
apply
Build_Predicate
with (fun a : A => forall p : part_set A, in_part p P -> in_part a p).
red in |- *; simpl in |- *.
intros.
apply in_part_comp_l with x; auto with algebra.
Defined.
Section intersection_v_indexed_intersection.

(* Specifications: *)
Lemma intersection_to_indexed_intersection :
forall (A I : Setoid) (f : MAP I (part_set A)),
Equal (intersection (range f)) (indexed_intersection f).