Skip to content

Commit

Permalink
makes this satellite compile again after merging UniMath PR1739
Browse files Browse the repository at this point in the history
only small adaptations
  • Loading branch information
rmatthes committed Jul 21, 2023
1 parent e346a32 commit 93d0e06
Show file tree
Hide file tree
Showing 6 changed files with 34 additions and 33 deletions.
8 changes: 4 additions & 4 deletions Modules/Prelims/quotientmonad.v
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ is so slow when R' is definitely equal to quot_functor !
----
*)

Definition R': functor SET SET := quot_functor (pr1 (pr1 R)) _ congr_equivc.
Definition R': functor SET SET := quot_functor (pr1 R) _ congr_equivc.

Definition projR : (R:functor _ _) ⟹ R' := pr_quot_functor _ _ congr_equivc.

Expand Down Expand Up @@ -169,7 +169,7 @@ Proof.
apply univ_surj_nt_ax_pw.
Qed.

Definition R'_Monad_data : Monad_data SET := ((R' ,, R'_μ) ,, R'_η).
Definition R'_Monad_data : disp_Monad_data R' := (R'_μ ,, R'_η).



Expand Down Expand Up @@ -339,7 +339,7 @@ Legend of the diagram :
apply assoc_ppprojR.
Qed.

Lemma R'_Monad_laws : Monad_laws R'_Monad_data.
Lemma R'_Monad_laws : disp_Monad_laws R'_Monad_data.
Proof.
repeat split.
- apply R'_Monad_law_η1.
Expand All @@ -349,7 +349,7 @@ Qed.

(* Le QED précédent prend énormément de temps.. pourquoi ? *)

Definition R'_monad : Monad _ := _ ,, R'_Monad_laws.
Definition R'_monad : Monad _ := _ ,, _ ,, R'_Monad_laws.

