}.
nrecord magma (A: magma_type) : Type[1] ≝
- { mcarr:> powerset_setoid1 A;
+ { mcarr:> Ω \sup A;
op_closed: ∀x,y. x ∈ mcarr → y ∈ mcarr → op A x y ∈ mcarr
}.
(* le coercion non vanno; sospetto setoid1_of_setoid *)
mmclosed: ∀x:carr A. x ∈ mcarr ? Ma → mmmcarr x ∈ mcarr ? Mb
}.
(*
-(* 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 mm_image:
∀A,B. ∀Ma: magma A. ∀Mb: magma B. magma_morphism … Ma Mb → magma B.
#A; #B; #Ma; #Mb; #f;
napply (mmprop … f)]##]
nqed.
-ndefinition counter_image: ∀A,B. (A → B) → Ω \sup B → Ω \sup A ≝
- λA,B,f,Sb. {x | ∃y. y ∈ Sb ∧ f x = y}.
-
ndefinition mm_counter_image:
∀A,B. ∀Ma: magma A. ∀Mb: magma B. magma_morphism … Ma Mb → magma A.
#A; #B; #Ma; #Mb; #f;
-sets/sets.ma sets/setoids.ma sets/setoids1.ma
+sets/sets.ma logic/cprop.ma
logic/cprop.ma sets/setoids1.ma
sets/setoids1.ma properties/relations1.ma sets/setoids.ma
sets/setoids.ma logic/connectives.ma properties/relations.ma
logic/equality.ma logic/connectives.ma
logic/connectives.ma logic/pts.ma
-algebra/magmas.ma sets/setoids.ma
+algebra/magmas.ma sets/sets.ma
properties/relations1.ma logic/pts.ma
properties/relations.ma logic/pts.ma
logic/pts.ma
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}.
+*)