X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2Fsoftware%2Fmatita%2Fnlibrary%2Fsets%2Fsets.ma;h=3e63bf8f2574fee8eba104a243c6176e83832e39;hb=2dc6ec0db2156431948014a6498c9901f8759e39;hp=239d9765989b05867a552d217c32acc564002152;hpb=c6d3537eee27d05490a9555cc7326bc954b356c5;p=helm.git diff --git a/helm/software/matita/nlibrary/sets/sets.ma b/helm/software/matita/nlibrary/sets/sets.ma index 239d97659..3e63bf8f2 100644 --- a/helm/software/matita/nlibrary/sets/sets.ma +++ b/helm/software/matita/nlibrary/sets/sets.ma @@ -34,9 +34,9 @@ interpretation "intersect" 'intersects U V = (intersect ? U V). ndefinition union ≝ λA.λU,V:Ω \sup A.{ x | x ∈ U ∨ x ∈ V }. interpretation "union" 'union U V = (union ? U V). -ndefinition big_union ≝ λA.λT:Type[0].λf:T → Ω \sup A.{ x | ∃i. x ∈ f i }. +ndefinition big_union ≝ λA,B.λT:Ω \sup A.λf:A → Ω \sup B.{ x | ∃i. i ∈ T ∧ x ∈ f i }. -ndefinition big_intersection ≝ λA.λT:Type[0].λf:T → Ω \sup A.{ x | ∀i. x ∈ f i }. +ndefinition big_intersection ≝ λA,B.λT:Ω \sup A.λf:A → Ω \sup B.{ x | ∀i. i ∈ T → x ∈ f i }. ndefinition full_set: ∀A. Ω \sup A ≝ λA.{ x | True }. (* bug dichiarazione coercion qui *) @@ -80,6 +80,13 @@ nrecord qpowerclass (A: setoid) : Type[1] ≝ mem_ok': ∀x,x':A. x=x' → (x ∈ pc) = (x' ∈ pc) }. +ndefinition Full_set: ∀A. qpowerclass A. + #A; napply mk_qpowerclass + [ napply (full_set A) + | #x; #x'; #H; nnormalize in ⊢ (?%?%%); (* bug universi qui napply refl1;*) + napply mk_iff; #K; nassumption ] +nqed. + ndefinition qseteq: ∀A. equivalence_relation1 (qpowerclass A). #A; napply mk_equivalence_relation1 [ napply (λS,S':qpowerclass A. eq_rel1 ? (eq1 (powerclass_setoid A)) S S') @@ -198,16 +205,27 @@ nlemma first_omomorphism_theorem_functions1: #A; #B; #f; #x; napply refl; nqed. -ndefinition surjective ≝ λA,B.λf:unary_morphism A B. ∀y.∃x. f x = y. +ndefinition surjective ≝ + λA,B.λS: qpowerclass A.λT: qpowerclass B.λf:unary_morphism A B. + ∀y. y ∈ T → ∃x. x ∈ S ∧ f x = y. -ndefinition injective ≝ λA,B.λf:unary_morphism A B. ∀x,x'. f x = f x' → x = x'. +ndefinition injective ≝ + λA,B.λS: qpowerclass A.λf:unary_morphism A B. + ∀x,x'. x ∈ S → x' ∈ S → f x = f x' → x = x'. nlemma first_omomorphism_theorem_functions2: - ∀A,B.∀f: unary_morphism A B. surjective ?? (canonical_proj ? (eqrel_of_morphism ?? f)). - #A; #B; #f; nwhd; #y; napply (ex_intro … y); napply refl. + ∀A,B.∀f: unary_morphism A B. surjective ?? (Full_set ?) (Full_set ?) (canonical_proj ? (eqrel_of_morphism ?? f)). + #A; #B; #f; nwhd; #y; #Hy; napply (ex_intro … y); napply conj + [ napply I | napply refl] nqed. nlemma first_omomorphism_theorem_functions3: - ∀A,B.∀f: unary_morphism A B. injective ?? (quotiented_mor ?? f). - #A; #B; #f; nwhd; #x; #x'; #H; nassumption. + ∀A,B.∀f: unary_morphism A B. injective ?? (Full_set ?) (quotiented_mor ?? f). + #A; #B; #f; nwhd; #x; #x'; #Hx; #Hx'; #K; nassumption. nqed. + +nrecord isomorphism (A) (B) (S: qpowerclass A) (T: qpowerclass B) : CProp[0] ≝ + { iso_f:> unary_morphism A B; + f_sur: surjective ?? S T iso_f; + f_inj: injective ?? S iso_f + }.