feat(library/hott) postcomposition from ua lemma is done up to the last gap
This commit is contained in:
parent
4420f0dc0c
commit
992aad9661
2 changed files with 46 additions and 11 deletions
|
@ -53,7 +53,8 @@ Equiv A B
|
|||
|
||||
namespace Equiv
|
||||
|
||||
definition equiv_fun [coercion] {A B : Type} (e : Equiv A B) : A → B :=
|
||||
--Note: No coercion here
|
||||
definition equiv_fun {A B : Type} (e : Equiv A B) : A → B :=
|
||||
Equiv.rec (λequiv_fun equiv_isequiv, equiv_fun) e
|
||||
|
||||
definition equiv_isequiv [instance] {A B : Type} (e : Equiv A B) : IsEquiv (equiv_fun e) :=
|
||||
|
@ -277,6 +278,18 @@ namespace Equiv
|
|||
|
||||
end
|
||||
|
||||
context
|
||||
parameters {A B : Type} (eqf eqg : A ≃ B)
|
||||
|
||||
private definition Hf [instance] : IsEquiv (equiv_fun eqf) := equiv_isequiv eqf
|
||||
private definition Hg [instance] : IsEquiv (equiv_fun eqg) := equiv_isequiv eqg
|
||||
|
||||
theorem inv_eq (p : eqf ≈ eqg)
|
||||
: IsEquiv.inv (equiv_fun eqf) ≈ IsEquiv.inv (equiv_fun eqg) :=
|
||||
path.rec_on p idp
|
||||
|
||||
end
|
||||
|
||||
-- calc enviroment
|
||||
-- Note: Calculating with substitutions needs univalence
|
||||
calc_trans compose
|
||||
|
|
|
@ -2,10 +2,10 @@
|
|||
-- Released under Apache 2.0 license as described in the file LICENSE.
|
||||
-- Author: Jakob von Raumer
|
||||
-- Ported from Coq HoTT
|
||||
import hott.equiv hott.equiv_precomp hott.funext_varieties
|
||||
import hott.equiv hott.funext_varieties
|
||||
import data.prod data.sigma data.unit
|
||||
|
||||
open path function prod sigma truncation Equiv unit
|
||||
open path function prod sigma truncation Equiv IsEquiv unit
|
||||
|
||||
definition isequiv_path {A B : Type} (H : A ≈ B) :=
|
||||
(@IsEquiv.transport Type (λX, X) A B H)
|
||||
|
@ -18,14 +18,36 @@ definition equiv_path {A B : Type} (H : A ≈ B) : A ≃ B :=
|
|||
definition ua_type := Π (A B : Type), IsEquiv (@equiv_path A B)
|
||||
|
||||
context
|
||||
parameters {ua : ua_type}
|
||||
parameters {ua : ua_type.{1}}
|
||||
|
||||
-- TODO base this theorem on UA instead of FunExt.
|
||||
-- IsEquiv.postcompose relies on FunExt!
|
||||
protected theorem ua_isequiv_postcompose {A B C : Type} {w : A → B} {H0 : IsEquiv w}
|
||||
: IsEquiv (@compose C A B w) :=
|
||||
!IsEquiv.postcompose
|
||||
|
||||
protected theorem ua_isequiv_postcompose {A B C : Type.{1}} {w : A → B} {H0 : IsEquiv w}
|
||||
: IsEquiv (@compose C A B w)
|
||||
:= IsEquiv.adjointify (@compose C A B w)
|
||||
(@compose C B A (IsEquiv.inv w))
|
||||
(λ (x : C → B),
|
||||
let w' := Equiv.mk w H0 in
|
||||
have foo : Equiv.equiv_fun w' ≈ w,
|
||||
from idp,
|
||||
have eqretr : equiv_path (equiv_path⁻¹ w') ≈ w',
|
||||
from (@retr _ _ (@equiv_path A B) (ua A B) w'),
|
||||
have eqinv : A ≈ B,
|
||||
from (@inv _ _ (@equiv_path A B) (ua A B) w'),
|
||||
have thoseeqs [visible] : Π (p : A ≈ B), IsEquiv (Equiv.equiv_fun (equiv_path p)),
|
||||
from (λp, Equiv.equiv_isequiv (equiv_path p)),
|
||||
have eqp : Π (p : A ≈ B) (x : C → B), equiv_path p ∘ ((equiv_path p)⁻¹ ∘ x) ≈ x,
|
||||
from (λ p,
|
||||
(@path.rec_on Type.{1} A
|
||||
(λ B' p', Π (x' : C → B'), (@equiv_path A B' p') ∘ ((equiv_path p')⁻¹ ∘ x') ≈ x')
|
||||
B p (λ x', idp))
|
||||
),
|
||||
--have eqfin : equiv_path eqinv ∘ ((equiv_path eqinv)⁻¹ eqinv ∘ x) ≈ x,
|
||||
-- from eqp eqinv,
|
||||
sorry
|
||||
)
|
||||
(λ x, sorry)
|
||||
exit
|
||||
-- We are ready to prove functional extensionality,
|
||||
-- starting with the naive non-dependent version.
|
||||
protected definition diagonal [reducible] (B : Type) : Type
|
||||
|
|
Loading…
Reference in a new issue