[GOAL]
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
⊢ Group (MulAut M)
[PROOFSTEP]
refine'
  { mul := fun g h => MulEquiv.trans h g
    one := MulEquiv.refl M
    inv := MulEquiv.symm
    div := fun g h => MulEquiv.trans h.symm g
    npow := @npowRec _ ⟨MulEquiv.refl M⟩ ⟨fun g h => MulEquiv.trans h g⟩
    zpow := @zpowRec _ ⟨MulEquiv.refl M⟩ ⟨fun g h => MulEquiv.trans h g⟩ ⟨MulEquiv.symm⟩ .. }
[GOAL]
case refine'_1
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
⊢ ∀ (a b c : MulAut M), a * b * c = a * (b * c)
[PROOFSTEP]
intros
[GOAL]
case refine'_2
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
⊢ ∀ (a : MulAut M), 1 * a = a
[PROOFSTEP]
intros
[GOAL]
case refine'_3
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
⊢ ∀ (a : MulAut M), a * 1 = a
[PROOFSTEP]
intros
[GOAL]
case refine'_4
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
⊢ ∀ (x : MulAut M), npowRec 0 x = 1
[PROOFSTEP]
intros
[GOAL]
case refine'_5
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
⊢ ∀ (n : ℕ) (x : MulAut M), npowRec (n + 1) x = x * npowRec n x
[PROOFSTEP]
intros
[GOAL]
case refine'_6
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
⊢ ∀ (a b : MulAut M), a / b = a * b⁻¹
[PROOFSTEP]
intros
[GOAL]
case refine'_7
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
⊢ ∀ (a : MulAut M), zpowRec 0 a = 1
[PROOFSTEP]
intros
[GOAL]
case refine'_8
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
⊢ ∀ (n : ℕ) (a : MulAut M), zpowRec (Int.ofNat (Nat.succ n)) a = a * zpowRec (Int.ofNat n) a
[PROOFSTEP]
intros
[GOAL]
case refine'_9
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
⊢ ∀ (n : ℕ) (a : MulAut M), zpowRec (Int.negSucc n) a = (zpowRec (↑(Nat.succ n)) a)⁻¹
[PROOFSTEP]
intros
[GOAL]
case refine'_10
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
⊢ ∀ (a : MulAut M), a⁻¹ * a = 1
[PROOFSTEP]
intros
[GOAL]
case refine'_1
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
a✝ b✝ c✝ : MulAut M
⊢ a✝ * b✝ * c✝ = a✝ * (b✝ * c✝)
[PROOFSTEP]
ext
[GOAL]
case refine'_2
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
a✝ : MulAut M
⊢ 1 * a✝ = a✝
[PROOFSTEP]
ext
[GOAL]
case refine'_3
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
a✝ : MulAut M
⊢ a✝ * 1 = a✝
[PROOFSTEP]
ext
[GOAL]
case refine'_4
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
x✝ : MulAut M
⊢ npowRec 0 x✝ = 1
[PROOFSTEP]
ext
[GOAL]
case refine'_5
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
n✝ : ℕ
x✝ : MulAut M
⊢ npowRec (n✝ + 1) x✝ = x✝ * npowRec n✝ x✝
[PROOFSTEP]
ext
[GOAL]
case refine'_6
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
a✝ b✝ : MulAut M
⊢ a✝ / b✝ = a✝ * b✝⁻¹
[PROOFSTEP]
ext
[GOAL]
case refine'_7
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
a✝ : MulAut M
⊢ zpowRec 0 a✝ = 1
[PROOFSTEP]
ext
[GOAL]
case refine'_8
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
n✝ : ℕ
a✝ : MulAut M
⊢ zpowRec (Int.ofNat (Nat.succ n✝)) a✝ = a✝ * zpowRec (Int.ofNat n✝) a✝
[PROOFSTEP]
ext
[GOAL]
case refine'_9
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
n✝ : ℕ
a✝ : MulAut M
⊢ zpowRec (Int.negSucc n✝) a✝ = (zpowRec (↑(Nat.succ n✝)) a✝)⁻¹
[PROOFSTEP]
ext
[GOAL]
case refine'_10
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
a✝ : MulAut M
⊢ a✝⁻¹ * a✝ = 1
[PROOFSTEP]
ext
[GOAL]
case refine'_1.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
a✝ b✝ c✝ : MulAut M
x✝ : M
⊢ ↑(a✝ * b✝ * c✝) x✝ = ↑(a✝ * (b✝ * c✝)) x✝
[PROOFSTEP]
try rfl
[GOAL]
case refine'_1.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
a✝ b✝ c✝ : MulAut M
x✝ : M
⊢ ↑(a✝ * b✝ * c✝) x✝ = ↑(a✝ * (b✝ * c✝)) x✝
[PROOFSTEP]
rfl
[GOAL]
case refine'_2.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
a✝ : MulAut M
x✝ : M
⊢ ↑(1 * a✝) x✝ = ↑a✝ x✝
[PROOFSTEP]
try rfl
[GOAL]
case refine'_2.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
a✝ : MulAut M
x✝ : M
⊢ ↑(1 * a✝) x✝ = ↑a✝ x✝
[PROOFSTEP]
rfl
[GOAL]
case refine'_3.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
a✝ : MulAut M
x✝ : M
⊢ ↑(a✝ * 1) x✝ = ↑a✝ x✝
[PROOFSTEP]
try rfl
[GOAL]
case refine'_3.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
a✝ : MulAut M
x✝ : M
⊢ ↑(a✝ * 1) x✝ = ↑a✝ x✝
[PROOFSTEP]
rfl
[GOAL]
case refine'_4.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
x✝¹ : MulAut M
x✝ : M
⊢ ↑(npowRec 0 x✝¹) x✝ = ↑1 x✝
[PROOFSTEP]
try rfl
[GOAL]
case refine'_4.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
x✝¹ : MulAut M
x✝ : M
⊢ ↑(npowRec 0 x✝¹) x✝ = ↑1 x✝
[PROOFSTEP]
rfl
[GOAL]
case refine'_5.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
n✝ : ℕ
x✝¹ : MulAut M
x✝ : M
⊢ ↑(npowRec (n✝ + 1) x✝¹) x✝ = ↑(x✝¹ * npowRec n✝ x✝¹) x✝
[PROOFSTEP]
try rfl
[GOAL]
case refine'_5.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
n✝ : ℕ
x✝¹ : MulAut M
x✝ : M
⊢ ↑(npowRec (n✝ + 1) x✝¹) x✝ = ↑(x✝¹ * npowRec n✝ x✝¹) x✝
[PROOFSTEP]
rfl
[GOAL]
case refine'_6.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
a✝ b✝ : MulAut M
x✝ : M
⊢ ↑(a✝ / b✝) x✝ = ↑(a✝ * b✝⁻¹) x✝
[PROOFSTEP]
try rfl
[GOAL]
case refine'_6.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
a✝ b✝ : MulAut M
x✝ : M
⊢ ↑(a✝ / b✝) x✝ = ↑(a✝ * b✝⁻¹) x✝
[PROOFSTEP]
rfl
[GOAL]
case refine'_7.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
a✝ : MulAut M
x✝ : M
⊢ ↑(zpowRec 0 a✝) x✝ = ↑1 x✝
[PROOFSTEP]
try rfl
[GOAL]
case refine'_7.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
a✝ : MulAut M
x✝ : M
⊢ ↑(zpowRec 0 a✝) x✝ = ↑1 x✝
[PROOFSTEP]
rfl
[GOAL]
case refine'_8.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
n✝ : ℕ
a✝ : MulAut M
x✝ : M
⊢ ↑(zpowRec (Int.ofNat (Nat.succ n✝)) a✝) x✝ = ↑(a✝ * zpowRec (Int.ofNat n✝) a✝) x✝
[PROOFSTEP]
try rfl
[GOAL]
case refine'_8.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
n✝ : ℕ
a✝ : MulAut M
x✝ : M
⊢ ↑(zpowRec (Int.ofNat (Nat.succ n✝)) a✝) x✝ = ↑(a✝ * zpowRec (Int.ofNat n✝) a✝) x✝
[PROOFSTEP]
rfl
[GOAL]
case refine'_9.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
n✝ : ℕ
a✝ : MulAut M
x✝ : M
⊢ ↑(zpowRec (Int.negSucc n✝) a✝) x✝ = ↑(zpowRec (↑(Nat.succ n✝)) a✝)⁻¹ x✝
[PROOFSTEP]
try rfl
[GOAL]
case refine'_9.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
n✝ : ℕ
a✝ : MulAut M
x✝ : M
⊢ ↑(zpowRec (Int.negSucc n✝) a✝) x✝ = ↑(zpowRec (↑(Nat.succ n✝)) a✝)⁻¹ x✝
[PROOFSTEP]
rfl
[GOAL]
case refine'_10.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
a✝ : MulAut M
x✝ : M
⊢ ↑(a✝⁻¹ * a✝) x✝ = ↑1 x✝
[PROOFSTEP]
try rfl
[GOAL]
case refine'_10.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
a✝ : MulAut M
x✝ : M
⊢ ↑(a✝⁻¹ * a✝) x✝ = ↑1 x✝
[PROOFSTEP]
rfl
[GOAL]
case refine'_10.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
a✝ : MulAut M
x✝ : M
⊢ ↑(a✝⁻¹ * a✝) x✝ = ↑1 x✝
[PROOFSTEP]
apply Equiv.left_inv
[GOAL]
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
⊢ MulAut M →* Equiv.Perm M
[PROOFSTEP]
refine' { toFun := MulEquiv.toEquiv, .. }
[GOAL]
case refine'_1
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
⊢ 1.toEquiv = 1
[PROOFSTEP]
intros
[GOAL]
case refine'_2
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
⊢ ∀ (x y : MulAut M),
    OneHom.toFun { toFun := MulEquiv.toEquiv, map_one' := ?refine'_1 } (x * y) =
      OneHom.toFun { toFun := MulEquiv.toEquiv, map_one' := ?refine'_1 } x *
        OneHom.toFun { toFun := MulEquiv.toEquiv, map_one' := ?refine'_1 } y
