lemma ZFfunDom: "|dom| (ZFfun A B f) = A" by (auto simp add: ZFfun_def ZFfunDom_def Fst)
lemma ZFfunCod: "|cod| (ZFfun A B f) = B" by (auto simp add: ZFfun_def ZFfunCod_def Snd Fst)
lemma SETfun: assumes"∀ x . x |∈| A ⟶ (f x) |∈| B" shows"isZFfun (ZFfun A B f)" proof(auto simp add: isZFfun_def ZFfun_def isOpair Fst Snd
ZFfunCod_def ZFfunDom_def isFun_Lambda domain_Lambda Let_def)
{ fix x have"x |∈| Range (Lambda A f) ==> x |∈| B" apply(insert isFun_Lambda[of A f]) apply (drule fun_range_witness[of "Lambda A f" x], simp) by (auto simp add: domain_Lambda Lambda_app assms)
} thus"subset (Range (Lambda A f)) B" by (auto simp add: subset_def)
{ fix x have"x |∈| (Lambda A f) ==> x |∈| A |×| Range (Lambda A f)" by(auto simp add: CartProd Lambda_def Repl Range)
} thus"(Lambda A f) |⊆| (A |×| Range (Lambda A f))" by (auto simp add: HOLZF.subset_def) qed
lemma ZFCartProd: assumes"x |∈| A |×| B" shows"Fst x |∈| A ∧ Snd x |∈| B ∧ isOpair x" proof- from CartProd obtain a b where"a |∈| A" and"b |∈| B" and"x = Opair a b"using assms by auto thus ?thesis using assms by (auto simp add: Fst Snd isOpair_def) qed
lemma ZFfunDomainOpair: assumes"isFun f" and"x |∈| Domain f" shows"Opair x (app f x) |∈| f" proof- have"∃! y . Opair x y |∈| f"using assms by (auto simp add: unique_fun_value) thus"Opair x (app f x) |∈| f"by (auto simp add: app_def intro: theI') qed
lemma ZFFunToLambda: assumes1: "isFun f" and2: "f |⊆| (Domain f) |×| (Range f)" shows"f = Lambda (Domain f) (λx. app f x)" proof(subst Ext, rule allI, rule iffI)
{ fix x assume a: "x |∈| f"show"x |∈| Lambda (Domain f) (λx. app f x)" proof(simp add: Lambda_def Repl, rule exI[of _ "(Fst x)"], rule conjI) have b:"isOpair x ∧ Fst x |∈| Domain f"using2 a by (auto simp add: subset_def ZFCartProd) thus"Fst x |∈| Domain f" .. hence"Opair (Fst x) (app f (Fst x)) |∈| f"using1by (simp add: ZFfunDomainOpair) moreoverhave"Opair (Fst x) (Snd x) |∈| f"using a 2by (auto simp add: FstSnd subset_def b) ultimatelyhave"Snd x = (app f (Fst x))"using1by (auto simp add: isFun_def) hence"Opair (Fst x) (app f (Fst x)) = Opair (Fst x) (Snd x)"by simp alsohave"... = x"using b by (simp add: FstSnd) finallyshow"x = Opair (Fst x) (app f (Fst x))" .. qed
} moreover
{ fix x assume a: "x |∈| Lambda (Domain f) (λx. app f x)"show"x |∈| f" proof- from Lambda_def obtain a where"a |∈| Domain f ∧ x = Opair a (app f a)" using a by (auto simp add: Repl) thus ?thesis using a 1by (auto simp add: ZFfunDomainOpair) qed
} qed
lemma ZFfunApp: assumes"x |∈| A" shows"(ZFfun A B f) |@| x = f x" proof- have"(ZFfun A B f) |@| x = app (Lambda A f) x"by (simp add: ZFfun_def ZFfunApp_def Snd) alsohave"... = f x"using assms by (simp add: Lambda_app) finallyshow ?thesis . qed
lemma ZFfun_ext: assumes"∀ x . x |∈| A ⟶ f x = g x" shows"(ZFfun A B f) = (ZFfun A B g)" proof- have"Lambda A f = Lambda A g"using assms by (auto simp add: Lambda_ext) thus ?thesis by (simp add: ZFfun_def) qed
lemma ZFfunExt: assumes"|dom| f = |dom| g"and"|cod| f = |cod| g"and funf: "isZFfun f"and fung: "isZFfun g" and"∧ x . x |∈| ( |dom| f) ==> f |@| x = g |@| x" shows"f = g" proof- have1: "f = ZFfun ( |dom| f) ( |cod| f) (λx. f |@| x)"using funf by (rule ZFfun) have"g = ZFfun ( |dom| g) ( |cod| g) (λx. g |@| x)"using fung by (rule ZFfun) hence2: "g = ZFfun ( |dom| f) ( |cod| f) (λx. g |@| x)"using assms by simp have"ZFfun ( |dom| f) ( |cod| f) (λx. f |@| x) = ZFfun ( |dom| f) ( |cod| f) (λx. g |@| x)" using assms by (simp add: ZFfun_ext) thus ?thesis using12by simp qed
lemma ZFfunDomAppCod: assumes"isZFfun f" and"x |∈| |dom|f" shows"f |@| x |∈| |cod|f" proof(simp add: ZFfunApp_def) have"app (Snd f) x |∈| Range (Snd f)"using assms by (auto simp add: fun_value_in_range ) thus"app (Snd f) x |∈| |cod|f"using assms by (auto simp add: HOLZF.subset_def) qed
lemma ZFfunComp: assumes"∀ x . x |∈| A ⟶ f x |∈| B" shows"(ZFfun A B f) |o| (ZFfun B C g) = ZFfun A C (g o f)" proof (simp add: ZFfunComp_def ZFfunDom ZFfunCod)
{ fix x assume a: "x |∈| A" have"ZFfun B C g |@| (ZFfun A B f |@| x) = (g o f) x" proof- have"(ZFfun A B f |@| x) = f x"using a by (simp add: ZFfunApp) hence"ZFfun B C g |@| (ZFfun A B f |@| x) = g (f x)"using assms a by (simp add: ZFfunApp) thus ?thesis by simp qed
} thus"ZFfun A C (λx. ZFfun B C g |@| (ZFfun A B f |@| x)) = ZFfun A C (g ∘ f)" by (simp add: ZFfun_ext) qed
lemma ZFfunCompApp: assumes a:"isZFfun f"and b:"isZFfun g"and c:"|dom|g = |cod|f" shows"f |o| g = ZFfun ( |dom| f) ( |cod| g) (λ x . g |@| (f |@| x))" proof- have1: "f = ZFfun ( |dom| f) ( |cod| f) (λ x . f |@| x)"using a by (rule ZFfun) have2: "g = ZFfun ( |dom| g) ( |cod| g) (λ x . g |@| x)"using b by (rule ZFfun) have3: "∀ x . x |∈| |dom|f ⟶ (λx. f |@| x) x |∈| |cod|f"using a by (simp add: ZFfunDomAppCod) hence4: "∀ x . x |∈| |dom|f ⟶ (λx. g |@| (f |@| x)) x |∈| |cod|g" using a b c by (simp add: ZFfunDomAppCod) have"f |o| g = ZFfun ( |dom| f) ( |cod| f) (λ x . f |@| x) |o| ZFfun ( |cod| f) ( |cod| g) (λ x . g |@| x)"using12 c by simp hence"f |o| g = ZFfun ( |dom| f) ( |cod| g) (λ x . g |@| (f |@| x))" using3by (simp add: ZFfunComp comp_def) thus ?thesis using4by (simp add: SETfun) qed
lemma ZFfunCompAppZFfun: assumes"isZFfun f"and"isZFfun g"and"|dom|g = |cod|f" shows"isZFfun (f |o| g)" proof- have"f |o| g = ZFfun ( |dom| f) ( |cod| g) (λ x . g |@| (f |@| x))"using assms by (simp add: ZFfunCompApp) moreoverhave"∀ x . x |∈| |dom|f ⟶ ((λ x . g |@| (f |@| x)) x) |∈| |cod|g"using assms by (simp add: ZFfunDomAppCod) ultimatelyshow ?thesis by (simp add: SETfun) qed
lemma ZFfunCompAssoc: assumes a: "isZFfun f"and b:"isZFfun h"and c:"|cod|g = |dom|h" and d:"isZFfun g"and e:"|cod|f = |dom|g" shows"f |o| g |o| h = f |o| (g |o| h)" proof- have1: "f = ZFfun ( |dom| f) ( |cod| f) (λ x . f |@| x)"using a by (rule ZFfun) have2: "g = ZFfun ( |dom| g) ( |cod| g) (λ x . g |@| x)"using d by (rule ZFfun) have3: "h = ZFfun ( |dom| h) ( |cod| h) (λ x . h |@| x)"using b by (rule ZFfun) have4: "∀ x . x |∈| |dom|f ⟶ (λx. f |@| x) x |∈| |cod|f"using a by (simp add: ZFfunDomAppCod) have"(f |o| g) |o| h = ZFfun ( |dom| f) ( |cod| h) (λ x . h |@| (g |@| (f |@| x)))" proof- have5: "∀ x . x |∈| |dom|f ⟶ (λx. g |@| (f |@| x)) x |∈| |cod|g" using4 e d by (simp add: ZFfunDomAppCod) have"(f |o| g) |o| h = (ZFfun ( |dom| f) ( |cod| f) (λ x . f |@| x) |o| ZFfun ( |cod| f) ( |cod| g) (λ x . g |@| x)) |o| ZFfun ( |cod| g) ( |cod| h) (λ x . h |@| x)" using123 c e by (simp) thus ?thesis using45by (simp add: ZFfunComp comp_def) qed moreoverhave"f |o| (g |o| h) = ZFfun ( |dom| f) ( |cod| h) (λ x . h |@| (g |@| (f |@| x)))" proof- have5: "∀ x . x |∈| |dom|g ⟶ (λx. g |@| x) x |∈| |cod|g"using d by (simp add: ZFfunDomAppCod) have"f |o| (g |o| h) = ZFfun ( |dom| f) ( |dom| g) (λ x . f |@| x) |o| (ZFfun ( |dom| g) ( |cod| g) (λ x . g |@| x) |o| ZFfun ( |cod| g) ( |cod| h) (λ x . h |@| x))" using123 c e by (simp) thus ?thesis using4 e 5by (simp add: ZFfunComp comp_def) qed ultimatelyshow ?thesis by simp qed
proof have java.lang.NullPointerException: Cannot invoke "String.equals(Object)" because "macro" is null :: "ZF ZF ==> ZF) ==>where thus ?thesis by (simp: ZFfunDom ZFfunCod qed
lemma assumes a: "isZFfun f"showsun(mf( dom>. x)) |o| f = f" proof- let ?g = "(ZFfun ( |dom|f) ( |dom|f) (🚫 app (Snd f) x" have "ZFfun ( |dom| f) ( |cod| f) (λ x . f |@| x) = ?g |o| f" using a by (simp add: ZFfun_ext ZFfunApp ZFfunCompApp SETfun ZFfunCod ZFfunDom) moreover have "f = ZFfun(|om)<lambdaf | " usin by uleZfn ultimately show ?thesis by sm qed
lemma ZFfunIdRight: assumes a isZfu f"hows| || \lambda) java.lang.StringIndexOutOfBoundsException: Index 86 out of bounds for length 86 proof- let ?g = "(ZFfun ( |cod|f) ( |cod|f) (λFn_df et_de) have 1: "∀| |dom|f ⟶x. f |@| x |<>d" sng aby smpadd ZFfnomApCod have"un cod 🚫x . f |@| x) = f |o| ?g" using a 1 by (simp add: ZFfun_ext ZFfunApp ZFfunCompApp SETfun ZFfunCod ZFfunDom) moreover have "Cod)" ultimately show ?thesis by simp qed
ET proof-fixx have"tegory_axioms bybyuto_bdams
ZFfunCompAppZFfun x |∈| Range (Lambda A f)" thus ?thesis by (auto simp add: SET_def MakeCat) qed
lemma SETdom: "isZFfun (ZFfunhave<xists! y . Opair x y |∈| f" using assms by (auto simp add: unique_fun_value) bympd:SE_de Maeatde ETdf funom)
lemma SETId: assumes "x |∈ proof- have"X ∈f STef akeeCt_d) hence "isZFfun(Id SET impategorygoryCatIdInMormor moreoverhavedET(<lambdax. x)" using assms by (simp add: SET_def SET'_def MaeCtde) ltimatelysho ?thesisusig ssmsb (ipdd:ZFuAp qed
lemma SETCompE[elim]: "[ bytoSETdef
lemma SETmapsToSET X to isZFfun f ∧ |cod| f = Y" by(auto simp add: MapsTo_def SET_def SET'_def MakeCat_def
lemma SETComp: assumes "f ≈| A" proof have a: "f ≈ have"f ;;g = f ;;g"by (simp add: SET_def) alsohave"... = f ;;g"using a by (simp add
nally simpdSETdef qed
lemma SETCompAt: assumes"f ≈| (Domain (Snd f)) |×sss proof- have "f ;;\^SET g= f| usingmpomp alsohave"... = ZFfun ( |dom| f) ( |cod| g) (λ x . g |@| (f |@| x))"usingautopd ompApp finallyshow ?thesissis d:fun_def qed
lemma SETZFfunfunom(lambda|x using le
sumesSET "shows "ZFfun <>x . f |@| x)" proof- have "isZFfun f" using assms by (autosimp ad: SETor hence "f = ZFfun ( |dom henceg=Ffun \lambda> @ )using yimp moreoverhave"|dom| f = X"nd"usingsin ssmb (uto imp dd ST_efSET_de akCt_ef ultimately show qed
lemma SETfunDomAppCod: assumes "f mapsto Y" and "x |∈ shows"f |@| x |∈ proof have 1pr (simp ad FunCmp_def Zunom Funod hence "x |∈
ence| |cod| f" using 1 by (simp add: ZFfunDomAppCod) thus ?thesis using 2 by simp qed
(*Locally Small Category has an injective map from the morphisms to ZF*) record ('o,'m) LSCategory = "(' :sZFfun:m od" or2F: "==>ZFm2z🍋_› fun <> x . g |@| x)" using b by (rule ZFfun)
definition ZF2mor (‹longrightarrow (λ g|@|( @| )) x|∈ "ZF2morhave"ogfundom)codf\lambda>x.f|@|x)|ojava.lang.StringIndexOutOfBoundsException: Index 73 out of bounds for length 73
lemma(inLSCategory)m2zz2m: assumes"fmapsXtoY"shows"(have4\>moringyauto proof- have"X\<in>ObjC"and"Y\<in>ObjC"usingssmsmp:sToObj hence"HOMCollectionCXY\<in>rangexplodesingsmsimpOMSetIsSetetIsSet moreoverhave"(m2zf)\<in>HOMCollectionCXY"usingssmsoimpdMCollection_defon_def ultimately\in|implode(HOMCollectionCXY)"by(simpadd:Elem_implode) thus?thesisby(simpadd:HomSet_def) qed
lemma(inLSCategory)m2zz2mInv: assumes"f\<in>mor" shows"z2m(m2zf)= proof- have1:"f\by(paddSETfun moreoverhave"\<exists>!m.m\<in>mor\<and>m2zm=z"java.lang.StringIndexOutOfBoundsException: Index 68 out of bounds for length 68 proof(ruleex_ex1I om<sub\<^>X,f]\<in>mor\<^bsub>SET'\<^esub>"usingassmsby(simpadd:HomFtorInMor') by(ruleexI[of_f],insert { assume<>morandm2zm=(m2zf)"and"y\<in>mor\<and>m2zy=(m2zf)" thus"m=y"by(simpadd:mor2ZFInj) } qed ultimatelyshowthesis(paddd2r_def1quality qed
lemma(inLSCategory)z2mm2z: assumes"X\<in>obj"and"Y\<in>obj"f\>(HomXY)" shows"z2mfmapsXtoY\<and>m2z(z2mf)=f" proof have1:"\<exists>m.mmapsXtoY\<and>m2zm=f" proof have"HOMCollectionC\in>angeodesingssmsbyimpdd:OMSetIsSet reoveref|<n|implode(HOMCollectionCXY)"usingassms(3)by(simpadd:mSet_deft_def ultimatelyhave"f\<in>HOMCollectionCXY"by(simpadd:HOLZF.Elem_implode) thus?thesisbyoimpdOMCollection_defection_def qed have2:"\<exists>!m.m\<in>mor\<and>m2zm=f" proof(ruleex_ex1I) show"\<exists>m.m\<in>mor\<and>m2zmfjava.lang.StringIndexOutOfBoundsException: Index 53 out of bounds for length 53 proof from1obtainmwhere"m\<in>mor\<and>java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9 thus?thesisby qed { fixmyassume"m\<in>mor\<and>m2zm=f"and"y\<in>mor\<and>m2zy=f" thus"m=y"by(simpadd:mor2ZFInjr2ZFInj qed thus?thesis proof- fromainherere:s\anda=f"byauto have4:\>mor"using3byauto have"z2mf=a" dF2mor_def_] apply(rulethe1_equality[of"\<lambda>m.m\<in>mor\<and>m2zm=f"a]) apply(autosimpadd:234) done thus?thesisby(simpadd:3) qed qed
lemmaHomFtorMapLemma1: assumesa:"LSCategoryC"andb:"X\<in>obj\<^bsub>C\<^esub>"andc:"f\<in>mor\<^bsub>C\<^esub>"andd:"x|\also"..ZFfun<bsubesubY)(Hom\<^bsub>C\<^esub>XY)(\<lambda>f.f)" shows"(m2z\<^bsub>C\<^esub>(\<^bsub\^>x);C\<^esub>f))|\<in><bsub\esubbcodC\^>)" proof- haveZFfunCod_defZFfunDom_defisFun_Lambdadomain_LambdaLet_def tot_def hence"andb"<<^bsub>C\<^esub>" henceunctornctor(ombsubproof byautosimp:LSCategorym2zz2m) thus?thesisusingclemmaHomFtorObjjava.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 17 qed
lemmaHomFtorInMor': b" shows proofsimpaddHomFtorMap_def { x|nceOpair(x()Opairirstx)(imp ncem2z<bsubC\<^esub>((z2m\<^bsub>C\<^esub>x);;\<^bsubC>finallyshow"irFst".java.lang.StringIndexOutOfBoundsException: Index 57 out of bounds for length 57 } hence"\<forall>x.x|\<"=(OpairimppddositeCategory_defor_Op_MapsTo_def "isZFfun((Hom\<bsub>\Xm<><>f)Hom\<^bsubC^>Xcod\<^bsub>C\<^esub>f(((z2m\<^bsub>C\esubx);;\<^>C\^esub) by(simpadd:SETfunsinggassmsby(mpaddFtorFtorFtor thus"ZFfun(Hom\<^bsub>C\<^esub>X by(simpadd:SET'_def) qed
lemmaHomFtorMor': assumes"LSCategoryC"and"<in>j<bsub<esuband"f\injava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 showshence4\forall>java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 0 proof- haveXusingy(impaddZFfunCompmp_def moreoverhave"dom\<^bsub>SET'\<^esub>(Hom\<^bsubshows"sZFfunf|) by(simpadd:HomFtorMap_defSET'_defZFfunDom) moreoverhave"cod\<^bsub>SET'\<^esub>(Hom (mpaddFtorMap_defp_deffSETunCod ultimatelymatelyshowhesisbyautompaddSET_def qed
lemmaHomFtorDist': assumesa:"LSCategoryC"andb:"X\<in>obj\<^bsub>C\<^esub>"andc:"f\<approx>>\<^bsub>C\<^esub>g" shows"(Hom\<^bsub>C\<^esub>[X,f]);;\<^bsub>SET'\<^esub>(Hom\<^bsub>C\<^esub>[X,g])=Hom\<^bsub>C\<^esub>[X,f;;\<^bsub>C\<^esub>g]" proof- let?A="(Hom\<^bsub>C\<^esub>Xdom\<^bsub>C\<^esub>f)" let?B="(Hom\<^bsub>C\<^esub>Xdom\<^bsub>C\<^esub>g)" let?C="(Hom\<^bsub>C\<^esub>Xcod\<^bsub>C\<^esub>g)" let?f="(\<lambda>h.m2z\<^bsub>C\<^esub>((z2m\<^bsub>C\<^esub>h);;\<^bsub>C\<^esub>f))" let?g="(\<lambda>f.m2z\<^bsub>C\<^esub>((z2m\<^bsub>C\<^esub>f);;\<^bsub>C\<^esub>g))" have1:"cod\<^bsub>C\<^esub>f=dom\<^bsub>C\<^esub>g"usingcbyauto have2:"dom\<^bsub>C\<^esub>(f;;\<^bsub>C\<^esub>g)=dom\<^bsub>C\<^esub>f"and3:"cod\<^bsub>C\<^esub>(f;;\<^bsub>C\<^esub>g)=cod\<^bsub>C\<^esub>g"usingassms by(autosimpadd:Category.MapsToMorDomCod) have"(Hom\<^bsub>C\<^esub>[X,f]);;\<^bsub>SET'\<^esub>(Hom\<^bsub>C\<^esub>[X,g])=(ZFfun?A(Hom\<^bsub>C\<^esub>Xcod\<^bsub>C\<^esub>f)?f)|o|(ZFfun?B?C?g)" by(simpadd:HomFtorMap_defSET'_def) alsohave"...=(ZFfun?A?B?f)|o|(ZFfun?B?C?g)"using1bysimp alsohave..=ZFfunA?(?g?" proof(ruleZFfunComp,ruleallI,ruleimpI) { fixhassumeaa:"h|\<in>|?A"show"?fh|\<in>|?proof- proof- have"f\<in>mor\<^bsub>C\<^esub>"usingassmsbyauto hence"?fh|\<in>|(Hom\<^bsub>C\<^esub>Xcod\<^bsub>C\<^esub>f)"usingassmsaaby(simpadd:HomFtorMapLemma1) thus?thesisusing1bysimp qed } qed alsohave"...=ZFfun?A?C(\<lambda>h.m2z\<^bsub>C\<^esub>((z2m\<^bsub>C\<^esub>h);;\<^bsub>C\<^esub>(f;;\<^bsub>C\<^esub>g)))" proof(ruleZFfun_ext,ruleallI,ruleimpI,simpadd:comp_def) { fixhassumeaa:"h|\<in>|?A" show"m2z\<^bsub>C\<^esub>((z2m\<^bsub>C\<^esub>(m2z\<^bsub>C\<^esub>((z2m\<^bsub>C\<^esub>h);;\<^bsub>C\<^esub>f)));;\<^bsub>C\<^esub>g)=m2z\<^bsub>C\<^esub>((z2m\<^bsub>C\<^esub>h);;\<^bsub>C\<^esub>(f;;\<^bsub>C\<^esub>g))" proof- havebb:"(z2m\<^bsub>C\<^esub>h)\<approx>>\<^bsub>C\<^esub>f" proof(ruleCompDefinedI) show"f\<in>mor\<^bsub>C\<^esub>"usingcbyauto hence"dom\<^bsub>C\<^esub>f\<in>obj\<^bsub>C\<^esub>"usingaby(simpadd:Category.Cdom) hence"(z2m\<^bsub>C\<^esub>h)maps\<^bsub>C\<^esub>Xtodom\<^bsub>C\<^esub>f"usingassmsaaby(simpadd:LSCategory.z2mm2z) thus"(z2m\<^bsub>C\<^esub>h)\<in>mor\<^bsub>C\<^esub>"and"cod\<^bsub>C\<^esub>(z2m\<^bsub>C\<^esub>h)=dom\<^bsub>C\<^esub>f"byauto qed hence"(z2m\<^bsub>C\<^esub>h);;\<^bsub>C\<^esub>f\<in>mor\<^bsub>C\<^esub>"usingaby(simpadd:Category.MapsToMorDomCod) hence"z2m\<^bsub>C\<^esub>(m2z\<^bsub>C\<^esub>((z2m\<^bsub>C\<^esub>h);;\<^bsub>C\<^esub>f))=(z2m\<^bsub>C\<^esub>h);;\<^bsub>C\<^esub>f"usingaby(simpadd:LSCategory.m2zz2mInv) hence"m2z\<^bsub>C\<^esub>((z2m\<^bsub>C\<^esub>(m2z\<^bsub>C\<^esub>((z2m\<^bsub>C\<^esub>h);;\<^bsub>C\<^esub>f)));;\<^bsub>C\<^esub>g)=m2z\<^bsub>C\<^esub>(((z2m\<^bsub>C\<^esub>h);;\<^bsub>C\<^esub>f);;\<^bsub>C\<^esub>g)"bysimp alsohave"...=m2z\<^bsub>C\<^esub>((z2m\<^bsub>C\<^esub>h);;\<^bsub>C\<^esub>(f;;\<^bsub>C\<^esub>g))"usingbbcaby(simpadd:Category.Cassoc) finallyshow?thesis. qed } qed alsohave"...=ZFfun(Hom\<^bsub>C\<^esub>Xdom\<^bsub>C\<^esub>(f;;\<^bsub>C\<^esub>g))(Hom\<^bsub>C\<^esub>Xcod\<^bsub>C\<^esub>(f;;\<^bsub>C\<^esub>g))(\<lambda>h.m2z\<^bsub>C\<^esub>((z2m\<^bsub>C\<^esub>h);;\<^bsub>C\<^esub>(f;;\<^bsub>C\<^esub>g)))" using23bysimp alsohave"...=Hom\<^bsub>C\<^esub>[X,f;;\<^bsub>C\<^esub>g]"by(simpadd:HomFtorMap_def) finallyshow?thesisby(autosimpadd:SET_def) qed
lemmaHomFtorDist: assumes"LSCategoryC"and"X\<in>obj\<^bsub>C\<^esub>"and"f\<approx>>\<^bsub>C\<^esub>g" shows"(Hom\<^bsub>C\<^esub>[X,f]);;\<^bsub>SET\<^esub>(Hom\<^bsub>C\<^esub>[X,g])=Hom\<^bsub>C\<^esub>[X,f;;\<^bsub>C\<^esub>g]" proof-thus"ZFfun(Hom<^sub>C<^esubXdom<^bsub>C\^sub>f)(Hom\<bsubC\<esubcod\bsubC\^>f)(\<>m2z\^><^sub(z2m<bsubC\^esubx;<^>C<^>f)\in>\<bsubSET'<^" have"(Hom\<^bsub>C\<^esub>[X,f]);;\<^bsub>SET'\<^esub>(Hom\<^bsub>C\<^esub>[X,g])=Hom\<^bsub>C\<^esub>[X,f;;\<^bsub>C\<^esub>lemmaHomFtorMor': moreoverhave"(Hom\<^bsub>C\<^esub>[X,f])\<approx>>\<^bsub>SET'\<^esub>(Hom\<^bsub>C\<^esub>[X,g])"usingassmsby(simpadd:HomFtorCompDef') ultimatelyshow?thesisby(simpadd:MakeCatCompSET_def) qed
lemmaHomFtorId': assumesa:"LSCategoryC"andb:"X\<in>obj\<^bsub>C\<^esub>"andc:"Y\<in>obj\<^bsub>C\<^esub>" shows"Hom\<^bsub>C\<^esub>[X,id\<^bsub>C\<^esub>Y]=id\<^bsub>SET'\<^esub>(Hom\<^bsub>C\<^esub>XY)" proof- have"(id\<^bsub>C\<^esub>Y)maps\<^bsub>C\<^esub>YtoY"usingacby(simpadd:Category.Simps) hence1:"(dom\<^bsub>C\<^esub>(id\<^bsub>C\<^esub>Y))=Y"and2:"(cod\<^bsub>C\<^esub>(id\<^bsub>C\<^esub>Y))=Y"byauto have"Hom\<^bsub>C\<^esub>[X,id\<^bsub>C\<^esub>Y]=ZFfun(Hom\<^bsub>C\<^esub>X(dom\<^bsub>C\<^esub>(id\<^bsub>C\<^esub>Y)))(Hom\<^bsub>C\<^esub>X(cod\<^bsub>C\<^esub>(id\<^bsub>C\<^esub>Y)))(\<lambda>f.m2z\<^bsub>C\<^esub>((z2m\<^bsub>C\<^esub>f);;\<^bsub>C\<^esub>(id\<^bsub>C\<^esub>Y)))" by(simpadd:HomFtorMap_def) alsohave"...=ZFfun(Hom\<^bsub>C\<^esub>XY)(Hom\<^bsub>C\<^esub>XY)(\<lambda>f.m2z\<^bsub>C\<^esub>((z2m\<^bsub>C\<^esub>f);;\<^bsub>C\<^esub>(id\<^bsub>C\<^esub>Y)))"using12bysimp alsohave"...=ZFfun(Hom\<^bsub>C\<^esub>XY)(Hom\<^bsub>C\<^esub>XY)(\<lambda>f.f)" proof(ruleZFfun_ext,ruleallI,ruleimpI) { fixhassumeaa:"h|\<in>|(Hom\<^bsub>C\<^esub>XY)"show"m2z\<^bsub>C\<^esub>((z2m\<^bsub>C\<^esub>h);;\<^bsub>C\<^esub>(id\<^bsub>C\<^esub>Y))=h" proof- have"(z2m\<^bsub>C\<^esub>h)maps\<^bsub>C\<^esub>XtoY"andbb:"m2z\<^bsub>C\<^esub>(z2m\<^bsub>C\<^esub>h)=h" usingassmsaaby(simpadd:LSCategory.z2mm2z)+ hence"(z2m\<^bsub>C\<^esub>h);;\<^bsub>C\<^esub>(id\<^bsub>C\<^esub>Y)=(z2m\<^bsub>C\<^esub>h)"usingaby(autosimpadd:Category.Simps) hence"m2z\<^bsub>C\<^esub>((z2m\<^bsub>C\<^esub>h);;\<^bsub>C\<^esub>(id\<^bsub>C\<^esub>Y))=m2z\<^bsub>C\<^esub>(z2m\<^bsub>C\<^esub>h)"bysimp alsohave"...=h"usingbb. finallyshow?thesis. qed } qed finallyshow?thesisby(simpadd:SET'_def) qed
lemmaHomFtorId: assumes"LSCategoryC"and"X\<in>obj\<^bsub>C\<^esub>"and"Y\<in>obj\<^bsub>C\<^esub>" shows"Hom\<^bsub>C\<^esub>[X,id\<^bsub>C\<^esub>Y]=id\<^bsub>SET\<^esub>(Hom\<^bsub>C\"Hom\^>C\^>Xf\>mor\^>'<esub"Hom^bsubC<esub[,]\in>mor<bsubSET\^>"usingassmsbysimpaddHomFtorInMor)+ proof- have"Hom\<^bsub>C\<^esub>[X,id\<^bsub>C\<^esub>Y]=id\<^bsub>SET'\<^esub>(Hom\<^bsub>C\<^esub>XY)"usingassmsby(simpadd:HomFtorId') moreoverhave"(Hom\<^bsub>C\<^esub>XY)\<in>obj\<^bsub>SET'\<^esub>"by(simpadd:SET'_def) ultimatelyshow?thesisby(simpadd:MakeCatIdSET_def) qed
lemmaHomFtorObj':
java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 27 andb:"PreFunctor(HomP\<^bsub>C\<^esub>[X,\<midarrow>])"andc:"X\<in>obj\<^bsub>C\<^esub>"andd:"Y\<in>obj\<^bsub>C\<^esub>" shows"(HomP\<^bsub>C\<^esub>[X,\<midarrow>])@@Y=Hom\<^bsub>C\<^esub>XY" proof- ultimatelyshowcod^bsub>SET\^>Hom<bsub><esub>Xf)=\^>'\^esub>(om<bsub>C\^[,]"by have"?F##(id\<^bsub>CatDom?F\<^esub>Y)=Hom\<^bsub>C\<^esub>[X,id\<^bsub>C\<^esub>Y]"by(simpadd:HomFtor'_def) alsohave"...=id\<^bsub>CatCod?F\<^esub>(Hom\<^bsub>C\<^esub>XY)"usingassmsby(simpadd:HomFtorIdHomFtor'_def) finallyhave"?F##(id\<^bsub>CatDom?F\<^esub>Y)=id\<^bsub>CatCod?F\<^esub>(Hom\<^bsub>C\<^esub>XY)"bysimp moreoverhave"Hom\<^bsub>C\<^esub>XY\<in>obj\<^bsub>CatCod?F\<^esub>"usingassms by(simpadd:HomFtorIdHomFtor'_defSET_defSET'_defMakeCatObj) moreoverhave"Y\<in>obj\<^bsub>CatDom?F\<^esub>"usingdby(simpadd:HomFtor'_def) ultimately?usingbysimpaddPreFunctor.FmToFoofFY"Hom<bsub><^esubXY"]) qed
lemmaHomFtorFtor': assumesa:"LSCategoryC" andb:"X\<in>obj\<^bsub>C\<^esub>" shows"FunctorM(HomP\<^bsub>C\<^esub>[X,\<midarrow>])"
java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 20 showPF:"PreFunctor(HomP\<^bsub>C\<^esub>[X,\<midarrow>])" proof(autosimpadd:HomFtor'_defPreFunctor_defSETCategoryaHomFtorDistb) { fixZassumeaa:"Z\<in>obj\<^bsub>C\<^esub>" show"\<exists>Y\<in>obj\<^bsub>SET\<^esub>.Hom\<^bsub>C\<^esub>[X,id\<^bsub>C\<^esub>Z]=id\<^bsub>SET\<^esub>Y" proof(rule_tacx="Hom\<^bsub>C\<^esub>XZ"inSet.rev_bexI) show"Hom\<^bsub>C\<^esub>XZ\<in>obj\<^bsub>SET\<^esub>"by(simpadd:SET_defSET'_defMakeCatObj) show"Hom\<^bsub>C\<^esub>[X,id\<^bsub>C\<^esub>Z]=id\<^bsub>SET\<^esub>(Hom\<^bsub>C\<^esub>XZ)"usingassmsaaby(simpadd:HomFtorId) qed } qed by(simpadd:HomFtorMap_defSET_def) fixfZYassumeaa:"fmaps\<^bsub>C\<^esub>ZtoY" have"(HomP\<^bsub>C\<^esub>[X,\<midarrow>])##fmaps\<^bsub>SET\<^esub>((HomP\<^bsub>C\<^esub>[X,\<midarrow>])@@Z)to((HomP\<^bsub>C\<^esub>[X,\<midarrow>])@@Y)" proof- havebb:"Z\<in>obj\<^bsub>C\<^esub>"andcc:"Y\<in>obj\<^bsub>C\<^esub>"usingaaaby(simpadd:Category.MapsToObj)+ havedd:"dom\<^bsub>C\<^esub>f=Z"andee:"cod\<^bsub>C\<^esub>f=Y"andff:"f\<in>mor\<^bsub>C\<^esub>"usingaabyauto have"(HomP\<^bsub>C\<^esub>[X,\<midarrow>])##f=Hom\<^bsub>C\<^esub>[X,f]"by(simpadd:HomFtor'_def) moreoverhave"(HomP\<^bsub>C\<^esub>[X,\<midarrow>])@@Z=Hom\<^bsub>C\<^esub>XZ" (\<bsubC<^subX,<midarrow>)@Y=\<bsubC<^esubXYassmsbbPFby(add:HomFtorObj')java.lang.StringIndexOutOfBoundsException: Index 133 out of bounds for length 133 moreoverhave"Hom\<^bsub>C\<^esub>[X,f]maps\<^bsub>SET\<^esub>(Hom\<^bsub>C\<^esub>X(dom\<^bsub>C\<^esub>f))to(Hom\<^bsub>C\<^esub>X(cod\<^bsub>C\<^esub>f))" usingassmsffby(simpadd:HomFtorMapsTo) ultimatelyshow?thesisusingddeebysimp qed } thus"FunctorM_axioms(HomP\<^bsub>C\<^esub>[X,\<midarrow>])"usingPFby(autosimpadd:FunctorM_axioms_defHomFtor'_def) qed
lemmaHomFtorFtor: assumesa:"LSCategoryC" andb:"X\<in>obj\<^bsub>C\<^esub>" shows"Functor(Hom\<^bsub>C\<^esub proof- have"FunctorM(HomP\<^bsub>C\<^esub>[X,\<midarrow>])"usingassmsby(ruleHomFtorFtor') thus?thesisby(simpadd:HomFtor_defMakeFtor) qed
(*This is used in the proof of the naturality of the Yoneda trans*) lemma HomCHom: assumes"LSCategory C"and"f ∈ Mor C"and"g ∈ Mor C" shows"(HomC[g,dom f]) ;; (Hom[dom g,f]) = (Hom[cod proof- have ObjDf: "dom f ∈ obj" and ObjDg: "dom g ∈ obj" using assms by (simp add: Category.Cdom)+ have ObjCg: "codjava.lang.NullPointerException have"(HomC[g,dom f]) ;; (Hom[dom g,f]) = (HomC proof- have "(HomC[g,dom f]) ≈> (Hom[dom g,f])" proof(rule CompDefinedI) show "Hom[dom g,f] ∈ Mor SET" using assms ObjDg by (simp add: HomFtorMor) show "HomC[g,dom f] ∈ Mor SET" using assms ObjDf by (simp add: HomFtorContraMor) show "cod (HomC[g,dom f]) = dom (Hom[dom g,f])" using assms ObjDg ObjDf by (simp add: HomFtorMor HomFtorContraMor) qed thus ?thesis by(simp add: SET_def SET'_def MakeCatComp2) qed also have "... = ZFfun (Hom (codjava.lang.NullPointerException
((λ h . m2z ((z2m h) ;; f)) o (λ h . m2z (g ;;java.lang.NullPointerException proof(simp add: HomFtorMapContra_def HomFtorMap_def, rule ZFfunComp, rule allI, rule impI)
{ fix x assume aa: "x |∈| (Hom (cod g) (dom f))" show"(m2z(g ;; (z2mx))) |∈| (Hom (dom g) (dom f))" prooflemma ZF2mor_Op (p C)f=ZF2mor have java.lang.NullPointerException moreover have "(z2mx) maps (cod g) to (dom mapsTo_Op " map\^Op C\<esub by (simp add: LSCategory.z2mm2z) show" ;^bsubesub> z2mbsub g) to\^>C<^esub) using(1 by (simp add: Category.Ccompt) qed
} qed alsohave java.lang.NullPointerException ((λ h . m2z (g ;; (z2m h))) o (λ h . m2z ((z2m h) ;; f)))" proof(rule ZFfun_ext, rule allI, rule impI)
{ fix h assume aa: "h |∈| (Hom (cod g) (dom f))" show java.lang.NullPointerException ((λ h . m2z (g ;; (z2m h))) o (λ h . m2z ((z2m h) ;; f))) h" proof- have MapsTo1: "(z2m h) maps (cod g) to (dom f)"using assms(1) ObjCg ObjDf aa by (simp add: LSCategory.z2mm2z) have CompDef1: "(z2m h) ≈> f" proof(rule CompDefinedI) " <>mor\^C\^esu>"byjava.lang.StringIndexOutOfBoundsException: Index 65 out of bounds for length 65 show"(z2m h) ∈ mor"and"cod (z2m h) = dom f"using MapsTo1 by auto qed have CompDef2: "g ≈> (z2m h)" proof(rule CompDefinedI) show"g ∈ mor"using assms by simp thus"(z2m h) ∈ mor"and"cod g = dom (z2m h)"using MapsTo1 by auto qed have c1: "(z2m h) ;; f ∈ (Op C)C)" have c2: "g ;; (z2m si only LSCa have "g ;; (z2m (m2z ((z2m h) ;; f))) = g ;; ((z2m h) ;; f)" using assms(1) c1 by (simp add: LSCategory.m2zz2mInv) also have "... = (g ;; (z2m h)) ;; f" using CompDef1 CompDef2 assms by (simp add: Category.Cassoc) also have "... = (z2m (m2z (g ;; (z2m h)))) ;; by (simp add: LSCategory.m2zz2mInv) finallyhave"g ;; (z2m (m2z ?hesis byby simp qed hows " (<bsub>\midarrow) :(pC)\longrightarrow SET
} qed alsohave"... = (Hom[cod[\midarrowX)" proof(simp add: HomFtorMapContra_def HomFtorMap_def, rule ZFfunComp[THEN sym], rule allI, rule impI)
{ fix x assume aa: "x |∈| (Hom cod g dom f)" show"m2z((z2mx) ;; f) |∈| (Hom cod g cod f)" proof(rule LSCategory.m2zz2m, simp_all add: assms(1) ObjCg ObjCf) have"f maps^bsub>Op C\^esub>"using ( addOppositeCategory_def moreoverhave"(z2mx) maps (cod g) to (domu show ?the usi assms by (s addd HomFtorFtor) by (simp add: LSCategory.z2mm2z) ultimately show "(z2mx) ;; f maps cod g to cod f" using assms(1) by (simp add: Category.Ccompt) qed } qed also have "... = (Hom[cod g,f]) ;; proof- have"(Hom[codsub>" java.lang.NullPointerException proof(rule CompDefinedI) show "Hom[cod g,f] ∈^>\^\midarrow] @ Y= Hom>C show"HomC[g,cod f] ∈ Mor SET"using assms ObjCf by (simp add: HomFtorContraMor) show"codhave 1: "\inObj"and : " <>Obj C) using(simp OppositeCategory_def by (simp add: HomFtorMor HomFtorContraMor) qed thus ?thesis by(simp add: SET_def SET'_def MakeCatComp2) qed finallyshow ?thesis . qed
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.