awhecmu/canonical-drafter-extract-mathlib huggingface dataset:
-- Lean 4 proof step from Mathlib.LinearAlgebra.Multilinear.Basic (goal)
Goal:
R : Type uR
S : Type uS
ι : Type uι
n : ℕ
M : Fin n.succ → Type v
M₁ : ι → Type v₁
M₁' : ι → Type v₁'
M₁'' : ι → Type v₁''
M₂ : Type v₂
M₃ : Type v₃
M₄ : Type v₄
M' : Type v'
inst : CommSemiring R
inst_1 : (i : ι) → AddCommMonoid (M₁ i)
inst_2 : (i : Fin n.succ) → AddCommMonoid (M i)
inst_3 : AddCommMonoid M₂
inst_4 : (i : Fin n.succ) → Module.{uR, v} R (M i)
inst_5 : (i : ι) → Module.{uR, v₁} R (M₁ i)
inst_6 : Module R M₂
f f' : MultilinearMap R M₁ M₂
inst_7 : (i : ι) → AddCommMonoid (M₁' i)
inst_8 : (i : ι) → Module.{uR, v₁'} R (M₁' i)
e : (i : ι) → LinearEquiv.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)
x : MultilinearMap R M₁' M₂
⊢ (compLinearMapₗ (M₁ := M₁') (M₁' := M₁) fun (x : ι) ↦ (↑(e x).symm : M₁' x →ₗ[R] M₁ x) :
        (a : MultilinearMap R M₁ M₂) → MultilinearMap R M₁' M₂)
      (AddHom.toFun
        (LinearMap.toAddHom (compLinearMapₗ (M₁ := M₁) (M₁' := M₁') fun (x : ι) ↦ (↑(e x) : M₁ x →ₗ[R] M₁' x))) x) =
    x
have H : ∀ (x_1 : (i : ι) → M₁' i),
  Eq.{v₂ + 1} (α := M₂)
    ((((compLinearMapₗ (M₁ := M₁') (M₁' := M₁) fun (x : ι) ↦ (↑(e x).symm : M₁' x →ₗ[R] M₁ x) :
                (a : MultilinearMap R M₁ M₂) → MultilinearMap R M₁' M₂)
              (AddHom.toFun
                (LinearMap.toAddHom (compLinearMapₗ (M₁ := M₁) (M₁' := M₁') fun (x : ι) ↦ (↑(e x) : M₁ x →ₗ[R] M₁' x)))
                x) :
            MultilinearMap R M₁' M₂) :
          (a : (i : ι) → M₁' i) → M₂)
        x_1 :
      M₂)
    ((x : (a : (i : ι) → M₁' i) → M₂) x_1 : M₂)
Tactic: ext
-- Lean 4 proof step from Mathlib.LinearAlgebra.Multilinear.Basic (goal)
Goal:
R : Type uR
S : Type uS
ι : Type uι
n : ℕ
M : Fin n.succ → Type v
M₁ : ι → Type v₁
M₁' : ι → Type v₁'
M₁'' : ι → Type v₁''
M₂ : Type v₂
M₃ : Type v₃
M₄ : Type v₄
M' : Type v'
inst : CommSemiring R
inst_1 : (i : ι) → AddCommMonoid (M₁ i)
inst_2 : (i : Fin n.succ) → AddCommMonoid (M i)
inst_3 : AddCommMonoid M₂
inst_4 : (i : Fin n.succ) → Module.{uR, v} R (M i)
inst_5 : (i : ι) → Module.{uR, v₁} R (M₁ i)
inst_6 : Module R M₂
f f' : MultilinearMap R M₁ M₂
inst_7 : (i : ι) → AddCommMonoid (M₁' i)
inst_8 : (i : ι) → Module.{uR, v₁'} R (M₁' i)
e : (i : ι) → LinearEquiv.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)
x : MultilinearMap R M₁ M₂
⊢ AddHom.toFun (M := MultilinearMap R M₁' M₂)
      (LinearMap.toAddHom (compLinearMapₗ (M₁ := M₁) (M₁' := M₁') fun (x : ι) ↦ (↑(e x) : M₁ x →ₗ[R] M₁' x)))
      ((compLinearMapₗ (M₁ := M₁') (M₁' := M₁) fun (x : ι) ↦ (↑(e x).symm : M₁' x →ₗ[R] M₁ x) :
          (a : MultilinearMap R M₁ M₂) → MultilinearMap R M₁' M₂)
        x) =
    x
have H : ∀ (x_1 : (i : ι) → M₁ i),
  Eq.{v₂ + 1} (α := M₂)
    ((AddHom.toFun (M := MultilinearMap R M₁' M₂)
            (LinearMap.toAddHom (compLinearMapₗ (M₁ := M₁) (M₁' := M₁') fun (x : ι) ↦ (↑(e x) : M₁ x →ₗ[R] M₁' x)))
            ((compLinearMapₗ (M₁ := M₁') (M₁' := M₁) fun (x : ι) ↦ (↑(e x).symm : M₁' x →ₗ[R] M₁ x) :
                (a : MultilinearMap R M₁ M₂) → MultilinearMap R M₁' M₂)
              x) :
          (a : (i : ι) → M₁ i) → M₂)
        x_1 :
      M₂)
    ((x : (a : (i : ι) → M₁ i) → M₂) x_1 : M₂)
Tactic: ext
-- Lean 4 proof step from Mathlib.LinearAlgebra.Multilinear.Basic (goal)
Goal:
R : Type uR
S : Type uS
ι : Type uι
n : ℕ
M : Fin n.succ → Type v
M₁ : ι → Type v₁
M₁' : ι → Type v₁'
M₁'' : ι → Type v₁''
M₂ : Type v₂
M₃ : Type v₃
M₄ : Type v₄
M' : Type v'
inst : CommSemiring R
inst_1 : (i : ι) → AddCommMonoid (M₁ i)
inst_2 : (i : Fin n.succ) → AddCommMonoid (M i)
inst_3 : AddCommMonoid M₂
inst_4 : (i : Fin n.succ) → Module.{uR, v} R (M i)
inst_5 : (i : ι) → Module.{uR, v₁} R (M₁ i)
inst_6 : Module R M₂
f_1 f' : MultilinearMap R M₁ M₂
inst_7 : (i : ι) → AddCommMonoid (M₁' i)
inst_8 : (i : ι) → Module.{uR, v₁'} R (M₁' i)
inst_9 : DecidableEq ι
f : (i : ι) → LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)
i : ι
f₁ f₂ : LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)
⊢ compLinearMapₗ (M₁ := M₁) (M₁' := M₁')
      (update (β := fun (i : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)) f i (f₁ + f₂)) =
    HAdd.hAdd (α := MultilinearMap R M₁' M₂ →ₗ[R] MultilinearMap R M₁ M₂)
      (compLinearMapₗ (M₁ := M₁) (M₁' := M₁')
        (update (β := fun (i : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)) f i f₁))
      (compLinearMapₗ (M₁ := M₁) (M₁' := M₁')
        (update (β := fun (i : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)) f i f₂))
have h : ∀ (g : MultilinearMap R M₁' M₂) (x : (i : ι) → M₁ i),
  Eq.{v₂ + 1} (α := M₂)
    ((((compLinearMapₗ (M₁ := M₁) (M₁' := M₁')
                  (update (β := fun (i : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)) f i
                    (f₁ + f₂)) :
                (a : MultilinearMap R M₁' M₂) → MultilinearMap R M₁ M₂)
              g :
            MultilinearMap R M₁ M₂) :
          (a : (i : ι) → M₁ i) → M₂)
        x :
      M₂)
    ((((HAdd.hAdd (α := MultilinearMap R M₁' M₂ →ₗ[R] MultilinearMap R M₁ M₂)
                  (compLinearMapₗ (M₁ := M₁) (M₁' := M₁')
                    (update (β := fun (i : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)) f i f₁))
                  (compLinearMapₗ (M₁ := M₁) (M₁' := M₁')
                    (update (β := fun (i : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)) f i f₂)) :
                (a : MultilinearMap R M₁' M₂) → MultilinearMap R M₁ M₂)
              g :
            MultilinearMap R M₁ M₂) :
          (a : (i : ι) → M₁ i) → M₂)
        x :
      M₂)
Tactic: ext g x
-- Lean 4 proof step from Mathlib.LinearAlgebra.Multilinear.Basic (goal)
Goal:
R : Type uR
S : Type uS
ι : Type uι
n : ℕ
M : Fin n.succ → Type v
M₁ : ι → Type v₁
M₁' : ι → Type v₁'
M₁'' : ι → Type v₁''
M₂ : Type v₂
M₃ : Type v₃
M₄ : Type v₄
M' : Type v'
inst : CommSemiring R
inst_1 : (i : ι) → AddCommMonoid (M₁ i)
inst_2 : (i : Fin n.succ) → AddCommMonoid (M i)
inst_3 : AddCommMonoid M₂
inst_4 : (i : Fin n.succ) → Module.{uR, v} R (M i)
inst_5 : (i : ι) → Module.{uR, v₁} R (M₁ i)
inst_6 : Module R M₂
f_1 f' : MultilinearMap R M₁ M₂
inst_7 : (i : ι) → AddCommMonoid (M₁' i)
inst_8 : (i : ι) → Module.{uR, v₁'} R (M₁' i)
inst_9 : DecidableEq ι
f : (i : ι) → LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)
i : ι
f₁ f₂ : LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)
g : MultilinearMap R M₁' M₂
x : (i : ι) → M₁ i
⊢ Eq.{v₂ + 1} (α := M₂)
    ((((compLinearMapₗ (M₁ := M₁) (M₁' := M₁')
                  (update (β := fun (i : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)) f i
                    (f₁ + f₂)) :
                (a : MultilinearMap R M₁' M₂) → MultilinearMap R M₁ M₂)
              g :
            MultilinearMap R M₁ M₂) :
          (a : (i : ι) → M₁ i) → M₂)
        x :
      M₂)
    ((((HAdd.hAdd (α := MultilinearMap R M₁' M₂ →ₗ[R] MultilinearMap R M₁ M₂)
                  (compLinearMapₗ (M₁ := M₁) (M₁' := M₁')
                    (update (β := fun (i : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)) f i f₁))
                  (compLinearMapₗ (M₁ := M₁) (M₁' := M₁')
                    (update (β := fun (i : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)) f i f₂)) :
                (a : MultilinearMap R M₁' M₂) → MultilinearMap R M₁ M₂)
              g :
            MultilinearMap R M₁ M₂) :
          (a : (i : ι) → M₁ i) → M₂)
        x :
      M₂)
have h : ((g : (a : (i : ι) → M₁' i) → M₂) fun (j : ι) ↦
    (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i (f₁ + f₂) j :
        (a : M₁ j) → M₁' j)
      (x j)) =
  HAdd.hAdd (α := M₂) (β := M₂)
    ((g : (a : (i : ι) → M₁' i) → M₂) fun (j : ι) ↦
        (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i f₁ j :
            (a : M₁ j) → M₁' j)
          (x j) :
      M₂)
    ((g : (a : (i : ι) → M₁' i) → M₂) fun (j : ι) ↦
        (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i f₂ j :
            (a : M₁ j) → M₁' j)
          (x j) :
      M₂)
Tactic: change (g fun j ↦ update f i (f₁ + f₂) j <| x j) =
        (g fun j ↦ update f i f₁ j <| x j) + g fun j ↦ update f i f₂ j (x j)
-- Lean 4 proof step from Mathlib.LinearAlgebra.Multilinear.Basic (goal)
Goal:
R : Type uR
S : Type uS
ι : Type uι
n : ℕ
M : Fin n.succ → Type v
M₁ : ι → Type v₁
M₁' : ι → Type v₁'
M₁'' : ι → Type v₁''
M₂ : Type v₂
M₃ : Type v₃
M₄ : Type v₄
M' : Type v'
inst : CommSemiring R
inst_1 : (i : ι) → AddCommMonoid (M₁ i)
inst_2 : (i : Fin n.succ) → AddCommMonoid (M i)
inst_3 : AddCommMonoid M₂
inst_4 : (i : Fin n.succ) → Module.{uR, v} R (M i)
inst_5 : (i : ι) → Module.{uR, v₁} R (M₁ i)
inst_6 : Module R M₂
f_1 f' : MultilinearMap R M₁ M₂
inst_7 : (i : ι) → AddCommMonoid (M₁' i)
inst_8 : (i : ι) → Module.{uR, v₁'} R (M₁' i)
inst_9 : DecidableEq ι
f : (i : ι) → LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)
i : ι
f₁ f₂ : LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)
g : MultilinearMap R M₁' M₂
x : (i : ι) → M₁ i
c : (i : ι) → LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i) → M₁' i :=
  fun (i : ι) (f : LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)) ↦ (f : (a : M₁ i) → M₁' i) (x i)
⊢ ((g : (a : (i : ι) → M₁' i) → M₂) fun (j : ι) ↦
      (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i (f₁ + f₂) j :
          (a : M₁ j) → M₁' j)
        (x j)) =
    HAdd.hAdd (α := M₂) (β := M₂)
      ((g : (a : (i : ι) → M₁' i) → M₂) fun (j : ι) ↦
          (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i f₁ j :
              (a : M₁ j) → M₁' j)
            (x j) :
        M₂)
      ((g : (a : (i : ι) → M₁' i) → M₂) fun (j : ι) ↦
          (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i f₂ j :
              (a : M₁ j) → M₁' j)
            (x j) :
        M₂)
have h : ∀ (j : ι),
  (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i (f₁ + f₂) j :
        (a : M₁ j) → M₁' j)
      (x j) =
    update (β := M₁') (fun (j : ι) ↦ (f j : (a : M₁ j) → M₁' j) (x j)) i
      (HAdd.hAdd (α := M₁' i) (β := M₁' i) ((f₁ : (a : M₁ i) → M₁' i) (x i) : M₁' i)
        ((f₂ : (a : M₁ i) → M₁' i) (x i) : M₁' i))
      j
Tactic: convert! g.map_update_add (fun j ↦ f j (x j)) i (f₁ (x i)) (f₂ (x i)) with j j j
-- Lean 4 proof step from Mathlib.LinearAlgebra.Multilinear.Basic (goal)
Goal:
R : Type uR
S : Type uS
ι : Type uι
n : ℕ
M : Fin n.succ → Type v
M₁ : ι → Type v₁
M₁' : ι → Type v₁'
M₁'' : ι → Type v₁''
M₂ : Type v₂
M₃ : Type v₃
M₄ : Type v₄
M' : Type v'
inst : CommSemiring R
inst_1 : (i : ι) → AddCommMonoid (M₁ i)
inst_2 : (i : Fin n.succ) → AddCommMonoid (M i)
inst_3 : AddCommMonoid M₂
inst_4 : (i : Fin n.succ) → Module.{uR, v} R (M i)
inst_5 : (i : ι) → Module.{uR, v₁} R (M₁ i)
inst_6 : Module R M₂
f_1 f' : MultilinearMap R M₁ M₂
inst_7 : (i : ι) → AddCommMonoid (M₁' i)
inst_8 : (i : ι) → Module.{uR, v₁'} R (M₁' i)
inst_9 : DecidableEq ι
f : (i : ι) → LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)
i : ι
f₁ f₂ : LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)
g : MultilinearMap R M₁' M₂
x : (i : ι) → M₁ i
c : (i : ι) → LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i) → M₁' i :=
  fun (i : ι) (f : LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)) ↦ (f : (a : M₁ i) → M₁' i) (x i)
h :
  ∀ (j : ι),
    (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i (f₁ + f₂) j :
          (a : M₁ j) → M₁' j)
        (x j) =
      update (β := M₁') (fun (j : ι) ↦ (f j : (a : M₁ j) → M₁' j) (x j)) i
        (HAdd.hAdd (α := M₁' i) (β := M₁' i) ((f₁ : (a : M₁ i) → M₁' i) (x i) : M₁' i)
          ((f₂ : (a : M₁ i) → M₁' i) (x i) : M₁' i))
        j
⊢ ((g : (a : (i : ι) → M₁' i) → M₂) fun (j : ι) ↦
      (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i (f₁ + f₂) j :
          (a : M₁ j) → M₁' j)
        (x j)) =
    HAdd.hAdd (α := M₂) (β := M₂)
      ((g : (a : (i : ι) → M₁' i) → M₂) fun (j : ι) ↦
          (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i f₁ j :
              (a : M₁ j) → M₁' j)
            (x j) :
        M₂)
      ((g : (a : (i : ι) → M₁' i) → M₂) fun (j : ι) ↦
          (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i f₂ j :
              (a : M₁ j) → M₁' j)
            (x j) :
        M₂)
have h₁ : ∀ (j : ι),
  Eq.{v₁' + 1} (α := M₁' j)
    ((update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i f₁ j :
          (a : M₁ j) → M₁' j)
        (x j) :
      M₁' j)
    (update (β := M₁') (fun (j : ι) ↦ (f j : (a : M₁ j) → M₁' j) (x j)) i ((f₁ : (a : M₁ i) → M₁' i) (x i)) j : M₁' j)
Tactic: convert! g.map_update_add (fun j ↦ f j (x j)) i (f₁ (x i)) (f₂ (x i)) with j j j
-- Lean 4 proof step from Mathlib.LinearAlgebra.Multilinear.Basic (goal)
Goal:
R : Type uR
S : Type uS
ι : Type uι
n : ℕ
M : Fin n.succ → Type v
M₁ : ι → Type v₁
M₁' : ι → Type v₁'
M₁'' : ι → Type v₁''
M₂ : Type v₂
M₃ : Type v₃
M₄ : Type v₄
M' : Type v'
inst : CommSemiring R
inst_1 : (i : ι) → AddCommMonoid (M₁ i)
inst_2 : (i : Fin n.succ) → AddCommMonoid (M i)
inst_3 : AddCommMonoid M₂
inst_4 : (i : Fin n.succ) → Module.{uR, v} R (M i)
inst_5 : (i : ι) → Module.{uR, v₁} R (M₁ i)
inst_6 : Module R M₂
f_1 f' : MultilinearMap R M₁ M₂
inst_7 : (i : ι) → AddCommMonoid (M₁' i)
inst_8 : (i : ι) → Module.{uR, v₁'} R (M₁' i)
inst_9 : DecidableEq ι
f : (i : ι) → LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)
i : ι
f₁ f₂ : LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)
g : MultilinearMap R M₁' M₂
x : (i : ι) → M₁ i
c : (i : ι) → LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i) → M₁' i :=
  fun (i : ι) (f : LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)) ↦ (f : (a : M₁ i) → M₁' i) (x i)
h :
  ∀ (j : ι),
    (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i (f₁ + f₂) j :
          (a : M₁ j) → M₁' j)
        (x j) =
      update (β := M₁') (fun (j : ι) ↦ (f j : (a : M₁ j) → M₁' j) (x j)) i
        (HAdd.hAdd (α := M₁' i) (β := M₁' i) ((f₁ : (a : M₁ i) → M₁' i) (x i) : M₁' i)
          ((f₂ : (a : M₁ i) → M₁' i) (x i) : M₁' i))
        j
h₁ :
  ∀ (j : ι),
    Eq.{v₁' + 1} (α := M₁' j)
      ((update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i f₁ j :
            (a : M₁ j) → M₁' j)
          (x j) :
        M₁' j)
      (update (β := M₁') (fun (j : ι) ↦ (f j : (a : M₁ j) → M₁' j) (x j)) i ((f₁ : (a : M₁ i) → M₁' i) (x i)) j : M₁' j)
⊢ ((g : (a : (i : ι) → M₁' i) → M₂) fun (j : ι) ↦
      (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i (f₁ + f₂) j :
          (a : M₁ j) → M₁' j)
        (x j)) =
    HAdd.hAdd (α := M₂) (β := M₂)
      ((g : (a : (i : ι) → M₁' i) → M₂) fun (j : ι) ↦
          (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i f₁ j :
              (a : M₁ j) → M₁' j)
            (x j) :
        M₂)
      ((g : (a : (i : ι) → M₁' i) → M₂) fun (j : ι) ↦
          (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i f₂ j :
              (a : M₁ j) → M₁' j)
            (x j) :
        M₂)
have h₂ : ∀ (j : ι),
  Eq.{v₁' + 1} (α := M₁' j)
    ((update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i f₂ j :
          (a : M₁ j) → M₁' j)
        (x j) :
      M₁' j)
    (update (β := M₁') (fun (j : ι) ↦ (f j : (a : M₁ j) → M₁' j) (x j)) i ((f₂ : (a : M₁ i) → M₁' i) (x i)) j : M₁' j)
Tactic: convert! g.map_update_add (fun j ↦ f j (x j)) i (f₁ (x i)) (f₂ (x i)) with j j j
-- Lean 4 proof step from Mathlib.LinearAlgebra.Multilinear.Basic (goal)
Goal:
R : Type uR
S : Type uS
ι : Type uι
n : ℕ
M : Fin n.succ → Type v
M₁ : ι → Type v₁
M₁' : ι → Type v₁'
M₁'' : ι → Type v₁''
M₂ : Type v₂
M₃ : Type v₃
M₄ : Type v₄
M' : Type v'
inst : CommSemiring R
inst_1 : (i : ι) → AddCommMonoid (M₁ i)
inst_2 : (i : Fin n.succ) → AddCommMonoid (M i)
inst_3 : AddCommMonoid M₂
inst_4 : (i : Fin n.succ) → Module.{uR, v} R (M i)
inst_5 : (i : ι) → Module.{uR, v₁} R (M₁ i)
inst_6 : Module R M₂
f_1 f' : MultilinearMap R M₁ M₂
inst_7 : (i : ι) → AddCommMonoid (M₁' i)
inst_8 : (i : ι) → Module.{uR, v₁'} R (M₁' i)
inst_9 : DecidableEq ι
f : (i : ι) → LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)
i : ι
a : R
f₀ : LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)
⊢ compLinearMapₗ (M₁ := M₁) (M₁' := M₁')
      (update (β := fun (i : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)) f i (a • f₀)) =
    HSMul.hSMul (β := MultilinearMap R M₁' M₂ →ₗ[R] MultilinearMap R M₁ M₂) a
      (compLinearMapₗ (M₁ := M₁) (M₁' := M₁')
        (update (β := fun (i : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)) f i f₀))
have h : ∀ (g : MultilinearMap R M₁' M₂) (x : (i : ι) → M₁ i),
  Eq.{v₂ + 1} (α := M₂)
    ((((compLinearMapₗ (M₁ := M₁) (M₁' := M₁')
                  (update (β := fun (i : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)) f i (a • f₀)) :
                (a : MultilinearMap R M₁' M₂) → MultilinearMap R M₁ M₂)
              g :
            MultilinearMap R M₁ M₂) :
          (a : (i : ι) → M₁ i) → M₂)
        x :
      M₂)
    ((((HSMul.hSMul (β := MultilinearMap R M₁' M₂ →ₗ[R] MultilinearMap R M₁ M₂) a
                  (compLinearMapₗ (M₁ := M₁) (M₁' := M₁')
                    (update (β := fun (i : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)) f i f₀)) :
                (a : MultilinearMap R M₁' M₂) → MultilinearMap R M₁ M₂)
              g :
            MultilinearMap R M₁ M₂) :
          (a : (i : ι) → M₁ i) → M₂)
        x :
      M₂)
Tactic: ext g x
-- Lean 4 proof step from Mathlib.LinearAlgebra.Multilinear.Basic (goal)
Goal:
R : Type uR
S : Type uS
ι : Type uι
n : ℕ
M : Fin n.succ → Type v
M₁ : ι → Type v₁
M₁' : ι → Type v₁'
M₁'' : ι → Type v₁''
M₂ : Type v₂
M₃ : Type v₃
M₄ : Type v₄
M' : Type v'
inst : CommSemiring R
inst_1 : (i : ι) → AddCommMonoid (M₁ i)
inst_2 : (i : Fin n.succ) → AddCommMonoid (M i)
inst_3 : AddCommMonoid M₂
inst_4 : (i : Fin n.succ) → Module.{uR, v} R (M i)
inst_5 : (i : ι) → Module.{uR, v₁} R (M₁ i)
inst_6 : Module R M₂
f_1 f' : MultilinearMap R M₁ M₂
inst_7 : (i : ι) → AddCommMonoid (M₁' i)
inst_8 : (i : ι) → Module.{uR, v₁'} R (M₁' i)
inst_9 : DecidableEq ι
f : (i : ι) → LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)
i : ι
a : R
f₀ : LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)
g : MultilinearMap R M₁' M₂
x : (i : ι) → M₁ i
⊢ Eq.{v₂ + 1} (α := M₂)
    ((((compLinearMapₗ (M₁ := M₁) (M₁' := M₁')
                  (update (β := fun (i : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)) f i (a • f₀)) :
                (a : MultilinearMap R M₁' M₂) → MultilinearMap R M₁ M₂)
              g :
            MultilinearMap R M₁ M₂) :
          (a : (i : ι) → M₁ i) → M₂)
        x :
      M₂)
    ((((HSMul.hSMul (β := MultilinearMap R M₁' M₂ →ₗ[R] MultilinearMap R M₁ M₂) a
                  (compLinearMapₗ (M₁ := M₁) (M₁' := M₁')
                    (update (β := fun (i : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)) f i f₀)) :
                (a : MultilinearMap R M₁' M₂) → MultilinearMap R M₁ M₂)
              g :
            MultilinearMap R M₁ M₂) :
          (a : (i : ι) → M₁ i) → M₂)
        x :
      M₂)
have h : ((g : (a : (i : ι) → M₁' i) → M₂) fun (j : ι) ↦
    (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i (a • f₀) j :
        (a : M₁ j) → M₁' j)
      (x j)) =
  HSMul.hSMul (β := M₂) a
    ((g : (a : (i : ι) → M₁' i) → M₂) fun (j : ι) ↦
        (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i f₀ j :
            (a : M₁ j) → M₁' j)
          (x j) :
      M₂)
Tactic: change (g fun j ↦ update f i (a • f₀) j <| x j) = a • g fun j ↦ update f i f₀ j (x j)
-- Lean 4 proof step from Mathlib.LinearAlgebra.Multilinear.Basic (goal)
Goal:
R : Type uR
S : Type uS
ι : Type uι
n : ℕ
M : Fin n.succ → Type v
M₁ : ι → Type v₁
M₁' : ι → Type v₁'
M₁'' : ι → Type v₁''
M₂ : Type v₂
M₃ : Type v₃
M₄ : Type v₄
M' : Type v'
inst : CommSemiring R
inst_1 : (i : ι) → AddCommMonoid (M₁ i)
inst_2 : (i : Fin n.succ) → AddCommMonoid (M i)
inst_3 : AddCommMonoid M₂
inst_4 : (i : Fin n.succ) → Module.{uR, v} R (M i)
inst_5 : (i : ι) → Module.{uR, v₁} R (M₁ i)
inst_6 : Module R M₂
f_1 f' : MultilinearMap R M₁ M₂
inst_7 : (i : ι) → AddCommMonoid (M₁' i)
inst_8 : (i : ι) → Module.{uR, v₁'} R (M₁' i)
inst_9 : DecidableEq ι
f : (i : ι) → LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)
i : ι
a : R
f₀ : LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)
g : MultilinearMap R M₁' M₂
x : (i : ι) → M₁ i
c : (i : ι) → LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i) → M₁' i :=
  fun (i : ι) (f : LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)) ↦ (f : (a : M₁ i) → M₁' i) (x i)
⊢ ((g : (a : (i : ι) → M₁' i) → M₂) fun (j : ι) ↦
      (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i (a • f₀) j :
          (a : M₁ j) → M₁' j)
        (x j)) =
    HSMul.hSMul (β := M₂) a
      ((g : (a : (i : ι) → M₁' i) → M₂) fun (j : ι) ↦
          (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i f₀ j :
              (a : M₁ j) → M₁' j)
            (x j) :
        M₂)
have h : ∀ (j : ι),
  (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i (a • f₀) j :
        (a : M₁ j) → M₁' j)
      (x j) =
    update (β := M₁') (fun (j : ι) ↦ (f j : (a : M₁ j) → M₁' j) (x j)) i
      (HSMul.hSMul (β := M₁' i) a ((f₀ : (a : M₁ i) → M₁' i) (x i) : M₁' i)) j
Tactic: convert! g.map_update_smul (fun j ↦ f j (x j)) i a (f₀ (x i)) with j j j
-- Lean 4 proof step from Mathlib.LinearAlgebra.Multilinear.Basic (goal)
Goal:
R : Type uR
S : Type uS
ι : Type uι
n : ℕ
M : Fin n.succ → Type v
M₁ : ι → Type v₁
M₁' : ι → Type v₁'
M₁'' : ι → Type v₁''
M₂ : Type v₂
M₃ : Type v₃
M₄ : Type v₄
M' : Type v'
inst : CommSemiring R
inst_1 : (i : ι) → AddCommMonoid (M₁ i)
inst_2 : (i : Fin n.succ) → AddCommMonoid (M i)
inst_3 : AddCommMonoid M₂
inst_4 : (i : Fin n.succ) → Module.{uR, v} R (M i)
inst_5 : (i : ι) → Module.{uR, v₁} R (M₁ i)
inst_6 : Module R M₂
f_1 f' : MultilinearMap R M₁ M₂
inst_7 : (i : ι) → AddCommMonoid (M₁' i)
inst_8 : (i : ι) → Module.{uR, v₁'} R (M₁' i)
inst_9 : DecidableEq ι
f : (i : ι) → LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)
i : ι
a : R
f₀ : LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)
g : MultilinearMap R M₁' M₂
x : (i : ι) → M₁ i
c : (i : ι) → LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i) → M₁' i :=
  fun (i : ι) (f : LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ i) (M₁' i)) ↦ (f : (a : M₁ i) → M₁' i) (x i)
h :
  ∀ (j : ι),
    (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i (a • f₀) j :
          (a : M₁ j) → M₁' j)
        (x j) =
      update (β := M₁') (fun (j : ι) ↦ (f j : (a : M₁ j) → M₁' j) (x j)) i
        (HSMul.hSMul (β := M₁' i) a ((f₀ : (a : M₁ i) → M₁' i) (x i) : M₁' i)) j
⊢ ((g : (a : (i : ι) → M₁' i) → M₂) fun (j : ι) ↦
      (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i (a • f₀) j :
          (a : M₁ j) → M₁' j)
        (x j)) =
    HSMul.hSMul (β := M₂) a
      ((g : (a : (i : ι) → M₁' i) → M₂) fun (j : ι) ↦
          (update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i f₀ j :
              (a : M₁ j) → M₁' j)
            (x j) :
        M₂)
have h₁ : ∀ (j : ι),
  Eq.{v₁' + 1} (α := M₁' j)
    ((update (β := fun (a : ι) ↦ LinearMap.{uR, uR, v₁, v₁'} (RingHom.id R) (M₁ a) (M₁' a)) f i f₀ j :
          (a : M₁ j) → M₁' j)
        (x j) :
      M₁' j)
    (update (β := M₁') (fun (j : ι) ↦ (f j : (a : M₁ j) → M₁' j) (x j)) i ((f₀ : (a : M₁ i) → M₁' i) (x i)) j : M₁' j)
Tactic: convert! g.map_update_smul (fun j ↦ f j (x j)) i a (f₀ (x i)) with j j j