(* The  Intersection set   *)

Definition Inter (E : Ens) : Ens :=
  match E with
  | sup A f =>
      sup _
        (fun
           c : depprod _
                 (fun a : A =>
                  depprod _
                    (fun b : pi1 (f a) =>
                     forall x : A, IN (pi2 (f a) b) (f x))) =>
         match c with
         | dep_i a (dep_i b p) => pi2 (f a) b
         end)
  end.

(* Specifications: *)
Theorem IN_Inter_all : forall E E' : Ens, IN E' (Inter E) -> forall E'' : Ens, IN E'' E -> IN E' E''.
Theorem all_IN_Inter : forall E E' E'' : Ens, IN E'' E -> (forall E'' : Ens, IN E'' E -> IN E' E'') -> IN E' (Inter E).
Theorem IN_Inter_all : forall E E' : Ens, IN E' (Inter E) -> forall E'' : Ens, IN E'' E -> IN E' E''.
Theorem all_IN_Inter : forall E E' E'' : Ens, IN E'' E -> (forall E'' : Ens, IN E'' E -> IN E' E'') -> IN E' (Inter E).