2017-06-29 13:57:11 +00:00
|
|
|
|
--Authors: Robert Rose, Liz Vidaurre
|
|
|
|
|
|
2017-07-04 15:11:21 +00:00
|
|
|
|
import .direct_sum ..move_to_lib
|
2017-06-07 03:53:45 +00:00
|
|
|
|
|
|
|
|
|
open eq algebra is_trunc set_quotient relation sigma prod sum list trunc function equiv sigma.ops nat
|
|
|
|
|
|
|
|
|
|
namespace group
|
|
|
|
|
|
|
|
|
|
section
|
|
|
|
|
|
2017-06-09 16:25:09 +00:00
|
|
|
|
parameters (A : ℕ → AbGroup) (f : Πi , A i →g A (i + 1))
|
2017-06-07 05:01:19 +00:00
|
|
|
|
variables {A' : AbGroup}
|
2017-06-07 03:53:45 +00:00
|
|
|
|
|
2017-06-07 05:01:19 +00:00
|
|
|
|
definition seq_colim_carrier : AbGroup := dirsum A
|
2017-06-07 03:53:45 +00:00
|
|
|
|
inductive seq_colim_rel : seq_colim_carrier → Type :=
|
2017-06-07 05:01:19 +00:00
|
|
|
|
| rmk : Πi a, seq_colim_rel ((dirsum_incl A i a) * (dirsum_incl A (i + 1) (f i a))⁻¹)
|
|
|
|
|
|
|
|
|
|
definition seq_colim : AbGroup := quotient_ab_group_gen seq_colim_carrier (λa, ∥seq_colim_rel a∥)
|
|
|
|
|
|
2017-06-09 00:09:48 +00:00
|
|
|
|
parameters {A f}
|
2017-06-07 05:01:19 +00:00
|
|
|
|
definition seq_colim_incl [constructor] (i : ℕ) : A i →g seq_colim :=
|
2017-06-08 22:17:23 +00:00
|
|
|
|
gqg_map _ _ ∘g dirsum_incl A i
|
2017-06-07 03:53:45 +00:00
|
|
|
|
|
2017-06-07 16:30:32 +00:00
|
|
|
|
definition seq_colim_quotient (h : Πi, A i →g A') (k : Πi a, h i a = h (succ i) (f i a))
|
2017-06-07 05:01:19 +00:00
|
|
|
|
(v : seq_colim_carrier) (r : ∥seq_colim_rel v∥) : dirsum_elim h v = 1 :=
|
2017-06-07 03:53:45 +00:00
|
|
|
|
begin
|
2017-06-09 00:09:48 +00:00
|
|
|
|
induction r with r, induction r,
|
2017-06-07 16:30:32 +00:00
|
|
|
|
refine !to_respect_mul ⬝ _,
|
2017-06-09 00:09:48 +00:00
|
|
|
|
refine ap (λγ, group_fun (dirsum_elim h) (group_fun (dirsum_incl A i) a) * group_fun (dirsum_elim h) γ)
|
2017-06-08 22:17:23 +00:00
|
|
|
|
(!to_respect_inv)⁻¹ ⬝ _,
|
2017-06-09 00:09:48 +00:00
|
|
|
|
refine ap (λγ, γ * group_fun (dirsum_elim h) (group_fun (dirsum_incl A (succ i)) (f i a)⁻¹))
|
2017-06-08 22:17:23 +00:00
|
|
|
|
!dirsum_elim_compute ⬝ _,
|
2017-06-07 16:30:32 +00:00
|
|
|
|
refine ap (λγ, (h i a) * γ) !dirsum_elim_compute ⬝ _,
|
|
|
|
|
refine ap (λγ, γ * group_fun (h (succ i)) (f i a)⁻¹) !k ⬝ _,
|
|
|
|
|
refine ap (λγ, group_fun (h (succ i)) (f i a) * γ) (!to_respect_inv) ⬝ _,
|
|
|
|
|
exact !mul.right_inv
|
2017-06-07 03:53:45 +00:00
|
|
|
|
end
|
|
|
|
|
|
2017-06-07 05:01:19 +00:00
|
|
|
|
definition seq_colim_elim [constructor] (h : Πi, A i →g A')
|
2017-06-07 16:30:32 +00:00
|
|
|
|
(k : Πi a, h i a = h (succ i) (f i a)) : seq_colim →g A' :=
|
2017-06-07 03:53:45 +00:00
|
|
|
|
gqg_elim _ (dirsum_elim h) (seq_colim_quotient h k)
|
|
|
|
|
|
2017-06-08 22:17:23 +00:00
|
|
|
|
definition seq_colim_compute (h : Πi, A i →g A')
|
2017-06-09 00:09:48 +00:00
|
|
|
|
(k : Πi a, h i a = h (succ i) (f i a)) (i : ℕ) (a : A i) :
|
2017-06-08 22:17:23 +00:00
|
|
|
|
(seq_colim_elim h k) (seq_colim_incl i a) = h i a :=
|
|
|
|
|
begin
|
|
|
|
|
refine gqg_elim_compute (λa, ∥seq_colim_rel a∥) (dirsum_elim h) (seq_colim_quotient h k) (dirsum_incl A i a) ⬝ _,
|
|
|
|
|
exact !dirsum_elim_compute
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
definition seq_colim_glue {i : @trunctype.mk 0 ℕ _} {a : A i} : seq_colim_incl i a = seq_colim_incl (succ i) (f i a) :=
|
2017-06-14 22:46:54 +00:00
|
|
|
|
begin
|
|
|
|
|
refine gqg_eq_of_rel _ _,
|
|
|
|
|
exact tr (seq_colim_rel.rmk _ _)
|
|
|
|
|
end
|
2017-06-08 22:17:23 +00:00
|
|
|
|
|
|
|
|
|
section
|
|
|
|
|
local abbreviation h (m : seq_colim →g A') : Πi, A i →g A' := λi, m ∘g (seq_colim_incl i)
|
2017-06-09 00:09:48 +00:00
|
|
|
|
local abbreviation k (m : seq_colim →g A') : Πi a, h m i a = h m (succ i) (f i a) :=
|
2017-06-14 22:46:54 +00:00
|
|
|
|
λ i a, ap m (@seq_colim_glue i a)
|
2017-06-08 22:17:23 +00:00
|
|
|
|
|
2017-06-09 00:09:48 +00:00
|
|
|
|
definition seq_colim_unique (m : seq_colim →g A') :
|
2017-06-08 22:17:23 +00:00
|
|
|
|
Πv, seq_colim_elim (h m) (k m) v = m v :=
|
|
|
|
|
begin
|
|
|
|
|
intro v, refine (gqg_elim_unique _ (dirsum_elim (h m)) _ m _ _)⁻¹ ⬝ _,
|
|
|
|
|
apply dirsum_elim_unique, rotate 1, reflexivity,
|
|
|
|
|
intro i a, reflexivity
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
end
|
|
|
|
|
|
2017-06-07 03:53:45 +00:00
|
|
|
|
end
|
|
|
|
|
|
2017-06-09 00:09:48 +00:00
|
|
|
|
definition seq_colim_functor [constructor] {A A' : ℕ → AbGroup}
|
|
|
|
|
{f : Πi , A i →g A (i + 1)} {f' : Πi , A' i →g A' (i + 1)}
|
2017-06-09 16:25:09 +00:00
|
|
|
|
(h : Πi, A i →g A' i) (p : Πi, hsquare (f i) (f' i) (h i) (h (i+1))) :
|
|
|
|
|
seq_colim A f →g seq_colim A' f' :=
|
|
|
|
|
seq_colim_elim (λi, seq_colim_incl i ∘g h i)
|
|
|
|
|
begin
|
|
|
|
|
intro i a,
|
|
|
|
|
refine _ ⬝ ap (seq_colim_incl (succ i)) (p i a)⁻¹,
|
|
|
|
|
apply seq_colim_glue
|
|
|
|
|
end
|
2017-06-09 00:09:48 +00:00
|
|
|
|
|
2017-06-09 16:25:09 +00:00
|
|
|
|
-- definition seq_colim_functor_compose [constructor] {A A' A'' : ℕ → AbGroup}
|
|
|
|
|
-- {f : Πi , A i →g A (i + 1)} {f' : Πi , A' i →g A' (i + 1)} {f'' : Πi , A'' i →g A'' (i + 1)}
|
|
|
|
|
-- (h : Πi, A i →g A' i) (p : Πi (a : A i), h (i+1) (f i a) = f' i (h i a))
|
|
|
|
|
-- (h : Πi, A i →g A' i) (p : Πi (a : A i), h (i+1) (f i a) = f' i (h i a)) :
|
|
|
|
|
-- seq_colim A f →g seq_colim A' f' :=
|
|
|
|
|
-- sorry
|
2017-06-09 00:09:48 +00:00
|
|
|
|
|
2017-06-07 03:53:45 +00:00
|
|
|
|
end group
|