[PROOFSTEP]
intros
[GOAL]
case refine'_1
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
⊢ 1.toEquiv = 1
[PROOFSTEP]
rfl
[GOAL]
case refine'_2
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Mul M
x✝ y✝ : MulAut M
⊢ OneHom.toFun { toFun := MulEquiv.toEquiv, map_one' := (_ : 1.toEquiv = 1.toEquiv) } (x✝ * y✝) =
    OneHom.toFun { toFun := MulEquiv.toEquiv, map_one' := (_ : 1.toEquiv = 1.toEquiv) } x✝ *
      OneHom.toFun { toFun := MulEquiv.toEquiv, map_one' := (_ : 1.toEquiv = 1.toEquiv) } y✝
[PROOFSTEP]
rfl
[GOAL]
A : Type u_1
M : Type u_2
G : Type u_3
inst✝¹ : Mul M
inst✝ : Group G
g x✝ : G
⊢ (fun h => g⁻¹ * h * g) ((fun h => g * h * g⁻¹) x✝) = x✝
[PROOFSTEP]
simp only [mul_assoc, inv_mul_cancel_left, mul_left_inv, mul_one]
[GOAL]
A : Type u_1
M : Type u_2
G : Type u_3
inst✝¹ : Mul M
inst✝ : Group G
g x✝ : G
⊢ (fun h => g * h * g⁻¹) ((fun h => g⁻¹ * h * g) x✝) = x✝
[PROOFSTEP]
simp only [mul_assoc, mul_inv_cancel_left, mul_right_inv, mul_one]
[GOAL]
A : Type u_1
M : Type u_2
G : Type u_3
inst✝¹ : Mul M
inst✝ : Group G
g : G
⊢ ∀ (x y : G),
    Equiv.toFun
        { toFun := fun h => g * h * g⁻¹, invFun := fun h => g⁻¹ * h * g,
          left_inv := (_ : ∀ (x : G), g⁻¹ * (g * x * g⁻¹) * g = x),
          right_inv := (_ : ∀ (x : G), g * (g⁻¹ * x * g) * g⁻¹ = x) }
        (x * y) =
      Equiv.toFun
          { toFun := fun h => g * h * g⁻¹, invFun := fun h => g⁻¹ * h * g,
            left_inv := (_ : ∀ (x : G), g⁻¹ * (g * x * g⁻¹) * g = x),
            right_inv := (_ : ∀ (x : G), g * (g⁻¹ * x * g) * g⁻¹ = x) }
          x *
        Equiv.toFun
          { toFun := fun h => g * h * g⁻¹, invFun := fun h => g⁻¹ * h * g,
            left_inv := (_ : ∀ (x : G), g⁻¹ * (g * x * g⁻¹) * g = x),
            right_inv := (_ : ∀ (x : G), g * (g⁻¹ * x * g) * g⁻¹ = x) }
          y
[PROOFSTEP]
simp only [mul_assoc, inv_mul_cancel_left, forall_const]
[GOAL]
A : Type u_1
M : Type u_2
G : Type u_3
inst✝¹ : Mul M
inst✝ : Group G
⊢ (fun g =>
        {
          toEquiv :=
            { toFun := fun h => g * h * g⁻¹, invFun := fun h => g⁻¹ * h * g,
              left_inv := (_ : ∀ (x : G), g⁻¹ * (g * x * g⁻¹) * g = x),
              right_inv := (_ : ∀ (x : G), g * (g⁻¹ * x * g) * g⁻¹ = x) },
          map_mul' := (_ : ∀ (a a_1 : G), g * (a * a_1) * g⁻¹ = g * a * g⁻¹ * (g * a_1 * g⁻¹)) })
      1 =
    1
[PROOFSTEP]
ext
[GOAL]
case h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝¹ : Mul M
inst✝ : Group G
x✝ : G
⊢ ↑((fun g =>
            {
              toEquiv :=
                { toFun := fun h => g * h * g⁻¹, invFun := fun h => g⁻¹ * h * g,
                  left_inv := (_ : ∀ (x : G), g⁻¹ * (g * x * g⁻¹) * g = x),
                  right_inv := (_ : ∀ (x : G), g * (g⁻¹ * x * g) * g⁻¹ = x) },
              map_mul' := (_ : ∀ (a a_1 : G), g * (a * a_1) * g⁻¹ = g * a * g⁻¹ * (g * a_1 * g⁻¹)) })
          1)
      x✝ =
    ↑1 x✝
[PROOFSTEP]
simp only [one_mul, inv_one, mul_one, one_apply]
[GOAL]
case h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝¹ : Mul M
inst✝ : Group G
x✝ : G
⊢ ↑{
          toEquiv :=
            { toFun := fun h => h, invFun := fun h => h, left_inv := (_ : Function.LeftInverse (fun h => h) fun h => h),
              right_inv := (_ : Function.RightInverse (fun h => h) fun h => h) },
          map_mul' :=
            (_ :
              ∀ (x y : G),
                Equiv.toFun
                    { toFun := fun h => h, invFun := fun h => h,
                      left_inv := (_ : Function.LeftInverse (fun h => h) fun h => h),
                      right_inv := (_ : Function.RightInverse (fun h => h) fun h => h) }
                    (x * y) =
                  Equiv.toFun
                      { toFun := fun h => h, invFun := fun h => h,
                        left_inv := (_ : Function.LeftInverse (fun h => h) fun h => h),
                        right_inv := (_ : Function.RightInverse (fun h => h) fun h => h) }
                      x *
                    Equiv.toFun
                      { toFun := fun h => h, invFun := fun h => h,
                        left_inv := (_ : Function.LeftInverse (fun h => h) fun h => h),
                        right_inv := (_ : Function.RightInverse (fun h => h) fun h => h) }
                      y) }
      x✝ =
    x✝
[PROOFSTEP]
rfl
[GOAL]
A : Type u_1
M : Type u_2
G : Type u_3
inst✝¹ : Mul M
inst✝ : Group G
g₁ g₂ : G
⊢ OneHom.toFun
      {
        toFun := fun g =>
          {
            toEquiv :=
              { toFun := fun h => g * h * g⁻¹, invFun := fun h => g⁻¹ * h * g,
                left_inv := (_ : ∀ (x : G), g⁻¹ * (g * x * g⁻¹) * g = x),
                right_inv := (_ : ∀ (x : G), g * (g⁻¹ * x * g) * g⁻¹ = x) },
            map_mul' := (_ : ∀ (a a_1 : G), g * (a * a_1) * g⁻¹ = g * a * g⁻¹ * (g * a_1 * g⁻¹)) },
        map_one' :=
          (_ :
            (fun g =>
                  {
                    toEquiv :=
                      { toFun := fun h => g * h * g⁻¹, invFun := fun h => g⁻¹ * h * g,
                        left_inv := (_ : ∀ (x : G), g⁻¹ * (g * x * g⁻¹) * g = x),
                        right_inv := (_ : ∀ (x : G), g * (g⁻¹ * x * g) * g⁻¹ = x) },
                    map_mul' := (_ : ∀ (a a_1 : G), g * (a * a_1) * g⁻¹ = g * a * g⁻¹ * (g * a_1 * g⁻¹)) })
                1 =
              1) }
      (g₁ * g₂) =
    OneHom.toFun
        {
          toFun := fun g =>
            {
              toEquiv :=
                { toFun := fun h => g * h * g⁻¹, invFun := fun h => g⁻¹ * h * g,
                  left_inv := (_ : ∀ (x : G), g⁻¹ * (g * x * g⁻¹) * g = x),
                  right_inv := (_ : ∀ (x : G), g * (g⁻¹ * x * g) * g⁻¹ = x) },
              map_mul' := (_ : ∀ (a a_1 : G), g * (a * a_1) * g⁻¹ = g * a * g⁻¹ * (g * a_1 * g⁻¹)) },
          map_one' :=
            (_ :
              (fun g =>
                    {
                      toEquiv :=
                        { toFun := fun h => g * h * g⁻¹, invFun := fun h => g⁻¹ * h * g,
                          left_inv := (_ : ∀ (x : G), g⁻¹ * (g * x * g⁻¹) * g = x),
                          right_inv := (_ : ∀ (x : G), g * (g⁻¹ * x * g) * g⁻¹ = x) },
                      map_mul' := (_ : ∀ (a a_1 : G), g * (a * a_1) * g⁻¹ = g * a * g⁻¹ * (g * a_1 * g⁻¹)) })
                  1 =
                1) }
        g₁ *
      OneHom.toFun
        {
          toFun := fun g =>
            {
              toEquiv :=
                { toFun := fun h => g * h * g⁻¹, invFun := fun h => g⁻¹ * h * g,
                  left_inv := (_ : ∀ (x : G), g⁻¹ * (g * x * g⁻¹) * g = x),
                  right_inv := (_ : ∀ (x : G), g * (g⁻¹ * x * g) * g⁻¹ = x) },
              map_mul' := (_ : ∀ (a a_1 : G), g * (a * a_1) * g⁻¹ = g * a * g⁻¹ * (g * a_1 * g⁻¹)) },
          map_one' :=
            (_ :
              (fun g =>
                    {
                      toEquiv :=
                        { toFun := fun h => g * h * g⁻¹, invFun := fun h => g⁻¹ * h * g,
                          left_inv := (_ : ∀ (x : G), g⁻¹ * (g * x * g⁻¹) * g = x),
                          right_inv := (_ : ∀ (x : G), g * (g⁻¹ * x * g) * g⁻¹ = x) },
                      map_mul' := (_ : ∀ (a a_1 : G), g * (a * a_1) * g⁻¹ = g * a * g⁻¹ * (g * a_1 * g⁻¹)) })
                  1 =
                1) }
        g₂
[PROOFSTEP]
ext h
[GOAL]
case h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝¹ : Mul M
inst✝ : Group G
g₁ g₂ h : G
⊢ ↑(OneHom.toFun
          {
            toFun := fun g =>
              {
                toEquiv :=
                  { toFun := fun h => g * h * g⁻¹, invFun := fun h => g⁻¹ * h * g,
                    left_inv := (_ : ∀ (x : G), g⁻¹ * (g * x * g⁻¹) * g = x),
                    right_inv := (_ : ∀ (x : G), g * (g⁻¹ * x * g) * g⁻¹ = x) },
                map_mul' := (_ : ∀ (a a_1 : G), g * (a * a_1) * g⁻¹ = g * a * g⁻¹ * (g * a_1 * g⁻¹)) },
            map_one' :=
              (_ :
                (fun g =>
                      {
                        toEquiv :=
                          { toFun := fun h => g * h * g⁻¹, invFun := fun h => g⁻¹ * h * g,
                            left_inv := (_ : ∀ (x : G), g⁻¹ * (g * x * g⁻¹) * g = x),
                            right_inv := (_ : ∀ (x : G), g * (g⁻¹ * x * g) * g⁻¹ = x) },
                        map_mul' := (_ : ∀ (a a_1 : G), g * (a * a_1) * g⁻¹ = g * a * g⁻¹ * (g * a_1 * g⁻¹)) })
                    1 =
                  1) }
          (g₁ * g₂))
      h =
    ↑(OneHom.toFun
            {
              toFun := fun g =>
                {
                  toEquiv :=
                    { toFun := fun h => g * h * g⁻¹, invFun := fun h => g⁻¹ * h * g,
                      left_inv := (_ : ∀ (x : G), g⁻¹ * (g * x * g⁻¹) * g = x),
                      right_inv := (_ : ∀ (x : G), g * (g⁻¹ * x * g) * g⁻¹ = x) },
                  map_mul' := (_ : ∀ (a a_1 : G), g * (a * a_1) * g⁻¹ = g * a * g⁻¹ * (g * a_1 * g⁻¹)) },
              map_one' :=
                (_ :
                  (fun g =>
                        {
                          toEquiv :=
                            { toFun := fun h => g * h * g⁻¹, invFun := fun h => g⁻¹ * h * g,
                              left_inv := (_ : ∀ (x : G), g⁻¹ * (g * x * g⁻¹) * g = x),
                              right_inv := (_ : ∀ (x : G), g * (g⁻¹ * x * g) * g⁻¹ = x) },
                          map_mul' := (_ : ∀ (a a_1 : G), g * (a * a_1) * g⁻¹ = g * a * g⁻¹ * (g * a_1 * g⁻¹)) })
                      1 =
                    1) }
            g₁ *
          OneHom.toFun
            {
              toFun := fun g =>
                {
                  toEquiv :=
                    { toFun := fun h => g * h * g⁻¹, invFun := fun h => g⁻¹ * h * g,
                      left_inv := (_ : ∀ (x : G), g⁻¹ * (g * x * g⁻¹) * g = x),
                      right_inv := (_ : ∀ (x : G), g * (g⁻¹ * x * g) * g⁻¹ = x) },
                  map_mul' := (_ : ∀ (a a_1 : G), g * (a * a_1) * g⁻¹ = g * a * g⁻¹ * (g * a_1 * g⁻¹)) },
              map_one' :=
                (_ :
                  (fun g =>
                        {
                          toEquiv :=
                            { toFun := fun h => g * h * g⁻¹, invFun := fun h => g⁻¹ * h * g,
                              left_inv := (_ : ∀ (x : G), g⁻¹ * (g * x * g⁻¹) * g = x),
                              right_inv := (_ : ∀ (x : G), g * (g⁻¹ * x * g) * g⁻¹ = x) },
                          map_mul' := (_ : ∀ (a a_1 : G), g * (a * a_1) * g⁻¹ = g * a * g⁻¹ * (g * a_1 * g⁻¹)) })
                      1 =
                    1) }
            g₂)
      h
[PROOFSTEP]
show g₁ * g₂ * h * (g₁ * g₂)⁻¹ = g₁ * (g₂ * h * g₂⁻¹) * g₁⁻¹
[GOAL]
case h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝¹ : Mul M
inst✝ : Group G
g₁ g₂ h : G
⊢ g₁ * g₂ * h * (g₁ * g₂)⁻¹ = g₁ * (g₂ * h * g₂⁻¹) * g₁⁻¹
[PROOFSTEP]
simp only [mul_assoc, mul_inv_rev]
[GOAL]
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
⊢ Group (AddAut A)
[PROOFSTEP]
refine'
  { mul := fun g h => AddEquiv.trans h g
    one := AddEquiv.refl A
    inv := AddEquiv.symm
    div := fun g h => AddEquiv.trans h.symm g
    npow := @npowRec _ ⟨AddEquiv.refl A⟩ ⟨fun g h => AddEquiv.trans h g⟩
    zpow := @zpowRec _ ⟨AddEquiv.refl A⟩ ⟨fun g h => AddEquiv.trans h g⟩ ⟨AddEquiv.symm⟩ .. }
[GOAL]
case refine'_1
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
⊢ ∀ (a b c : AddAut A), a * b * c = a * (b * c)
[PROOFSTEP]
intros
[GOAL]
case refine'_2
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
⊢ ∀ (a : AddAut A), 1 * a = a
[PROOFSTEP]
intros
[GOAL]
case refine'_3
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
⊢ ∀ (a : AddAut A), a * 1 = a
[PROOFSTEP]
intros
[GOAL]
case refine'_4
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
⊢ ∀ (x : AddAut A), npowRec 0 x = 1
[PROOFSTEP]
intros
[GOAL]
case refine'_5
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
⊢ ∀ (n : ℕ) (x : AddAut A), npowRec (n + 1) x = x * npowRec n x
[PROOFSTEP]
intros
[GOAL]
case refine'_6
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
⊢ ∀ (a b : AddAut A), a / b = a * b⁻¹
[PROOFSTEP]
intros
[GOAL]
case refine'_7
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
⊢ ∀ (a : AddAut A), zpowRec 0 a = 1
[PROOFSTEP]
intros
[GOAL]
case refine'_8
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
⊢ ∀ (n : ℕ) (a : AddAut A), zpowRec (Int.ofNat (Nat.succ n)) a = a * zpowRec (Int.ofNat n) a
[PROOFSTEP]
intros
[GOAL]
case refine'_9
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
⊢ ∀ (n : ℕ) (a : AddAut A), zpowRec (Int.negSucc n) a = (zpowRec (↑(Nat.succ n)) a)⁻¹
[PROOFSTEP]
intros
[GOAL]
case refine'_10
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
⊢ ∀ (a : AddAut A), a⁻¹ * a = 1
[PROOFSTEP]
intros
[GOAL]
case refine'_1
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
a✝ b✝ c✝ : AddAut A
⊢ a✝ * b✝ * c✝ = a✝ * (b✝ * c✝)
[PROOFSTEP]
ext
[GOAL]
case refine'_2
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
a✝ : AddAut A
⊢ 1 * a✝ = a✝
[PROOFSTEP]
ext
[GOAL]
case refine'_3
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
a✝ : AddAut A
⊢ a✝ * 1 = a✝
[PROOFSTEP]
ext
[GOAL]
case refine'_4
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
x✝ : AddAut A
⊢ npowRec 0 x✝ = 1
[PROOFSTEP]
ext
[GOAL]
case refine'_5
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
n✝ : ℕ
x✝ : AddAut A
⊢ npowRec (n✝ + 1) x✝ = x✝ * npowRec n✝ x✝
[PROOFSTEP]
ext
[GOAL]
case refine'_6
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
a✝ b✝ : AddAut A
⊢ a✝ / b✝ = a✝ * b✝⁻¹
[PROOFSTEP]
ext
[GOAL]
case refine'_7
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
a✝ : AddAut A
⊢ zpowRec 0 a✝ = 1
[PROOFSTEP]
ext
[GOAL]
case refine'_8
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
n✝ : ℕ
a✝ : AddAut A
⊢ zpowRec (Int.ofNat (Nat.succ n✝)) a✝ = a✝ * zpowRec (Int.ofNat n✝) a✝
[PROOFSTEP]
ext
[GOAL]
case refine'_9
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
n✝ : ℕ
a✝ : AddAut A
⊢ zpowRec (Int.negSucc n✝) a✝ = (zpowRec (↑(Nat.succ n✝)) a✝)⁻¹
[PROOFSTEP]
ext
[GOAL]
case refine'_10
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
a✝ : AddAut A
⊢ a✝⁻¹ * a✝ = 1
[PROOFSTEP]
ext
[GOAL]
case refine'_1.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
a✝ b✝ c✝ : AddAut A
x✝ : A
⊢ ↑(a✝ * b✝ * c✝) x✝ = ↑(a✝ * (b✝ * c✝)) x✝
[PROOFSTEP]
try rfl
[GOAL]
case refine'_1.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
a✝ b✝ c✝ : AddAut A
x✝ : A
⊢ ↑(a✝ * b✝ * c✝) x✝ = ↑(a✝ * (b✝ * c✝)) x✝
[PROOFSTEP]
rfl
[GOAL]
case refine'_2.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
a✝ : AddAut A
x✝ : A
⊢ ↑(1 * a✝) x✝ = ↑a✝ x✝
[PROOFSTEP]
try rfl
[GOAL]
case refine'_2.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
a✝ : AddAut A
x✝ : A
⊢ ↑(1 * a✝) x✝ = ↑a✝ x✝
[PROOFSTEP]
rfl
[GOAL]
case refine'_3.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
a✝ : AddAut A
x✝ : A
⊢ ↑(a✝ * 1) x✝ = ↑a✝ x✝
[PROOFSTEP]
try rfl
[GOAL]
case refine'_3.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
a✝ : AddAut A
x✝ : A
⊢ ↑(a✝ * 1) x✝ = ↑a✝ x✝
[PROOFSTEP]
rfl
[GOAL]
case refine'_4.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
x✝¹ : AddAut A
x✝ : A
⊢ ↑(npowRec 0 x✝¹) x✝ = ↑1 x✝
[PROOFSTEP]
try rfl
[GOAL]
case refine'_4.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
x✝¹ : AddAut A
x✝ : A
⊢ ↑(npowRec 0 x✝¹) x✝ = ↑1 x✝
[PROOFSTEP]
rfl
[GOAL]
case refine'_5.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
n✝ : ℕ
x✝¹ : AddAut A
x✝ : A
⊢ ↑(npowRec (n✝ + 1) x✝¹) x✝ = ↑(x✝¹ * npowRec n✝ x✝¹) x✝
[PROOFSTEP]
try rfl
[GOAL]
case refine'_5.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
n✝ : ℕ
x✝¹ : AddAut A
x✝ : A
⊢ ↑(npowRec (n✝ + 1) x✝¹) x✝ = ↑(x✝¹ * npowRec n✝ x✝¹) x✝
[PROOFSTEP]
rfl
[GOAL]
case refine'_6.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
a✝ b✝ : AddAut A
x✝ : A
⊢ ↑(a✝ / b✝) x✝ = ↑(a✝ * b✝⁻¹) x✝
[PROOFSTEP]
try rfl
[GOAL]
case refine'_6.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
a✝ b✝ : AddAut A
x✝ : A
⊢ ↑(a✝ / b✝) x✝ = ↑(a✝ * b✝⁻¹) x✝
[PROOFSTEP]
rfl
[GOAL]
case refine'_7.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
a✝ : AddAut A
x✝ : A
⊢ ↑(zpowRec 0 a✝) x✝ = ↑1 x✝
[PROOFSTEP]
try rfl
[GOAL]
case refine'_7.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
a✝ : AddAut A
x✝ : A
⊢ ↑(zpowRec 0 a✝) x✝ = ↑1 x✝
[PROOFSTEP]
rfl
[GOAL]
case refine'_8.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
n✝ : ℕ
a✝ : AddAut A
x✝ : A
⊢ ↑(zpowRec (Int.ofNat (Nat.succ n✝)) a✝) x✝ = ↑(a✝ * zpowRec (Int.ofNat n✝) a✝) x✝
[PROOFSTEP]
try rfl
[GOAL]
case refine'_8.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
n✝ : ℕ
a✝ : AddAut A
x✝ : A
⊢ ↑(zpowRec (Int.ofNat (Nat.succ n✝)) a✝) x✝ = ↑(a✝ * zpowRec (Int.ofNat n✝) a✝) x✝
[PROOFSTEP]
rfl
[GOAL]
case refine'_9.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
n✝ : ℕ
a✝ : AddAut A
x✝ : A
⊢ ↑(zpowRec (Int.negSucc n✝) a✝) x✝ = ↑(zpowRec (↑(Nat.succ n✝)) a✝)⁻¹ x✝
[PROOFSTEP]
try rfl
[GOAL]
case refine'_9.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
n✝ : ℕ
a✝ : AddAut A
x✝ : A
⊢ ↑(zpowRec (Int.negSucc n✝) a✝) x✝ = ↑(zpowRec (↑(Nat.succ n✝)) a✝)⁻¹ x✝
[PROOFSTEP]
rfl
[GOAL]
case refine'_10.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
a✝ : AddAut A
x✝ : A
⊢ ↑(a✝⁻¹ * a✝) x✝ = ↑1 x✝
[PROOFSTEP]
try rfl
[GOAL]
case refine'_10.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
a✝ : AddAut A
x✝ : A
⊢ ↑(a✝⁻¹ * a✝) x✝ = ↑1 x✝
[PROOFSTEP]
rfl
[GOAL]
case refine'_10.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
a✝ : AddAut A
x✝ : A
⊢ ↑(a✝⁻¹ * a✝) x✝ = ↑1 x✝
[PROOFSTEP]
apply Equiv.left_inv
[GOAL]
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
⊢ AddAut A →* Equiv.Perm A
[PROOFSTEP]
refine' { toFun := AddEquiv.toEquiv, .. }
[GOAL]
case refine'_1
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
⊢ 1.toEquiv = 1
[PROOFSTEP]
intros
[GOAL]
case refine'_2
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
⊢ ∀ (x y : AddAut A),
    OneHom.toFun { toFun := AddEquiv.toEquiv, map_one' := ?refine'_1 } (x * y) =
      OneHom.toFun { toFun := AddEquiv.toEquiv, map_one' := ?refine'_1 } x *
        OneHom.toFun { toFun := AddEquiv.toEquiv, map_one' := ?refine'_1 } y
[PROOFSTEP]
intros
[GOAL]
case refine'_1
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
⊢ 1.toEquiv = 1
[PROOFSTEP]
rfl
[GOAL]
case refine'_2
A : Type u_1
M : Type u_2
G : Type u_3
inst✝ : Add A
x✝ y✝ : AddAut A
⊢ OneHom.toFun { toFun := AddEquiv.toEquiv, map_one' := (_ : 1.toEquiv = 1.toEquiv) } (x✝ * y✝) =
    OneHom.toFun { toFun := AddEquiv.toEquiv, map_one' := (_ : 1.toEquiv = 1.toEquiv) } x✝ *
      OneHom.toFun { toFun := AddEquiv.toEquiv, map_one' := (_ : 1.toEquiv = 1.toEquiv) } y✝
[PROOFSTEP]
rfl
[GOAL]
A : Type u_1
M : Type u_2
G : Type u_3
inst✝¹ : Add A
inst✝ : AddGroup G
g x✝ : G
⊢ (fun h => -g + h + g) ((fun h => g + h + -g) x✝) = x✝
[PROOFSTEP]
simp only [add_assoc, neg_add_cancel_left, add_left_neg, add_zero]
[GOAL]
A : Type u_1
M : Type u_2
G : Type u_3
inst✝¹ : Add A
inst✝ : AddGroup G
g x✝ : G
⊢ (fun h => g + h + -g) ((fun h => -g + h + g) x✝) = x✝
[PROOFSTEP]
simp only [add_assoc, add_neg_cancel_left, add_right_neg, add_zero]
[GOAL]
A : Type u_1
M : Type u_2
G : Type u_3
inst✝¹ : Add A
inst✝ : AddGroup G
g : G
⊢ ∀ (x y : G),
    Equiv.toFun
        { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
          left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
          right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) }
        (x + y) =
      Equiv.toFun
          { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
            left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
            right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) }
          x +
        Equiv.toFun
          { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
            left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
            right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) }
          y
[PROOFSTEP]
simp only [add_assoc, neg_add_cancel_left, forall_const]
[GOAL]
A : Type u_1
M : Type u_2
G : Type u_3
inst✝¹ : Add A
inst✝ : AddGroup G
⊢ (fun g =>
        ↑Additive.ofMul
          {
            toEquiv :=
              { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
            map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) })
      0 =
    0
[PROOFSTEP]
apply Additive.toMul.injective
[GOAL]
case a
A : Type u_1
M : Type u_2
G : Type u_3
inst✝¹ : Add A
inst✝ : AddGroup G
⊢ ↑Additive.toMul
      ((fun g =>
          ↑Additive.ofMul
            {
              toEquiv :=
                { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                  left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                  right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
              map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) })
        0) =
    ↑Additive.toMul 0
[PROOFSTEP]
ext
[GOAL]
case a.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝¹ : Add A
inst✝ : AddGroup G
x✝ : G
⊢ ↑(↑Additive.toMul
          ((fun g =>
              ↑Additive.ofMul
                {
                  toEquiv :=
                    { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                      left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                      right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
                  map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) })
            0))
      x✝ =
    ↑(↑Additive.toMul 0) x✝
[PROOFSTEP]
simp only [zero_add, neg_zero, add_zero, toMul_ofMul, toMul_zero, one_apply]
[GOAL]
case a.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝¹ : Add A
inst✝ : AddGroup G
x✝ : G
⊢ ↑{
          toEquiv :=
            { toFun := fun h => h, invFun := fun h => h, left_inv := (_ : Function.LeftInverse (fun h => h) fun h => h),
              right_inv := (_ : Function.RightInverse (fun h => h) fun h => h) },
          map_add' :=
            (_ :
              ∀ (x y : G),
                Equiv.toFun
                    { toFun := fun h => h, invFun := fun h => h,
                      left_inv := (_ : Function.LeftInverse (fun h => h) fun h => h),
                      right_inv := (_ : Function.RightInverse (fun h => h) fun h => h) }
                    (x + y) =
                  Equiv.toFun
                      { toFun := fun h => h, invFun := fun h => h,
                        left_inv := (_ : Function.LeftInverse (fun h => h) fun h => h),
                        right_inv := (_ : Function.RightInverse (fun h => h) fun h => h) }
                      x +
                    Equiv.toFun
                      { toFun := fun h => h, invFun := fun h => h,
                        left_inv := (_ : Function.LeftInverse (fun h => h) fun h => h),
                        right_inv := (_ : Function.RightInverse (fun h => h) fun h => h) }
                      y) }
      x✝ =
    x✝
[PROOFSTEP]
rfl
[GOAL]
A : Type u_1
M : Type u_2
G : Type u_3
inst✝¹ : Add A
inst✝ : AddGroup G
g₁ g₂ : G
⊢ ZeroHom.toFun
      {
        toFun := fun g =>
          ↑Additive.ofMul
            {
              toEquiv :=
                { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                  left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                  right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
              map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) },
        map_zero' :=
          (_ :
            (fun g =>
                  ↑Additive.ofMul
                    {
                      toEquiv :=
                        { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                          left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                          right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
                      map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) })
                0 =
              0) }
      (g₁ + g₂) =
    ZeroHom.toFun
        {
          toFun := fun g =>
            ↑Additive.ofMul
              {
                toEquiv :=
                  { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                    left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                    right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
                map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) },
          map_zero' :=
            (_ :
              (fun g =>
                    ↑Additive.ofMul
                      {
                        toEquiv :=
                          { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                            left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                            right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
                        map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) })
                  0 =
                0) }
        g₁ +
      ZeroHom.toFun
        {
          toFun := fun g =>
            ↑Additive.ofMul
              {
                toEquiv :=
                  { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                    left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                    right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
                map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) },
          map_zero' :=
            (_ :
              (fun g =>
                    ↑Additive.ofMul
                      {
                        toEquiv :=
                          { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                            left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                            right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
                        map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) })
                  0 =
                0) }
        g₂
[PROOFSTEP]
apply Additive.toMul.injective
[GOAL]
case a
A : Type u_1
M : Type u_2
G : Type u_3
inst✝¹ : Add A
inst✝ : AddGroup G
g₁ g₂ : G
⊢ ↑Additive.toMul
      (ZeroHom.toFun
        {
          toFun := fun g =>
            ↑Additive.ofMul
              {
                toEquiv :=
                  { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                    left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                    right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
                map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) },
          map_zero' :=
            (_ :
              (fun g =>
                    ↑Additive.ofMul
                      {
                        toEquiv :=
                          { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                            left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                            right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
                        map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) })
                  0 =
                0) }
        (g₁ + g₂)) =
    ↑Additive.toMul
      (ZeroHom.toFun
          {
            toFun := fun g =>
              ↑Additive.ofMul
                {
                  toEquiv :=
                    { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                      left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                      right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
                  map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) },
            map_zero' :=
              (_ :
                (fun g =>
                      ↑Additive.ofMul
                        {
                          toEquiv :=
                            { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                              left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                              right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
                          map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) })
                    0 =
                  0) }
          g₁ +
        ZeroHom.toFun
          {
            toFun := fun g =>
              ↑Additive.ofMul
                {
                  toEquiv :=
                    { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                      left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                      right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
                  map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) },
            map_zero' :=
              (_ :
                (fun g =>
                      ↑Additive.ofMul
                        {
                          toEquiv :=
                            { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                              left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                              right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
                          map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) })
                    0 =
                  0) }
          g₂)
[PROOFSTEP]
ext h
[GOAL]
case a.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝¹ : Add A
inst✝ : AddGroup G
g₁ g₂ h : G
⊢ ↑(↑Additive.toMul
          (ZeroHom.toFun
            {
              toFun := fun g =>
                ↑Additive.ofMul
                  {
                    toEquiv :=
                      { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                        left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                        right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
                    map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) },
              map_zero' :=
                (_ :
                  (fun g =>
                        ↑Additive.ofMul
                          {
                            toEquiv :=
                              { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                                left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                                right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
                            map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) })
                      0 =
                    0) }
            (g₁ + g₂)))
      h =
    ↑(↑Additive.toMul
          (ZeroHom.toFun
              {
                toFun := fun g =>
                  ↑Additive.ofMul
                    {
                      toEquiv :=
                        { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                          left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                          right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
                      map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) },
                map_zero' :=
                  (_ :
                    (fun g =>
                          ↑Additive.ofMul
                            {
                              toEquiv :=
                                { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                                  left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                                  right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
                              map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) })
                        0 =
                      0) }
              g₁ +
            ZeroHom.toFun
              {
                toFun := fun g =>
                  ↑Additive.ofMul
                    {
                      toEquiv :=
                        { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                          left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                          right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
                      map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) },
                map_zero' :=
                  (_ :
                    (fun g =>
                          ↑Additive.ofMul
                            {
                              toEquiv :=
                                { toFun := fun h => g + h + -g, invFun := fun h => -g + h + g,
                                  left_inv := (_ : ∀ (x : G), -g + (g + x + -g) + g = x),
                                  right_inv := (_ : ∀ (x : G), g + (-g + x + g) + -g = x) },
                              map_add' := (_ : ∀ (a a_1 : G), g + (a + a_1) + -g = g + a + -g + (g + a_1 + -g)) })
                        0 =
                      0) }
              g₂))
      h
[PROOFSTEP]
show g₁ + g₂ + h + -(g₁ + g₂) = g₁ + (g₂ + h + -g₂) + -g₁
[GOAL]
case a.h
A : Type u_1
M : Type u_2
G : Type u_3
inst✝¹ : Add A
inst✝ : AddGroup G
g₁ g₂ h : G
⊢ g₁ + g₂ + h + -(g₁ + g₂) = g₁ + (g₂ + h + -g₂) + -g₁
[PROOFSTEP]
simp only [add_assoc, neg_add_rev]