[ napply (Ω \sup S)
| napply mk_equivalence_relation1
[ #A; #B; napply (∀x. iff (x ∈ A) (x ∈ B))
- | nnormalize; #x; #x0; napply mk_iff; #H; nassumption
- | nnormalize; #x; #y; #H; #A; napply mk_iff; #K
+ | nwhd; #x; #x0; napply mk_iff; #H; nassumption
+ | nwhd; #x; #y; #H; #A; napply mk_iff; #K
[ napply (fi ?? (H ?)) | napply (if ?? (H ?)) ]
nassumption
- | nnormalize; #A; #B; #C; #H1; #H2; #H3; napply mk_iff; #H4
+ | nwhd; #A; #B; #C; #H1; #H2; #H3; napply mk_iff; #H4
[ napply (if ?? (H2 ?)); napply (if ?? (H1 ?)); nassumption
| napply (fi ?? (H1 ?)); napply (fi ?? (H2 ?)); nassumption]##]
nqed.
ndefinition intersects ≝ λA.λU,V:Ω \sup A. {x | x ∈ U ∧ x ∈ V }.
#a; #a'; #H; napply mk_iff; *; #H1; #H2
- [ napply (. ((H^-1‡#)‡(H^-1‡#))); nnormalize; napply conj; nassumption
- | napply (. ((H‡#)‡(H‡#))); nnormalize; napply conj; nassumption]
+ [ napply (. ((H^-1‡#)‡(H^-1‡#))); nwhd; napply conj; nassumption
+ | napply (. ((H‡#)‡(H‡#))); nwhd; napply conj; nassumption]
nqed.
(*interpretation "intersects" 'intersects U V = (intersects ? U V).*)
ndefinition singleton ≝ λA:setoid.λa:A.{b | a=b}.
-interpretation "singleton" 'singl a = (singleton ? a).*)
\ No newline at end of file
+interpretation "singleton" 'singl a = (singleton ? a).*)
+
+(*
+(* qui non funziona una cippa *)
+ndefinition image: ∀A,B. (carr A → carr B) → Ω \sup A → Ω \sup B ≝
+ λA,B:setoid.λf:carr A → carr B.λSa:Ω \sup A.
+ {y | ∃x. x ∈ Sa ∧ eq_rel (carr B) (eq B) ? ?(*(f x) y*)}.
+ ##[##2: napply (f x); ##|##3: napply y]
+ #a; #a'; #H; nwhd; nnormalize; (* per togliere setoid1_of_setoid *) napply (mk_iff ????);
+ *; #x; #Hx; napply (ex_intro … x)
+ [ napply (. (#‡(#‡#)));
+
+ndefinition counter_image: ∀A,B. (A → B) → Ω \sup B → Ω \sup A ≝
+ λA,B,f,Sb. {x | ∃y. y ∈ Sb ∧ f x = y}.
+*)