(*
FIN DE LA PREMIERE ETAPE
Expand Down
4 changes: 3 additions & 1 deletion Modules/Prelims/quotientmonadslice.v
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,8 @@ Section QuotientMonad.

Context {R : Monad SET}.

Local Definition R0 : functor SET SET := R.

(**
R preserves epimorphisms.
This is needed to prove the the horizontal composition of the
Expand Down Expand Up @@ -141,7 +143,7 @@ Let projR := projR congr_equivc.
of actions
*)
Lemma compat_slice (j : J) ( m := ff j)
: ∏ (X : SET) (x y : (pr1 R X : hSet)),
: ∏ (X : SET) (x y : (R0 X : hSet)),
projR X x = projR X y → m X x = m X y.
Proof.
intros X x y eqpr.
Expand Down
14 changes: 7 additions & 7 deletions Modules/Signatures/EpiSigRepresentability.v
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ Example EpiSignatureThetaTheta
Proof.
intro hepi.
apply is_nat_trans_epi_from_pointwise_epis.
assert (hf : ∏ x, isEpi (pr1 f x)).
assert (hf : ∏ x, isEpi (pr1 (pr1 f) x)).
{
apply epi_nt_SET_pw.
exact hepi.
Expand Down Expand Up @@ -196,7 +196,7 @@ Definition u {S : REP b} (m : R -->[ F] S)
:= u_monad R_epi dd ff (S ,, m) .

(** The induced natural transformation makes a triangle commute *)
Lemma u_def {S : REP b} (m : R -->[ F] S) : ∏ x, ## m x = projR x · u m x.
Lemma u_def {S : REP b} (m : R -->[ F] S) : ∏ x, pr1 (## m) x = projR x · u m x.
Proof.
apply (u_def dd ff (S ,, m)).
Qed.
Expand All @@ -223,7 +223,7 @@ Lemma Rep_mor_is_composition
{S : REP b} (m : R -->[ F] S)
: pr1 m = compose (C:=category_Monad _) projR (u m) .
Proof.
use (invmap (Monad_Mor_equiv _ _ _)).
use (invmap (Monad_Mor_equiv _ _)).
apply nat_trans_eq.
- apply (homset_property SET).
- intro X'.
Expand All @@ -248,7 +248,7 @@ Qed.

Lemma eq_mr
{S : REP b} (m : R -->[ F] S) (X : SET)
: model_τ R X · ## m X
: model_τ R X · pr1 (## m) X
=
pr1 (# a projR)%ar X · (F (R' ))%ar X
·
Expand Down Expand Up @@ -511,7 +511,7 @@ Proof.
apply cancel_postcomposition.
etrans.
apply (cancel_ar_on _ (compose (C:=category_Monad _) projR (u m))).
use (invmap (Monad_Mor_equiv _ _ _)).
use (invmap (Monad_Mor_equiv _ _)).
(* { apply homset_property. } *)
{ apply nat_trans_eq.
apply homset_property.
Expand Down Expand Up @@ -571,9 +571,9 @@ Lemma helper
(S : model b)
: ∏ (u' : Rep_b ⟦ rep_of_b_in_R' R R_epi epiab cond_F, S ⟧) x,
projR R R_epi x · (u' : model_mor_mor _ _ _ _ _) x =
pr1 (pr1 (compose (C:=Rep_a) (b:=FF (rep_of_b_in_R' R R_epi epiab cond_F))
pr1 (compose (C:=Rep_a) (b:=FF (rep_of_b_in_R' R R_epi epiab cond_F))
(projR_rep R R_epi epiab cond_F : model_mor_mor _ _ _ _ _)
(# FF u'))) x.
(# FF u')) x.
Proof.
intros u' x.
apply pathsinv0.
Expand Down
14 changes: 7 additions & 7 deletions Modules/Signatures/ModelCat.v
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ Lemma isaset_rep_fiber_mor {a : SIG} (M N : model a) :
Proof.
intros.
apply isaset_total2 .
- apply has_homsets_Monad.
- apply isaset_Monad_Mor.
- intros.
apply isasetaprop.
apply isaprop_rep_fiber_mor_law.
Expand All @@ -99,14 +99,14 @@ Proof.
use (invmap (subtypeInjectivity _ _ _ _ )).
- intro g.
apply isaprop_rep_fiber_mor_law.
- use (invmap (Monad_Mor_equiv _ _ _ )).
- use (invmap (Monad_Mor_equiv _ _)).
+ assumption.
Qed.

(** If two 1-model morphisms are pointwise equal, then they are equal *)
Lemma rep_fiber_mor_eq {a : SIG} (R S:model a)
(u v: rep_fiber_mor R S) :
(∏ c, pr1 (pr1 u) c = pr1 (pr1 v) c) -> u = v.
(∏ c, pr1 u c = pr1 v c) -> u = v.
Proof.
intros.
apply rep_fiber_mor_eq_nt.
Expand Down Expand Up @@ -407,8 +407,8 @@ M (M + Id) ---------> M R --------> M
Defined.

(** Data for the (M + Id) monad *)
Definition mod_id_monad_data : Monad_data C :=
((IdM ,, mod_id_μ) ,, mod_id_η).
Definition mod_id_monad_data : disp_Monad_data IdM :=
(mod_id_μ ,, mod_id_η).

Local Infix "++f" := (BinCoproductOfArrows _ _ _) (at level 6).
Local Notation "[[ f , g ]]" := (BinCoproductArrow _ f g).
Expand Down Expand Up @@ -506,7 +506,7 @@ M (M + Id) ---------> M R --------> M


(** Monad laws for (M + Id) *)
Lemma mod_id_monad_laws : Monad_laws mod_id_monad_data.
Lemma mod_id_monad_laws : disp_Monad_laws mod_id_monad_data.
Proof.
repeat split.
- intro c.
Expand Down Expand Up @@ -584,7 +584,7 @@ M (M + Id) ---------> M R --------> M


(** The M + Id monad *)
Definition mod_id_monad : Monad C := _ ,, mod_id_monad_laws.
Definition mod_id_monad : Monad C := _ ,, _ ,, mod_id_monad_laws.

(** The morphism M + Id --> R is a monad morphism *)
Lemma mod_id_monad_mor_laws : Monad_Mor_laws (T := mod_id_monad) mod_id_nt.
Expand Down
25 changes: 12 additions & 13 deletions Modules/Signatures/Signature.v
Original file line number Diff line number Diff line change
Expand Up @@ -385,7 +385,7 @@ Lemma isaset_model_mor_mor (a b : SIGNATURE) (M : model a) (N : model b) f :
Proof.
intros.
apply isaset_total2 .
- apply has_homsets_Monad.
- apply isaset_Monad_Mor.
- intros.
apply isasetaprop.
apply isaprop_model_mor_law.
Expand All @@ -404,7 +404,7 @@ Definition rep_disp_ob_mor : disp_cat_ob_mor PRECAT_SIGNATURE :=
(model,, model_mor_mor).

Lemma rep_id_law (a : SIGNATURE) (RM : rep_disp_ob_mor a) :
model_mor_law RM RM (identity (C:=PRECAT_SIGNATURE) _) (Monad_identity _).
model_mor_law RM RM (identity (C:=PRECAT_SIGNATURE) _) (identity _).
Proof.
intro c.
apply pathsinv0.
Expand All @@ -421,7 +421,7 @@ Definition rep_id (a : SIGNATURE) (RM : rep_disp_ob_mor a) :
RM -->[ identity (C:=PRECAT_SIGNATURE) a] RM.
Proof.
intros.
exists (Monad_identity _).
exists (identity _).
apply rep_id_law.
Defined.

Expand All @@ -432,8 +432,7 @@ Lemma transport_signature_mor (x y : SIGNATURE) (f g : signature_Mor x y)
(xx : rep_disp_ob_mor x)
(yy : rep_disp_ob_mor y)
(ff : xx -->[ f] yy)
(c : C) :
pr1 (pr1 (transportf (mor_disp xx yy) e ff)) c = pr1 (pr1 ff) c.
(c : C) : pr1 (transportf (mor_disp xx yy) e ff) c = pr1 ff c.
Proof.
induction e.
apply idpath.
Expand All @@ -446,13 +445,13 @@ Qed.
Lemma model_mor_mor_equiv (a b : SIGNATURE) (R:rep_disp_ob_mor a)
(S:rep_disp_ob_mor b) (f:signature_Mor a b)
(u v: R -->[ f] S) :
(∏ c, pr1 (pr1 u) c = pr1 (pr1 v) c) -> u = v.
(∏ c, pr1 u c = pr1 v c) -> u = v.
Proof.
intros.
use (invmap (subtypeInjectivity _ _ _ _ )).
- intro g.
apply isaprop_model_mor_law.
- use (invmap (Monad_Mor_equiv _ _ _ )).
- use (invmap (Monad_Mor_equiv _ _)).
+ apply nat_trans_eq.
apply homset_property.
assumption.
Expand Down Expand Up @@ -544,12 +543,12 @@ Proof.
- set (heqf:= assoc f g h).
apply model_mor_mor_equiv.
intros c.
etrans. Focus 2.
symmetry.
apply transport_signature_mor.
cbn.
rewrite assoc.
apply idpath.
etrans.
2: { symmetry.
apply transport_signature_mor. }
cbn.
rewrite assoc.
apply idpath.
- apply isaset_model_mor_mor.
Qed.

Expand Down
2 changes: 1 addition & 1 deletion Modules/SoftEquations/CatOfTwoSignatures.v
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,7 @@ Lemma transport_signature_mor (x y : TwoSignature) (f g : x →→ y)
(yy : two_model_disp_ob_mor y)
(ff : xx -->[ f] yy)
(c : C) :
pr1 (pr1 (transportf (mor_disp xx yy) e ff)) c = pr1 (pr1 ff) c.
pr1 (transportf (mor_disp xx yy) e ff) c = pr1 ff c.
Proof.
induction e.
apply idpath.
Expand Down

0 comments on commit 93d0e06

Please sign in to comment.