fact
stringlengths
0
6.66k
type
stringclasses
10 values
imports
stringclasses
399 values
filename
stringclasses
465 values
symbolic_name
stringlengths
1
75
index_level
int64
0
7.85k
{ n : nat & P n }. Proof. destruct prop_n_to_min_n as [n pl]. destruct pl as [p _]. exact (n; fst merely_inhabited_iff_inhabited_stable p). Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import HoTT.Truncations.Core. Require Import HoTT.Spaces.Nat.Core.
BoundedSearch.v
minimal_n
0
{x : X & P x}. Proof. set (P' n := P (e n)). assert (P'_dec : forall n, Decidable (P' n)) by apply _. assert (P'_inhab : hexists (fun n => P' n)). { strip_truncations. apply tr. destruct P_inhab as [x p]. exists (e ^-1 x). unfold P'. rewrite (eisretr e). exact p. } destruct (minimal_n P' P'_dec P'_inhab) as [n p']. exists (e n). exact p'. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import HoTT.Truncations.Core. Require Import HoTT.Spaces.Nat.Core.
BoundedSearch.v
minimal_n_alt_type
1
{X : Type} (f : X -> X) := {x : X & f x = x}. Global Instance ishprop_fix_wconst {X : Type} (f : X -> X) {wc : WeaklyConstant f} : IsHProp ( f). Proof. apply hprop_inhabited_contr; intros [x0 p0]. refine (contr_equiv' {x:X & f x0 = x} _); unfold . apply equiv_functor_sigma_id. intros x. apply equiv_concat_l. apply wconst. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Extensions Factorization. Require Import Truncations.Core Modalities.Modality.
Constant.v
FixedBy
2
{X : Type} (f : X -> X) {wc : WeaklyConstant f} : FixedBy f <~> merely X. Proof. apply equiv_iff_hprop. - intros [x p]; exact (tr x). - apply Trunc_rec; intros x. exists (f x). apply wconst. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Extensions Factorization. Require Import Truncations.Core Modalities.Modality.
Constant.v
equiv_fix_merely
3
{X} `{Collapsible X} : merely X -> X. Proof. refine (_ o (equiv_fix_merely collapse)^-1). apply pr1. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Extensions Factorization. Require Import Truncations.Core Modalities.Modality.
Constant.v
splitsupp_collapsible
4
{X} (s : merely X -> X) : Collapsible X. Proof. refine (Build_Collapsible _ (s o tr) _); intros x y. apply (ap s), path_ishprop. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Extensions Factorization. Require Import Truncations.Core Modalities.Modality.
Constant.v
collapsible_splitsupp
5
{X Y : Type} (f : X -> Y) := ExtensionAlong (@tr (-1) X) (fun _ => Y) f.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Extensions Factorization. Require Import Truncations.Core Modalities.Modality.
Constant.v
ConditionallyConstant
6
{X Y} (y : Y) : ConditionallyConstant (@const X Y y). Proof. exists (const y); intros x; reflexivity. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Extensions Factorization. Require Import Truncations.Core Modalities.Modality.
Constant.v
cconst_const
7
`{Funext} (X Y : Type) : { f : X -> Y & ConditionallyConstant f } <~> (merely X -> Y). Proof. refine (_ oE (equiv_sigma_symm _)). refine (equiv_sigma_contr _). Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Extensions Factorization. Require Import Truncations.Core Modalities.Modality.
Constant.v
equiv_cconst_from_merely
8
{X Y : Type} (f : X -> Y) (P : Type) `{IsHProp P} (g : X -> P) (h : P -> Y) (p : h o g == f) : ConditionallyConstant f. Proof. pose (g' := Trunc_rec g : merely X -> P). exists (h o g'); intros x. apply p. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Extensions Factorization. Require Import Truncations.Core Modalities.Modality.
Constant.v
cconst_factors_hprop
9
`{Funext} {X Y : Type} (f : X -> Y) (P : Type) {Pc : X -> Contr P} (g : X -> P) (h : P -> Y) (p : h o g == f) : ConditionallyConstant f. Proof. assert (merely X -> IsHProp P). { apply Trunc_rec. intros x; pose (Pc x); apply istrunc_succ. } pose (g' := Trunc_ind (fun _ => P) g : merely X -> P). exists (h o g'); intros x. apply p. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Extensions Factorization. Require Import Truncations.Core Modalities.Modality.
Constant.v
cconst_factors_contr
10
{X Y : Type} `{Collapsible X} (f : X -> Y) {wc : WeaklyConstant f} : ConditionallyConstant f. Proof. exists (f o splitsupp_collapsible); intros x. unfold splitsupp_collapsible; simpl. apply wconst. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Extensions Factorization. Require Import Truncations.Core Modalities.Modality.
Constant.v
cconst_wconst_collapsible
11
{X Y : Type} (f : X -> Y) {Ys : merely X -> IsHSet Y} {wc: WeaklyConstant f} : ConditionallyConstant f. Proof. srapply (cconst_factors_hprop f (image (-1) f)). - apply factor1. - apply factor2. - apply fact_factors. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Extensions Factorization. Require Import Truncations.Core Modalities.Modality.
Constant.v
cconst_wconst_hset_if_merely_domain
12
{X Y : Type} (f : X -> Y) {Ys : IsHSet Y} {wc : WeaklyConstant f} : ConditionallyConstant f := cconst_wconst_hset_if_merely_domain f (Ys:=fun _ => Ys).
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Extensions Factorization. Require Import Truncations.Core Modalities.Modality.
Constant.v
cconst_wconst_hset
13
{X Y : Type} (f : X -> Y) {Ys : IsHSet Y} {wc : WeaklyConstant f} : merely X -> Y := (cconst_wconst_hset f).
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Extensions Factorization. Require Import Truncations.Core Modalities.Modality.
Constant.v
merely_rec_hset
14
{X Y : Type} (f : X -> Y) {Ys : IsHSet Y} {wc : WeaklyConstant f} (x : X) : merely_rec_hset f (tr x) = f x := idpath.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Extensions Factorization. Require Import Truncations.Core Modalities.Modality.
Constant.v
merely_rec_hset_beta
15
`{Funext} {X Y : Type} (f : X -> Y) {Ys : X -> IsHSet Y} {wc : WeaklyConstant f} : ConditionallyConstant f := cconst_wconst_hset_if_merely_domain f (Ys:=Trunc_rec Ys).
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Extensions Factorization. Require Import Truncations.Core Modalities.Modality.
Constant.v
cconst_wconst_hset_if_domain
16
`{Funext} {X Y : Type} (f : X -> Y) {Ys : X -> IsHSet Y} {wc : WeaklyConstant f} : merely X -> Y := (cconst_wconst_hset_if_domain f).
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Extensions Factorization. Require Import Truncations.Core Modalities.Modality.
Constant.v
merely_rec_hset_if_domain
17
`{Funext} (X Y : Type) {Ys : X -> IsHSet Y} : { f : X -> Y & WeaklyConstant f } <~> (merely X -> Y). Proof. pose proof (Ys' := Trunc_rec Ys : merely X -> IsHSet Y). snrapply equiv_adjointify. - intros [f wc]. exact (merely_rec_hset_if_domain f (wc:=wc)). - intro g. exists (g o tr). intros x y; apply (ap g), path_ishprop. - intros g; apply path_arrow; intros mx. pose proof (Ys' mx). strip_truncations; reflexivity. - intros [f wc]. snrapply path_sigma; cbn. + reflexivity. + cbn. funext x y. pose (Ys x); apply path_ishprop. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Extensions Factorization. Require Import Truncations.Core Modalities.Modality.
Constant.v
equiv_merely_rec_hset_if_domain
18
{A B} (e : A <~> B) : e oE 1 = e. Proof. apply path_equiv; reflexivity. Defined.
Lemma
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
ecompose_e1
19
{A B} (e : A <~> B) : 1 oE e = e. Proof. apply path_equiv; reflexivity. Defined.
Lemma
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
ecompose_1e
20
{A B C D} (e : A <~> B) (f : B <~> C) (g : C <~> D) : g oE (f oE e) = (g oE f) oE e. Proof. apply path_equiv; reflexivity. Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
ecompose_e_ee
21
{A B C D} (e : A <~> B) (f : B <~> C) (g : C <~> D) : (g oE f) oE e = g oE (f oE e). Proof. apply path_equiv; reflexivity. Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
ecompose_ee_e
22
{A B} (e : A <~> B) : e oE e^-1 = 1. Proof. apply path_equiv; apply path_forall; intro; apply eisretr. Defined.
Lemma
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
ecompose_eV
23
{A B} (e : A <~> B) : e^-1 oE e = 1. Proof. apply path_equiv; apply path_forall; intro; apply eissect. Defined.
Lemma
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
ecompose_Ve
24
{A B C} (e : A <~> B) (f : B <~> C) : f^-1 oE (f oE e) = e. Proof. apply path_equiv; apply path_forall; intro; simpl; apply eissect. Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
ecompose_V_ee
25
{A B C} (e : A <~> B) (f : C <~> B) : e oE (e^-1 oE f) = f. Proof. apply path_equiv; apply path_forall; intro; simpl; apply eisretr. Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
ecompose_e_Ve
26
{A B C} (e : A <~> B) (f : B <~> C) : (f oE e) oE e^-1 = f. Proof. apply path_equiv; apply path_forall; intro; simpl; apply ap; apply eisretr. Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
ecompose_ee_V
27
{A B C} (e : B <~> A) (f : B <~> C) : (f oE e^-1) oE e = f. Proof. apply path_equiv; apply path_forall; intro; simpl; apply ap; apply eissect. Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
ecompose_eV_e
28
{A B C} (e : A <~> B) (f : B <~> C) : (f oE e)^-1 = e^-1 oE f^-1. Proof. apply path_equiv; reflexivity. Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
einv_ee
29
{A B C} (e : A <~> C) (f : B <~> C) : (f^-1 oE e)^-1 = e^-1 oE f. Proof. apply path_equiv; reflexivity. Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
einv_Ve
30
{A B C} (e : C <~> A) (f : C <~> B) : (f oE e^-1)^-1 = e oE f^-1. Proof. apply path_equiv; reflexivity. Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
einv_eV
31
{A B C} (e : A <~> B) (f : B <~> C) : (e^-1 oE f^-1)^-1 = f oE e. Proof. apply path_equiv; reflexivity. Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
einv_VV
32
{A B} (e : A <~> B) : (e^-1)^-1 = e. Proof. apply path_equiv; reflexivity. Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
einv_V
33
{A B C} (e : B <~> A) (f : B <~> C) (g : A <~> C) : e = g^-1 oE f -> g oE e = f. Proof. intro h. refine (ap (fun e => g oE e) h @ ecompose_e_Ve _ _). Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
emoveR_Me
34
{A B C} (e : B <~> A) (f : B <~> C) (g : A <~> C) : g = f oE e^-1 -> g oE e = f. Proof. intro h. refine (ap (fun g => g oE e) h @ ecompose_eV_e _ _). Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
emoveR_eM
35
{A B C} (e : B <~> A) (f : B <~> C) (g : C <~> A) : e = g oE f -> g^-1 oE e = f. Proof. intro h. refine (ap (fun e => g^-1 oE e) h @ ecompose_V_ee _ _). Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
emoveR_Ve
36
{A B C} (e : A <~> B) (f : B <~> C) (g : A <~> C) : g = f oE e -> g oE e^-1 = f. Proof. intro h. refine (ap (fun g => g oE e^-1) h @ ecompose_ee_V _ _). Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
emoveR_eV
37
{A B C} (e : A <~> B) (f : A <~> C) (g : B <~> C) : g^-1 oE f = e -> f = g oE e. Proof. intro h. refine ((ecompose_e_Ve _ _)^ @ ap (fun e => g oE e) h). Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
emoveL_Me
38
{A B C} (e : A <~> B) (f : A <~> C) (g : B <~> C) : f oE e^-1 = g -> f = g oE e. Proof. intro h. refine ((ecompose_eV_e _ _)^ @ ap (fun g => g oE e) h). Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
emoveL_eM
39
{A B C} (e : A <~> C) (f : A <~> B) (g : B <~> C) : g oE f = e -> f = g^-1 oE e. Proof. intro h. refine ((ecompose_V_ee _ _)^ @ ap (fun e => g^-1 oE e) h). Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
emoveL_Ve
40
{A B C} (e : A <~> B) (f : B <~> C) (g : A <~> C) : f oE e = g -> f = g oE e^-1. Proof. intro h. refine ((ecompose_ee_V _ _)^ @ ap (fun g => g oE e^-1) h). Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
emoveL_eV
41
{A B} (e f : A <~> B) : e oE f^-1 = 1 -> e = f. Proof. intro h. refine ((ecompose_eV_e _ _)^ @ ap (fun ef => ef oE f) h @ ecompose_1e _). Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
emoveL_1M
42
{A B} (e f : A <~> B) : f^-1 oE e = 1 -> e = f. Proof. intro h. refine ((ecompose_e_Ve _ _)^ @ ap (fun fe => f oE fe) h @ ecompose_e1 _). Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
emoveL_M1
43
{A B} (e : A <~> B) (f : B <~> A) : e oE f = 1 -> e = f^-1. Proof. intro h. refine ((ecompose_ee_V _ _)^ @ ap (fun ef => ef oE f^-1) h @ ecompose_1e _). Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
emoveL_1V
44
{A B} (e : A <~> B) (f : B <~> A) : f oE e = 1 -> e = f^-1. Proof. intro h. refine ((ecompose_V_ee _ _)^ @ ap (fun fe => f^-1 oE fe) h @ ecompose_e1 _). Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
emoveL_V1
45
{A B} (e f : A <~> B) : 1 = e^-1 oE f -> e = f. Proof. intro h. refine ((ecompose_e1 _)^ @ ap (fun ef => e oE ef) h @ ecompose_e_Ve _ _). Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
emoveR_M1
46
{A B} (e f : A <~> B) : 1 = f oE e^-1 -> e = f. Proof. intro h. refine ((ecompose_1e _)^ @ ap (fun fe => fe oE e) h @ ecompose_eV_e _ _). Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
emoveR_1M
47
{A B} (e : A <~> B) (f : B <~> A) : 1 = f oE e -> e^-1 = f. Proof. intro h. refine ((ecompose_1e _)^ @ ap (fun fe => fe oE e^-1) h @ ecompose_ee_V _ _). Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
emoveR_1V
48
{A B} (e : A <~> B) (f : B <~> A) : 1 = e oE f -> e^-1 = f. Proof. intro h. refine ((ecompose_e1 _)^ @ ap (fun ef => e^-1 oE ef) h @ ecompose_V_ee _ _). Defined.
Definition
Require Import Basics.Overture Basics.Equivalences Types.Equiv.
EquivGroupoids.v
emoveR_V1
49
forall `{ExcludedMiddle} (P : Type), IsHProp P -> P + ~P.
Axiom
Require Import HoTT.Basics HoTT.Types.
ExcludedMiddle.v
LEM
50
forall (P : Type), IsHProp P -> P + ~P.
Definition
Require Import HoTT.Basics HoTT.Types.
ExcludedMiddle.v
ExcludedMiddle_type
51
forall P, IsHProp P -> ~~P -> P.
Definition
Require Import HoTT.Basics HoTT.Types.
ExcludedMiddle.v
DNE_type
52
ExcludedMiddle -> DNE_type. Proof. intros lem P hp nnp. case (LEM P _). - auto. - intros np; elim (nnp np). Defined.
Definition
Require Import HoTT.Basics HoTT.Types.
ExcludedMiddle.v
LEM_to_DNE
53
`{Funext} : DNE_type -> ExcludedMiddle_type. Proof. intros dn P hp. refine (dn (P + ~P) _ _). - apply ishprop_sum. + exact _. + exact _. + intros p np; exact (np p). - intros nlem. apply nlem. apply inr. intros p. apply nlem. apply inl. apply p. Defined.
Definition
Require Import HoTT.Basics HoTT.Types.
ExcludedMiddle.v
DNE_to_LEM
54
(H : DNE_type) (P : Type) `{IsHProp P} : {Q : Type & P <-> ~Q}. Proof. exists (~P); split. - intros p np; exact (np p). - apply H; exact _. Defined.
Definition
Require Import HoTT.Basics HoTT.Types.
ExcludedMiddle.v
allneg_from_DNE
55
(H : forall P, IsHProp P -> {Q : Type & P <-> ~Q}) : DNE_type. Proof. intros P ? nnp. destruct (H P _) as [Q e]. apply e. intros q. apply nnp. intros p. exact (fst e p q). Defined.
Definition
Require Import HoTT.Basics HoTT.Types.
ExcludedMiddle.v
DNE_from_allneg
56
ExtensionAlong@{a b p m} {A : Type@{a}} {B : Type@{b}} (f : A -> B) (P : B -> Type@{p}) (d : forall x:A, P (f x)) := (* { s : forall y:B, P y & forall x:A, s (f x) = d x }.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
ExtensionAlong@
57
lift_extensionalong@{a1 a2 amin b1 b2 bmin p1 p2 pmin m1 m2} {A : Type@{amin}} {B : Type@{bmin}} (f : A -> B) (P : B -> Type@{pmin}) (d : forall x:A, P (f x)) : ExtensionAlong@{a1 b1 p1 m1} f P d -> ExtensionAlong@{a2 b2 p2 m2} f P d. Proof. intros ext. assert (e2 := ext.2); set (e1 := ext.1) in e2. cbn in e2. exact (e1;e2). Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
lift_extensionalong@
58
`{Funext} {A B : Type} {f : A -> B} {P : B -> Type} {d : forall x:A, P (f x)} (ext ext' : ExtensionAlong f P d) : (ExtensionAlong f (fun y => pr1 ext y = pr1 ext' y) (fun x => pr2 ext x @ (pr2 ext' x)^)) <~> ext = ext'. Proof. revert ext'. srapply equiv_path_from_contr. { unfold ExtensionAlong; cbn. exists (fun y => 1%path). intros x; symmetry; apply concat_pV. } destruct ext as [g gd]; unfold ExtensionAlong; cbn. refine (contr_sigma_sigma (forall y:B, P y) (fun s => forall x:A, s (f x) = d x) (fun a => g == a) (fun a b c => forall x:A, c (f x) = gd x @ (b x)^) g (fun y:B => idpath (g y))). refine (contr_equiv' {p:g o f == d & gd == p} _). cbn. refine (equiv_functor_sigma_id _); intros p. refine (equiv_functor_forall_id _); intros x; cbn. refine (_ oE equiv_path_inverse _ _). symmetry; apply equiv_moveR_1M. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
equiv_path_extension
59
`{Funext} {A B : Type} {f : A -> B} {P : B -> Type} {d : forall x:A, P (f x)} (ext ext' : ExtensionAlong f P d) : (ExtensionAlong f (fun y => pr1 ext y = pr1 ext' y) (fun x => pr2 ext x @ (pr2 ext' x)^)) -> ext = ext' := equiv_path_extension ext ext'.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
path_extension
60
ExtendableAlong@{i j k l} (n : nat) {A : Type@{i}} {B : Type@{j}} (f : A -> B) (C : B -> Type@{k}) : Type@{l} := match n with | 0 => Unit | S n => (forall (g : forall a, C (f a)), ExtensionAlong@{i j k l} f C g) * forall (h k : forall b, C b), ExtendableAlong n f (fun b => h b = k b) end.
Fixpoint
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
ExtendableAlong@
61
lift_extendablealong@{a1 a2 amin b1 b2 bmin p1 p2 pmin m1 m2} (n : nat) {A : Type@{amin}} {B : Type@{bmin}} (f : A -> B) (P : B -> Type@{pmin}) : ExtendableAlong@{a1 b1 p1 m1} n f P -> ExtendableAlong@{a2 b2 p2 m2} n f P. Proof. revert P; simple_induction n n IH; intros P. - intros _; exact tt. - intros ext; split. + intros g; exact (lift_extensionalong@{a1 a2 amin b1 b2 bmin p1 p2 pmin m1 m2} _ _ _ (fst ext g)). + intros h k. pose (P' := (fun b => h b = k b) : B -> Type@{pmin}). exact (IH P' (snd ext h k)). Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
lift_extendablealong@
62
`{Funext} (n : nat) {A B : Type} (C : B -> Type) (f : A -> B) : ExtendableAlong n f C <~> PathSplit n (fun (g : forall b, C b) => g oD f). Proof. generalize dependent C; simple_induction n n IHn; intros C. 1:apply equiv_idmap. refine (_ *E _); simpl. - refine (equiv_functor_forall' 1 _); intros g; simpl. refine (equiv_functor_sigma' 1 _); intros rec. apply equiv_path_forall. - refine (equiv_functor_forall' 1 _); intros h. refine (equiv_functor_forall' 1 _); intros k; simpl. refine (_ oE IHn (fun b => h b = k b)). apply equiv_inverse. refine (equiv_functor_pathsplit n _ _ (equiv_apD10 _ _ _) (equiv_apD10 _ _ _) _). intros []; reflexivity. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
equiv_extendable_pathsplit
63
`{Funext} (n : nat) {A B : Type} {C : B -> Type} {f : A -> B} : ExtendableAlong n.+2 f C -> IsEquiv (fun g => g oD f) := isequiv_pathsplit n o (equiv_extendable_pathsplit n.+2 C f). Global Instance ishprop_extendable `{Funext} (n : nat) {A B : Type} (C : B -> Type) (f : A -> B) : IsHProp (ExtendableAlong n.+2 f C). Proof. exact (istrunc_equiv_istrunc _ (equiv_extendable_pathsplit n.+2 C f)^-1). Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
isequiv_extendable
64
`{Funext} (n : nat) {A B : Type} (C : B -> Type) (f : A -> B) : ExtendableAlong n.+2 f C <~> IsEquiv (fun (g : forall b, C b) => g oD f). Proof. etransitivity. - apply equiv_extendable_pathsplit. - apply equiv_pathsplit_isequiv. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
equiv_extendable_isequiv
65
{A : Type} {B : Type} (f : A -> B) (C : B -> Type) : IsEquiv (fun (g : forall b, C b) => g oD f) -> forall g, ExtensionAlong f C g. Proof. intros E g. pose (e := Build_Equiv _ _ _ E). exists (e^-1 g). apply apD10. exact (eisretr e g). Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
extension_isequiv_precompose
66
extendable_postcompose' (n : nat) {A B : Type} (C D : B -> Type) (f : A -> B) (g : forall b, C b <~> D b) : ExtendableAlong n f C -> ExtendableAlong n f D. Proof. generalize dependent C; revert D. simple_induction n n IH; intros C D g; simpl. 1:apply idmap. refine (functor_prod _ _). - refine (functor_forall (functor_forall idmap (fun a => (g (f a))^-1)) _); intros h; simpl. refine (functor_sigma (functor_forall idmap g) _); intros k. refine (functor_forall idmap _); intros a; unfold functor_arrow, functor_forall, composeD; simpl. apply moveR_equiv_M. - refine (functor_forall (functor_forall idmap (fun b => (g b)^-1)) _); intros h. refine (functor_forall (functor_forall idmap (fun b => (g b)^-1)) _); intros k; simpl; unfold functor_forall. refine (IH _ _ _); intros b. apply equiv_inverse, equiv_ap; exact _. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
extendable_postcompose'
67
(n : nat) {A B : Type} (C D : B -> Type) (f : A -> B) (g : forall b, C b -> D b) `{forall b, IsEquiv (g b)} : ExtendableAlong n f C -> ExtendableAlong n f D := ' n C D f (fun b => Build_Equiv _ _ (g b) _).
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
extendable_postcompose
68
(n : nat) {A B C : Type} (P : C -> Type) (f : A -> B) (g : B -> C) : ExtendableAlong n g P -> ExtendableAlong n f (fun b => P (g b)) -> ExtendableAlong n (g o f) P. Proof. revert P; simple_induction n n IHn; intros P extg extf; [ exact tt | split ]. - intros h. exists ((fst extg (fst extf h).1).1); intros a. refine ((fst extg (fst extf h).1).2 (f a) @ _). exact ((fst extf h).2 a). - intros h k. apply IHn. + exact (snd extg h k). + exact (snd extf (h oD g) (k oD g)). Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
extendable_compose
69
(n : nat) {A B C : Type} (P : C -> Type) (f : A -> B) (g : B -> C) : ExtendableAlong n g P -> ExtendableAlong n (g o f) P -> ExtendableAlong n f (fun b => P (g b)). Proof. revert P; simple_induction n n IHn; intros P extg extgf; [ exact tt | split ]. - intros h. exists ((fst extgf h).1 oD g); intros a. exact ((fst extgf h).2 a). - intros h k. pose (h' := (fst extg h).1). pose (k' := (fst extg k).1). refine (extendable_postcompose' n (fun b => h' (g b) = k' (g b)) (fun b => h b = k b) f _ _). + intros b. exact (equiv_concat_lr ((fst extg h).2 b)^ ((fst extg k).2 b)). + apply (IHn (fun c => h' c = k' c) (snd extg h' k') (snd extgf h' k')). Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
cancelL_extendable
70
(n : nat) {A B C : Type} (P : C -> Type) (f : A -> B) (g : B -> C) : ExtendableAlong n.+1 f (fun b => P (g b)) -> ExtendableAlong n (g o f) P -> ExtendableAlong n g P. Proof. revert P; simple_induction n n IHn; intros P extf extgf; [ exact tt | split ]. - intros h. exists ((fst extgf (h oD f)).1); intros b. refine ((fst (snd extf ((fst extgf (h oD f)).1 oD g) h) _).1 b); intros a. apply ((fst extgf (h oD f)).2). - intros h k. apply IHn. + apply (snd extf (h oD g) (k oD g)). + apply (snd extgf h k). Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
cancelR_extendable
71
(n : nat) {A B : Type} (C : B -> Type) (f : A -> B) {g : A -> B} (p : f == g) : ExtendableAlong n f C -> ExtendableAlong n g C. Proof. revert C; simple_induction n n IHn; intros C extf; [ exact tt | split ]. - intros h. exists ((fst extf (fun a => (p a)^ # h a)).1); intros a. refine ((apD ((fst extf (fun a => (p a)^ # h a)).1) (p a))^ @ _). apply moveR_transport_p. exact ((fst extf (fun a => (p a)^ # h a)).2 a). - intros h k. apply IHn, (snd extf h k). Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
extendable_homotopic
72
(n : nat) {A B : Type} (C : B -> Type) (f : A -> B) `{IsEquiv _ _ f} : ExtendableAlong n f C. Proof. revert C; simple_induction n n IHn; intros C; [ exact tt | split ]. - intros h. exists (fun b => eisretr f b # h (f^-1 b)); intros a. refine (transport2 C (eisadj f a) _ @ _). refine ((transport_compose C f _ _)^ @ _). exact (apD h (eissect f a)). - intros h k. apply IHn. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
extendable_equiv
73
(n : nat) {A B : Type} (C : B -> Type) (f : A -> B) `{forall b, Contr (C b)} : ExtendableAlong n f C. Proof. generalize dependent C; simple_induction n n IHn; intros C ?; [ exact tt | split ]. - intros h. exists (fun _ => center _); intros a. apply contr. - intros h k. apply IHn; exact _. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
extendable_contr
74
(n : nat) {A B : Type} (C : B -> Type) (f : A -> B) (h k : forall b, C b) : ExtendableAlong n.+1 f C -> ExtendableAlong n f (fun b => h b = k b). Proof. revert C h k; simple_induction n n IHn; intros C h k ext; [exact tt | split]. - intros p. exact (fst (snd ext h k) p). - intros p q. apply IHn, ext. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
extendable_homotopy
75
ooExtendableAlong@{i j k l} {A : Type@{i}} {B : Type@{j}} (f : A -> B) (C : B -> Type@{k}) : Type@{l} := forall n : nat, ExtendableAlong@{i j k l} n f C.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
ooExtendableAlong@
76
lift_ooextendablealong@{a1 a2 amin b1 b2 bmin p1 p2 pmin m1 m2} {A : Type@{amin}} {B : Type@{bmin}} (f : A -> B) (P : B -> Type@{pmin}) : ooExtendableAlong@{a1 b1 p1 m1} f P -> ooExtendableAlong@{a2 b2 p2 m2} f P := fun ext n => lift_extendablealong@{a1 a2 amin b1 b2 bmin p1 p2 pmin m1 m2} n f P (ext n).
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
lift_ooextendablealong@
77
`{Funext} {A B : Type} (C : B -> Type) (f : A -> B) : ooExtendableAlong f C -> IsEquiv (fun g => g oD f) := fun ps => isequiv_extendable 0 (fst (ps 1%nat), snd (ps 2)).
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
isequiv_ooextendable
78
`{Funext} {A B : Type} (C : B -> Type) (f : A -> B) : ooExtendableAlong f C <~> ooPathSplit (fun (g : forall b, C b) => g oD f). Proof. refine (equiv_functor_forall' 1 _); intros n. apply equiv_extendable_pathsplit. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
equiv_ooextendable_pathsplit
79
`{Funext} {A B : Type} (C : B -> Type) (f : A -> B) : ooExtendableAlong f C <~> IsEquiv (fun (g : forall b, C b) => g oD f) := equiv_oopathsplit_isequiv _ oE equiv_ooextendable_pathsplit _ _.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
equiv_ooextendable_isequiv
80
{A B : Type} (C D : B -> Type) (f : A -> B) (g : forall b, C b -> D b) `{forall b, IsEquiv (g b)} : ooExtendableAlong f C -> ooExtendableAlong f D := fun ppp n => extendable_postcompose n C D f g (ppp n).
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
ooextendable_postcompose
81
ooextendable_postcompose' {A B : Type} (C D : B -> Type) (f : A -> B) (g : forall b, C b <~> D b) : ooExtendableAlong f C -> ooExtendableAlong f D := fun ppp n => extendable_postcompose' n C D f g (ppp n).
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
ooextendable_postcompose'
82
{A B C : Type} (P : C -> Type) (f : A -> B) (g : B -> C) : ooExtendableAlong g P -> ooExtendableAlong f (fun b => P (g b)) -> ooExtendableAlong (g o f) P := fun extg extf n => extendable_compose n P f g (extg n) (extf n).
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
ooextendable_compose
83
{A B C : Type} (P : C -> Type) (f : A -> B) (g : B -> C) : ooExtendableAlong g P -> ooExtendableAlong (g o f) P -> ooExtendableAlong f (fun b => P (g b)) := fun extg extgf n => cancelL_extendable n P f g (extg n) (extgf n).
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
cancelL_ooextendable
84
{A B C : Type} (P : C -> Type) (f : A -> B) (g : B -> C) : ooExtendableAlong f (fun b => P (g b)) -> ooExtendableAlong (g o f) P -> ooExtendableAlong g P := fun extf extgf n => cancelR_extendable n P f g (extf n.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
cancelR_ooextendable
85
{A B : Type} (C : B -> Type) (f : A -> B) {g : A -> B} (p : f == g) : ooExtendableAlong f C -> ooExtendableAlong g C := fun extf n => extendable_homotopic n C f p (extf n).
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
ooextendable_homotopic
86
{A B : Type} (C : B -> Type) (f : A -> B) `{IsEquiv _ _ f} : ooExtendableAlong f C := fun n => extendable_equiv n C f.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
ooextendable_equiv
87
{A B : Type} (C : B -> Type) (f : A -> B) `{forall b, Contr (C b)} : ooExtendableAlong f C := fun n => extendable_contr n C f.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
ooextendable_contr
88
{A B : Type} (C : B -> Type) (f : A -> B) (h k : forall b, C b) : ooExtendableAlong f C -> ooExtendableAlong f (fun b => h b = k b). Proof. intros ext n; apply extendable_homotopy, ext. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
ooextendable_homotopy
89
{A B} (f : A -> B) (C : B -> Type) : (forall b, ooExtendableAlong (const_tt (hfiber f b)) (fun _ => C b)) -> ooExtendableAlong f C. Proof. intros orth n; revert C orth. induction n as [|n IHn]; intros C orth; [exact tt | split]. - intros g. exists (fun b => (fst (orth b 1%nat) (fun x => x.2 # g x.1)).1 tt). intros a. rewrite (path_unit tt (const_tt _ a)). exact ((fst (orth (f a) 1%nat) _).2 (a ; 1)). - intros h k. apply IHn; intros b. apply ooextendable_homotopy, orth. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
ooextendable_isnull_fibers
90
{A B} (f : A -> B) (C : Cyl f -> Type) (g : forall a, C (cyl a)) (ext : ExtensionAlong cyl C g) : ExtensionAlong cyl C g. Proof. srefine (Cyl_ind C g (ext.1 o cyr) _ ; _); intros a. + refine ((ext.2 a)^ @Dl _)%dpath. apply apD. + reflexivity. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
cyl_extension
91
(n : nat) {A B} (f : A -> B) (C : Cyl f -> Type) (ext : ExtendableAlong n cyl C) : ExtendableAlong n cyl C. Proof. revert C ext; simple_induction n n IH; intros C ext; [ exact tt | split ]. - intros g. apply cyl_extension. exact (fst ext g). - intros h k; apply IH. exact (snd ext h k). Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
cyl_extendable
92
{A B} (f : A -> B) (C : Cyl f -> Type) (ext : ooExtendableAlong cyl C) : ooExtendableAlong cyl C := fun n => cyl_extendable n f C (ext n).
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
cyl_ooextendable
93
cyl_extension' {A B} (f : A -> B) (C : B -> Type) (g : forall a, C (pr_cyl (cyl a))) (ext : ExtensionAlong f C g) : ExtensionAlong cyl (C o pr_cyl) g. Proof. rapply cyl_extension. exists (ext.1 o pr_cyl). intros x; apply ext.2. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
cyl_extension'
94
cyl_extendable' (n : nat) {A B} (f : A -> B) (C : B -> Type) (ext : ExtendableAlong n f C) : ExtendableAlong n cyl (C o (pr_cyl' f)). Proof. rapply cyl_extendable. refine (cancelL_extendable n C cyl pr_cyl _ ext). rapply extendable_equiv. Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
cyl_extendable'
95
cyl_ooextendable' {A B} (f : A -> B) (C : B -> Type) (ext : ooExtendableAlong f C) : ooExtendableAlong cyl (C o (pr_cyl' f)) := fun n => cyl_extendable' n f C (ext n).
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
cyl_ooextendable'
96
{A B A' B'} (f : A -> A') (g : B -> B') (P : A' * B' -> Type) (ef : forall b', ExtendableAlong 1 f (fun a' => P (a',b'))) (eg : forall a', ExtendableAlong 1 g (fun b' => P (a',b'))) (s : forall z, P (functor_prod f g z)) : ExtensionAlong (functor_prod f g) P s. Proof. srefine (_;_). - intros [a' b']; revert b'. refine ((fst (eg a') _).1). intros b; revert a'. refine ((fst (ef (g b)) _).1). intros a. exact (s (a,b)). - intros [a b]; cbn. refine ((fst (eg (f a)) _).2 b @ _). exact ((fst (ef (g b)) _).2 a). Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
extension_functor_prod
97
(n : nat) {A B A' B'} (f : A -> A') (g : B -> B') (P : A' * B' -> Type) (ef : forall b', ExtendableAlong n f (fun a' => P (a',b'))) (eg : forall a', ExtendableAlong n g (fun b' => P (a',b'))) : ExtendableAlong n (functor_prod f g) P. Proof. revert P ef eg; simple_induction n n IH; intros P ef eg; [ exact tt | split ]. - apply extension_functor_prod. + intros b'; exact (fst (ef b'), fun _ _ => tt). + intros a'; exact (fst (eg a'), fun _ _ => tt). - intros h k; apply IH. + intros b'; apply (snd (ef b')). + intros a'; apply (snd (eg a')). Defined.
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
extendable_functor_prod
98
{A B A' B'} (f : A -> A') (g : B -> B') (P : A' * B' -> Type) (ef : forall b', ooExtendableAlong f (fun a' => P (a',b'))) (eg : forall a', ooExtendableAlong g (fun b' => P (a',b'))) : ooExtendableAlong (functor_prod f g) P := fun n => extendable_functor_prod n f g P (fun b' => ef b' n) (fun a' => eg a' n).
Definition
Require Import HoTT.Basics HoTT.Types. Require Import Equiv.PathSplit Homotopy.IdentitySystems. Require Import Cubical.DPath Cubical.DPathSquare. Require Import Colimits.Coeq Colimits.MappingCylinder.
Extensions.v
ooextendable_functor_prod
99

