Timings for JoinSusp.v
Require Import Basics Types.
Require Import Join.Core Join.JoinAssoc Suspension Spaces.Spheres.
Require Import Spaces.Nat.Core.
(** * [Join Bool A] is equivalent to [Susp A]
We give a direct proof of this fact. It is also possible to give a proof using [opyon_equiv_0gpd]; see PR#1769. *)
Definition join_to_susp (A : Type) : Join Bool A -> Susp A.
exact (fun b => if b then North else South).
Definition susp_to_join (A : Type) : Susp A -> Join Bool A.
srapply (Susp_rec (joinl true) (joinl false)).
exact (zigzag true false).
Instance isequiv_join_to_susp (A : Type) : IsEquiv (join_to_susp A).
snapply (isequiv_adjointify _ (susp_to_join A)).
lhs napply (ap _ _); [napply Susp_rec_beta_merid | ].
lhs napply (Join_rec_beta_zigzag _ _ _ true false a).
srapply (Join_ind_FFlr (join_to_susp A)); cbn beta.
1: intros [|]; reflexivity.
1: intros a; apply jglue.
lhs nrefine (ap _ _ @@ 1).
1: napply Join_rec_beta_jglue.
lhs nrefine (_ @@ 1); [napply Susp_rec_beta_merid | ].
Definition equiv_join_susp (A : Type) : Join Bool A <~> Susp A
:= Build_Equiv _ _ (join_to_susp A) _.
(** It follows that the join powers of [Bool] are spheres. These are sometimes a convenient alternative to working with spheres, so we give them a name. *)
Definition bool_pow (n : nat) := join_power Bool n.
Definition equiv_bool_pow_sphere (n : nat): bool_pow n <~> Sphere (n.-1).
refine (_ oE equiv_join_susp _).
(** It follows that joins of spheres are spheres, starting in dimension -1. *)
Definition equiv_join_sphere (n m : nat)
: Join (Sphere n.-1) (Sphere m.-1) <~> Sphere (n + m)%nat.-1.
refine (_ oE equiv_functor_join _ _).
2,3: symmetry; exact (equiv_bool_pow_sphere _).
refine (equiv_bool_pow_sphere _ oE _).