2015-11-16 20:30:28 +00:00
|
|
|
/-
|
|
|
|
Copyright (c) 2015 Floris van Doorn. All rights reserved.
|
|
|
|
Released under Apache 2.0 license as described in the file LICENSE.
|
|
|
|
Authors: Floris van Doorn
|
|
|
|
|
|
|
|
truncating an ∞-group to a group
|
|
|
|
-/
|
|
|
|
|
|
|
|
import hit.trunc algebra.group
|
|
|
|
|
|
|
|
open eq is_trunc trunc
|
|
|
|
|
|
|
|
namespace algebra
|
|
|
|
|
|
|
|
section
|
2016-03-06 00:35:12 +00:00
|
|
|
parameters (n : trunc_index) {A : Type} (mul : A → A → A) (inv : A → A) (one : A)
|
|
|
|
(mul_assoc : ∀a b c, mul (mul a b) c = mul a (mul b c))
|
|
|
|
(one_mul : ∀a, mul one a = a) (mul_one : ∀a, mul a one = a)
|
|
|
|
(mul_left_inv : ∀a, mul (inv a) a = one)
|
2015-11-16 20:30:28 +00:00
|
|
|
|
2016-03-06 00:35:12 +00:00
|
|
|
local abbreviation G := trunc n A
|
2015-11-16 20:30:28 +00:00
|
|
|
|
2016-03-06 00:35:12 +00:00
|
|
|
include mul
|
2015-11-16 20:30:28 +00:00
|
|
|
definition trunc_mul [unfold 9 10] (g h : G) : G :=
|
|
|
|
begin
|
2016-03-06 00:35:12 +00:00
|
|
|
induction g with p,
|
|
|
|
induction h with q,
|
2015-11-16 20:30:28 +00:00
|
|
|
exact tr (mul p q)
|
|
|
|
end
|
|
|
|
|
2016-03-06 00:35:12 +00:00
|
|
|
omit mul include inv
|
2015-11-16 20:30:28 +00:00
|
|
|
definition trunc_inv [unfold 9] (g : G) : G :=
|
|
|
|
begin
|
2016-03-06 00:35:12 +00:00
|
|
|
induction g with p,
|
2015-11-16 20:30:28 +00:00
|
|
|
exact tr (inv p)
|
|
|
|
end
|
|
|
|
|
2016-03-06 00:35:12 +00:00
|
|
|
omit inv include one
|
2015-11-16 20:30:28 +00:00
|
|
|
definition trunc_one [constructor] : G :=
|
|
|
|
tr one
|
|
|
|
|
|
|
|
local notation 1 := trunc_one
|
|
|
|
local postfix ⁻¹ := trunc_inv
|
|
|
|
local infix * := trunc_mul
|
|
|
|
|
2016-03-06 00:35:12 +00:00
|
|
|
parameters {mul} {inv} {one}
|
|
|
|
omit one include mul_assoc
|
2015-11-20 22:47:11 +00:00
|
|
|
theorem trunc_mul_assoc (g₁ g₂ g₃ : G) : g₁ * g₂ * g₃ = g₁ * (g₂ * g₃) :=
|
2015-11-16 20:30:28 +00:00
|
|
|
begin
|
2016-03-06 00:35:12 +00:00
|
|
|
induction g₁ with p₁,
|
|
|
|
induction g₂ with p₂,
|
|
|
|
induction g₃ with p₃,
|
2015-11-16 20:30:28 +00:00
|
|
|
exact ap tr !mul_assoc,
|
|
|
|
end
|
|
|
|
|
2016-03-06 00:35:12 +00:00
|
|
|
omit mul_assoc include one_mul
|
2015-11-20 22:47:11 +00:00
|
|
|
theorem trunc_one_mul (g : G) : 1 * g = g :=
|
2015-11-16 20:30:28 +00:00
|
|
|
begin
|
2016-03-06 00:35:12 +00:00
|
|
|
induction g with p,
|
2015-11-16 20:30:28 +00:00
|
|
|
exact ap tr !one_mul
|
|
|
|
end
|
|
|
|
|
2016-03-06 00:35:12 +00:00
|
|
|
omit one_mul include mul_one
|
2015-11-20 22:47:11 +00:00
|
|
|
theorem trunc_mul_one (g : G) : g * 1 = g :=
|
2015-11-16 20:30:28 +00:00
|
|
|
begin
|
2016-03-06 00:35:12 +00:00
|
|
|
induction g with p,
|
2015-11-16 20:30:28 +00:00
|
|
|
exact ap tr !mul_one
|
|
|
|
end
|
|
|
|
|
2016-03-06 00:35:12 +00:00
|
|
|
omit mul_one include mul_left_inv
|
2015-11-20 22:47:11 +00:00
|
|
|
theorem trunc_mul_left_inv (g : G) : g⁻¹ * g = 1 :=
|
2015-11-16 20:30:28 +00:00
|
|
|
begin
|
2016-03-06 00:35:12 +00:00
|
|
|
induction g with p,
|
2015-11-16 20:30:28 +00:00
|
|
|
exact ap tr !mul_left_inv
|
|
|
|
end
|
|
|
|
|
2016-03-06 00:35:12 +00:00
|
|
|
omit mul_left_inv
|
2015-11-20 22:47:11 +00:00
|
|
|
theorem trunc_mul_comm (mul_comm : ∀a b, mul a b = mul b a) (g h : G)
|
2015-11-16 20:30:28 +00:00
|
|
|
: g * h = h * g :=
|
|
|
|
begin
|
2016-03-06 00:35:12 +00:00
|
|
|
induction g with p,
|
|
|
|
induction h with q,
|
2015-11-16 20:30:28 +00:00
|
|
|
exact ap tr !mul_comm
|
|
|
|
end
|
|
|
|
|
2016-03-06 00:35:12 +00:00
|
|
|
parameters (mul) (inv) (one)
|
2015-11-16 20:30:28 +00:00
|
|
|
|
2016-03-06 00:35:12 +00:00
|
|
|
definition trunc_group [constructor] : group (trunc 0 A) :=
|
2015-11-16 20:30:28 +00:00
|
|
|
⦃group,
|
2016-03-06 00:35:12 +00:00
|
|
|
mul := algebra.trunc_mul 0 mul,
|
|
|
|
mul_assoc := algebra.trunc_mul_assoc 0 mul_assoc,
|
|
|
|
one := algebra.trunc_one 0 one,
|
|
|
|
one_mul := algebra.trunc_one_mul 0 one_mul,
|
|
|
|
mul_one := algebra.trunc_mul_one 0 mul_one,
|
|
|
|
inv := algebra.trunc_inv 0 inv,
|
|
|
|
mul_left_inv := algebra.trunc_mul_left_inv 0 mul_left_inv,
|
2016-02-15 20:18:07 +00:00
|
|
|
is_set_carrier := _⦄
|
2015-11-16 20:30:28 +00:00
|
|
|
|
2016-03-06 00:35:12 +00:00
|
|
|
definition trunc_comm_group [constructor] (mul_comm : ∀a b, mul a b = mul b a)
|
|
|
|
: comm_group (trunc 0 A) :=
|
|
|
|
⦃comm_group, trunc_group, mul_comm := algebra.trunc_mul_comm 0 mul_comm⦄
|
2015-11-16 20:30:28 +00:00
|
|
|
|
|
|
|
end
|
|
|
|
end algebra
|