Coq-HoTT Dataset

Dataset Description

The Coq-HoTT Dataset is derived from the Coq-HoTT repository, focusing on the formalization of Homotopy Type Theory in the Coq proof assistant. This dataset processes .v files from the theories directory to extract mathematical content in a structured format.

This work builds upon the format established by Andreas Florath (@florath) in his Coq Facts, Propositions and Proofs dataset.

Dataset Structure

The dataset includes the following fields:

  • fact: The complete mathematical statement, including type (Definition/Lemma/Theorem), name, and body
  • imports: The Require Import statements from the source file
  • filename: The source file name within the theories directory
  • symbolic_name: The identifier of the mathematical object
  • __index_level_0__: Sequential index for the dataset

Example Row

fact: "Definition minimal(n : nat) : Type := forall m : nat, P m -> n <= m."
imports: "Require Import HoTT.Basics HoTT.Types. Require Import HoTT.Truncations.Core. Require Import HoTT.Spaces.Nat.Core."
filename: "BoundedSearch.v"
symbolic_name: "minimal"
__index_level_0__: 0

Source Code

The dataset was generated using a custom Python script that processes the Coq-HoTT repository's theories directory, extracting mathematical content while preserving the structure and relationships between definitions, imports, and their source files. ``` to clean and organize content. .v files were processed for mathematical content, while .md files were included to retain important documentation and context.

Usage:

This dataset is designed for:

  • Formal Methods Research: Analyzing formal proofs and definitions in Homotopy Type Theory.
  • Machine Learning Applications: Training models on formal verification, code completion, and theorem proving tasks.
  • Educational Purposes: Providing structured examples of Coq formalizations.

License:

This dataset is distributed under the BSD 2-clause licence, aligning with the license of the original Coq-HoTT repository.

Acknowledgments:

Downloads last month
50

Collection including phanerozoic/Coq-HoTT