Documentation

Mathlib.Data.Matrix.Basic

Matrices #

This file defines basic properties of matrices.

Matrices with rows indexed by m, columns indexed by n, and entries of type α are represented with Matrix m n α. For the typical approach of counting rows and columns, Matrix (Fin m) (Fin n) α can be used.

Notation #

The locale Matrix gives the following notation:

Implementation notes #

For convenience, Matrix m n α is defined as m → n → α, as this allows elements of the matrix to be accessed with A i j. However, it is not advisable to construct matrices using terms of the form λ i j, _ or even (λ i j, _ : Matrix m n α), as these are not recognized by lean as having the right type. Instead, Matrix.of should be used.

TODO #

Under various conditions, multiplication of infinite matrices makes sense. These have not yet been implemented.

def Matrix (m : Type u) (n : Type u') (α : Type v) :
Type (max u u' v)

Matrix m n R is the type of matrices with entries in R, whose rows are indexed by m and whose columns are indexed by n.

Equations
Instances For
    theorem Matrix.ext_iff {m : Type u_2} {n : Type u_3} {α : Type v} {M : Matrix m n α} {N : Matrix m n α} :
    (∀ (i : m) (j : n), M i j = N i j) M = N
    theorem Matrix.ext {m : Type u_2} {n : Type u_3} {α : Type v} {M : Matrix m n α} {N : Matrix m n α} :
    (∀ (i : m) (j : n), M i j = N i j) → M = N
    theorem Matrix.ext' {m : Type u_2} {n : Type u_3} {α : Type v} {M : Matrix m n α} {N : Matrix m n α} :
    (∀ (i : m), M i = N i) → M = N
    def Matrix.of {m : Type u_2} {n : Type u_3} {α : Type v} :
    (mnα) Matrix m n α

    Cast a function into a matrix.

    The two sides of the equivalence are definitionally equal types. We want to use an explicit cast to distinguish the types because Matrix has different instances to pi types (such as Pi.mul, which performs elementwise multiplication, vs Matrix.mul).

    If you are defining a matrix, in terms of its entries, use of (fun i j ↦ _). The purpose of this approach is to ensure that terms of the form (fun i j ↦ _) * (fun i j ↦ _) do not appear, as the type of * can be misleading.

    Porting note: In Lean 3, it is also safe to use pattern matching in a definition as | i j := _, which can only be unfolded when fully-applied. leanprover/lean4#2042 means this does not (currently) work in Lean 4.

    Equations
    Instances For
      @[simp]
      theorem Matrix.of_apply {m : Type u_2} {n : Type u_3} {α : Type v} (f : mnα) (i : m) (j : n) :
      Matrix.of f i j = f i j
      @[simp]
      theorem Matrix.of_symm_apply {m : Type u_2} {n : Type u_3} {α : Type v} (f : Matrix m n α) (i : m) (j : n) :
      Matrix.of.symm f i j = f i j
      def Matrix.map {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} (M : Matrix m n α) (f : αβ) :
      Matrix m n β

      M.map f is the matrix obtained by applying f to each entry of the matrix M.

      This is available in bundled forms as:

      Equations
      Instances For
        @[simp]
        theorem Matrix.map_apply {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} {M : Matrix m n α} {f : αβ} {i : m} {j : n} :
        Matrix.map M f i j = f (M i j)
        @[simp]
        theorem Matrix.map_id {m : Type u_2} {n : Type u_3} {α : Type v} (M : Matrix m n α) :
        Matrix.map M id = M
        @[simp]
        theorem Matrix.map_map {m : Type u_2} {n : Type u_3} {α : Type v} {M : Matrix m n α} {β : Type u_10} {γ : Type u_11} {f : αβ} {g : βγ} :
        theorem Matrix.map_injective {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} {f : αβ} (hf : Function.Injective f) :
        def Matrix.transpose {m : Type u_2} {n : Type u_3} {α : Type v} (M : Matrix m n α) :
        Matrix n m α

        The transpose of a matrix.

        Equations
        Instances For
          @[simp]
          theorem Matrix.transpose_apply {m : Type u_2} {n : Type u_3} {α : Type v} (M : Matrix m n α) (i : n) (j : m) :
          Matrix.transpose M i j = M j i

          The transpose of a matrix.

          Equations
          Instances For
            def Matrix.conjTranspose {m : Type u_2} {n : Type u_3} {α : Type v} [Star α] (M : Matrix m n α) :
            Matrix n m α

            The conjugate transpose of a matrix defined in term of star.

            Equations
            Instances For

              The conjugate transpose of a matrix defined in term of star.

              Equations
              Instances For
                def Matrix.col {m : Type u_2} {α : Type v} (w : mα) :

                Matrix.col u is the column matrix whose entries are given by u.

                Equations
                Instances For
                  @[simp]
                  theorem Matrix.col_apply {m : Type u_2} {α : Type v} (w : mα) (i : m) (j : Unit) :
                  Matrix.col w i j = w i
                  def Matrix.row {n : Type u_3} {α : Type v} (v : nα) :

                  Matrix.row u is the row matrix whose entries are given by u.

                  Equations
                  Instances For
                    @[simp]
                    theorem Matrix.row_apply {n : Type u_3} {α : Type v} (v : nα) (i : Unit) (j : n) :
                    Matrix.row v i j = v j
                    instance Matrix.inhabited {m : Type u_2} {n : Type u_3} {α : Type v} [Inhabited α] :
                    Inhabited (Matrix m n α)
                    Equations
                    instance Matrix.decidableEq {m : Type u_2} {n : Type u_3} {α : Type v} [DecidableEq α] [Fintype m] [Fintype n] :
                    Equations
                    • Matrix.decidableEq = Fintype.decidablePiFintype
                    instance Matrix.add {m : Type u_2} {n : Type u_3} {α : Type v} [Add α] :
                    Add (Matrix m n α)
                    Equations
                    • Matrix.add = Pi.instAdd
                    instance Matrix.addSemigroup {m : Type u_2} {n : Type u_3} {α : Type v} [AddSemigroup α] :
                    Equations
                    • Matrix.addSemigroup = Pi.addSemigroup
                    instance Matrix.addCommSemigroup {m : Type u_2} {n : Type u_3} {α : Type v} [AddCommSemigroup α] :
                    Equations
                    • Matrix.addCommSemigroup = Pi.addCommSemigroup
                    instance Matrix.zero {m : Type u_2} {n : Type u_3} {α : Type v} [Zero α] :
                    Zero (Matrix m n α)
                    Equations
                    • Matrix.zero = Pi.instZero
                    instance Matrix.addZeroClass {m : Type u_2} {n : Type u_3} {α : Type v} [AddZeroClass α] :
                    Equations
                    • Matrix.addZeroClass = Pi.addZeroClass
                    instance Matrix.addMonoid {m : Type u_2} {n : Type u_3} {α : Type v} [AddMonoid α] :
                    AddMonoid (Matrix m n α)
                    Equations
                    • Matrix.addMonoid = Pi.addMonoid
                    instance Matrix.addCommMonoid {m : Type u_2} {n : Type u_3} {α : Type v} [AddCommMonoid α] :
                    Equations
                    • Matrix.addCommMonoid = Pi.addCommMonoid
                    instance Matrix.neg {m : Type u_2} {n : Type u_3} {α : Type v} [Neg α] :
                    Neg (Matrix m n α)
                    Equations
                    • Matrix.neg = Pi.instNeg
                    instance Matrix.sub {m : Type u_2} {n : Type u_3} {α : Type v} [Sub α] :
                    Sub (Matrix m n α)
                    Equations
                    • Matrix.sub = Pi.instSub
                    instance Matrix.addGroup {m : Type u_2} {n : Type u_3} {α : Type v} [AddGroup α] :
                    AddGroup (Matrix m n α)
                    Equations
                    • Matrix.addGroup = Pi.addGroup
                    instance Matrix.addCommGroup {m : Type u_2} {n : Type u_3} {α : Type v} [AddCommGroup α] :
                    Equations
                    • Matrix.addCommGroup = Pi.addCommGroup
                    instance Matrix.unique {m : Type u_2} {n : Type u_3} {α : Type v} [Unique α] :
                    Unique (Matrix m n α)
                    Equations
                    • Matrix.unique = Pi.unique
                    instance Matrix.nonempty {m : Type u_2} {n : Type u_3} {α : Type v} [Nonempty m] [Nonempty n] [Nontrivial α] :
                    Equations
                    instance Matrix.smul {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} [SMul R α] :
                    SMul R (Matrix m n α)
                    Equations
                    • Matrix.smul = Pi.instSMul
                    instance Matrix.smulCommClass {m : Type u_2} {n : Type u_3} {R : Type u_7} {S : Type u_8} {α : Type v} [SMul R α] [SMul S α] [SMulCommClass R S α] :
                    SMulCommClass R S (Matrix m n α)
                    Equations
                    instance Matrix.isScalarTower {m : Type u_2} {n : Type u_3} {R : Type u_7} {S : Type u_8} {α : Type v} [SMul R S] [SMul R α] [SMul S α] [IsScalarTower R S α] :
                    IsScalarTower R S (Matrix m n α)
                    Equations
                    instance Matrix.mulAction {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} [Monoid R] [MulAction R α] :
                    MulAction R (Matrix m n α)
                    Equations
                    instance Matrix.distribMulAction {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} [Monoid R] [AddMonoid α] [DistribMulAction R α] :
                    Equations
                    instance Matrix.module {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} [Semiring R] [AddCommMonoid α] [Module R α] :
                    Module R (Matrix m n α)
                    Equations
                    @[simp]
                    theorem Matrix.zero_apply {m : Type u_2} {n : Type u_3} {α : Type v} [Zero α] (i : m) (j : n) :
                    OfNat.ofNat (Matrix m n α) 0 Zero.toOfNat0 i j = 0
                    @[simp]
                    theorem Matrix.add_apply {m : Type u_2} {n : Type u_3} {α : Type v} [Add α] (A : Matrix m n α) (B : Matrix m n α) (i : m) (j : n) :
                    (Matrix m n α + Matrix m n α) (Matrix m n α) instHAdd A B i j = A i j + B i j
                    @[simp]
                    theorem Matrix.smul_apply {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} [SMul β α] (r : β) (A : Matrix m n α) (i : m) (j : n) :
                    (β Matrix m n α) (Matrix m n α) instHSMul r A i j = r A i j
                    @[simp]
                    theorem Matrix.sub_apply {m : Type u_2} {n : Type u_3} {α : Type v} [Sub α] (A : Matrix m n α) (B : Matrix m n α) (i : m) (j : n) :
                    (Matrix m n α - Matrix m n α) (Matrix m n α) instHSub A B i j = A i j - B i j
                    @[simp]
                    theorem Matrix.neg_apply {m : Type u_2} {n : Type u_3} {α : Type v} [Neg α] (A : Matrix m n α) (i : m) (j : n) :
                    (-Matrix m n α) Matrix.neg A i j = -A i j

                    simp-normal form pulls of to the outside.

                    @[simp]
                    theorem Matrix.of_zero {m : Type u_2} {n : Type u_3} {α : Type v} [Zero α] :
                    Matrix.of 0 = 0
                    @[simp]
                    theorem Matrix.of_add_of {m : Type u_2} {n : Type u_3} {α : Type v} [Add α] (f : mnα) (g : mnα) :
                    Matrix.of f + Matrix.of g = Matrix.of (f + g)
                    @[simp]
                    theorem Matrix.of_sub_of {m : Type u_2} {n : Type u_3} {α : Type v} [Sub α] (f : mnα) (g : mnα) :
                    Matrix.of f - Matrix.of g = Matrix.of (f - g)
                    @[simp]
                    theorem Matrix.neg_of {m : Type u_2} {n : Type u_3} {α : Type v} [Neg α] (f : mnα) :
                    -Matrix.of f = Matrix.of (-f)
                    @[simp]
                    theorem Matrix.smul_of {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} [SMul R α] (r : R) (f : mnα) :
                    r Matrix.of f = Matrix.of (r f)
                    @[simp]
                    theorem Matrix.map_zero {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} [Zero α] [Zero β] (f : αβ) (h : f 0 = 0) :
                    theorem Matrix.map_add {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} [Add α] [Add β] (f : αβ) (hf : ∀ (a₁ a₂ : α), f (a₁ + a₂) = f a₁ + f a₂) (M : Matrix m n α) (N : Matrix m n α) :
                    theorem Matrix.map_sub {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} [Sub α] [Sub β] (f : αβ) (hf : ∀ (a₁ a₂ : α), f (a₁ - a₂) = f a₁ - f a₂) (M : Matrix m n α) (N : Matrix m n α) :
                    theorem Matrix.map_smul {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} {β : Type w} [SMul R α] [SMul R β] (f : αβ) (r : R) (hf : ∀ (a : α), f (r a) = r f a) (M : Matrix m n α) :
                    Matrix.map (r M) f = r Matrix.map M f
                    theorem Matrix.map_smul' {n : Type u_3} {α : Type v} {β : Type w} [Mul α] [Mul β] (f : αβ) (r : α) (A : Matrix n n α) (hf : ∀ (a₁ a₂ : α), f (a₁ * a₂) = f a₁ * f a₂) :
                    Matrix.map (r A) f = f r Matrix.map A f

                    The scalar action via Mul.toSMul is transformed by the same map as the elements of the matrix, when f preserves multiplication.

                    theorem Matrix.map_op_smul' {n : Type u_3} {α : Type v} {β : Type w} [Mul α] [Mul β] (f : αβ) (r : α) (A : Matrix n n α) (hf : ∀ (a₁ a₂ : α), f (a₁ * a₂) = f a₁ * f a₂) :

                    The scalar action via mul.toOppositeSMul is transformed by the same map as the elements of the matrix, when f preserves multiplication.

                    theorem IsSMulRegular.matrix {m : Type u_2} {n : Type u_3} {R : Type u_7} {S : Type u_8} [SMul R S] {k : R} (hk : IsSMulRegular S k) :
                    theorem IsLeftRegular.matrix {m : Type u_2} {n : Type u_3} {α : Type v} [Mul α] {k : α} (hk : IsLeftRegular k) :
                    def Matrix.diagonal {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] (d : nα) :
                    Matrix n n α

                    diagonal d is the square matrix such that (diagonal d) i i = d i and (diagonal d) i j = 0 if i ≠ j.

                    Note that bundled versions exist as:

                    Equations
                    Instances For
                      theorem Matrix.diagonal_apply {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] (d : nα) (i : n) (j : n) :
                      Matrix.diagonal d i j = if i = j then d i else 0
                      @[simp]
                      theorem Matrix.diagonal_apply_eq {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] (d : nα) (i : n) :
                      Matrix.diagonal d i i = d i
                      @[simp]
                      theorem Matrix.diagonal_apply_ne {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] (d : nα) {i : n} {j : n} (h : i j) :
                      theorem Matrix.diagonal_apply_ne' {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] (d : nα) {i : n} {j : n} (h : j i) :
                      @[simp]
                      theorem Matrix.diagonal_eq_diagonal_iff {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] {d₁ : nα} {d₂ : nα} :
                      Matrix.diagonal d₁ = Matrix.diagonal d₂ ∀ (i : n), d₁ i = d₂ i
                      theorem Matrix.diagonal_injective {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] :
                      Function.Injective Matrix.diagonal
                      @[simp]
                      theorem Matrix.diagonal_zero {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] :
                      (Matrix.diagonal fun x => 0) = 0
                      @[simp]
                      theorem Matrix.diagonal_transpose {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] (v : nα) :
                      @[simp]
                      theorem Matrix.diagonal_add {n : Type u_3} {α : Type v} [DecidableEq n] [AddZeroClass α] (d₁ : nα) (d₂ : nα) :
                      Matrix.diagonal d₁ + Matrix.diagonal d₂ = Matrix.diagonal fun i => d₁ i + d₂ i
                      @[simp]
                      theorem Matrix.diagonal_smul {n : Type u_3} {R : Type u_7} {α : Type v} [DecidableEq n] [Monoid R] [AddMonoid α] [DistribMulAction R α] (r : R) (d : nα) :
                      @[simp]
                      theorem Matrix.diagonalAddMonoidHom_apply (n : Type u_3) (α : Type v) [DecidableEq n] [AddZeroClass α] (d : nα) :
                      def Matrix.diagonalAddMonoidHom (n : Type u_3) (α : Type v) [DecidableEq n] [AddZeroClass α] :
                      (nα) →+ Matrix n n α

                      Matrix.diagonal as an AddMonoidHom.

                      Equations
                      • One or more equations did not get rendered due to their size.
                      Instances For
                        @[simp]
                        theorem Matrix.diagonalLinearMap_apply (n : Type u_3) (R : Type u_7) (α : Type v) [DecidableEq n] [Semiring R] [AddCommMonoid α] [Module R α] :
                        ∀ (a : nα), ↑(Matrix.diagonalLinearMap n R α) a = ZeroHom.toFun (↑(Matrix.diagonalAddMonoidHom n α)) a
                        def Matrix.diagonalLinearMap (n : Type u_3) (R : Type u_7) (α : Type v) [DecidableEq n] [Semiring R] [AddCommMonoid α] [Module R α] :
                        (nα) →ₗ[R] Matrix n n α

                        Matrix.diagonal as a LinearMap.

                        Equations
                        • One or more equations did not get rendered due to their size.
                        Instances For
                          @[simp]
                          theorem Matrix.diagonal_map {n : Type u_3} {α : Type v} {β : Type w} [DecidableEq n] [Zero α] [Zero β] {f : αβ} (h : f 0 = 0) {d : nα} :
                          instance Matrix.one {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] [One α] :
                          One (Matrix n n α)
                          Equations
                          @[simp]
                          theorem Matrix.diagonal_one {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] [One α] :
                          (Matrix.diagonal fun x => 1) = 1
                          theorem Matrix.one_apply {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] [One α] {i : n} {j : n} :
                          OfNat.ofNat (Matrix n n α) 1 One.toOfNat1 i j = if i = j then 1 else 0
                          @[simp]
                          theorem Matrix.one_apply_eq {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] [One α] (i : n) :
                          OfNat.ofNat (Matrix n n α) 1 One.toOfNat1 i i = 1
                          @[simp]
                          theorem Matrix.one_apply_ne {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] [One α] {i : n} {j : n} :
                          i jOfNat.ofNat (Matrix n n α) 1 One.toOfNat1 i j = 0
                          theorem Matrix.one_apply_ne' {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] [One α] {i : n} {j : n} :
                          j iOfNat.ofNat (Matrix n n α) 1 One.toOfNat1 i j = 0
                          @[simp]
                          theorem Matrix.map_one {n : Type u_3} {α : Type v} {β : Type w} [DecidableEq n] [Zero α] [One α] [Zero β] [One β] (f : αβ) (h₀ : f 0 = 0) (h₁ : f 1 = 1) :
                          theorem Matrix.one_eq_pi_single {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] [One α] {i : n} {j : n} :
                          OfNat.ofNat (Matrix n n α) 1 One.toOfNat1 i j = Pi.single i 1 j
                          @[simp, deprecated]
                          theorem Matrix.bit0_apply {m : Type u_2} {α : Type v} [Add α] (M : Matrix m m α) (i : m) (j : m) :
                          bit0 (Matrix m m α) Matrix.add M i j = bit0 (M i j)
                          @[deprecated]
                          theorem Matrix.bit1_apply {n : Type u_3} {α : Type v} [DecidableEq n] [AddZeroClass α] [One α] (M : Matrix n n α) (i : n) (j : n) :
                          bit1 (Matrix n n α) Matrix.one Matrix.add M i j = if i = j then bit1 (M i j) else bit0 (M i j)
                          @[simp, deprecated]
                          theorem Matrix.bit1_apply_eq {n : Type u_3} {α : Type v} [DecidableEq n] [AddZeroClass α] [One α] (M : Matrix n n α) (i : n) :
                          bit1 (Matrix n n α) Matrix.one Matrix.add M i i = bit1 (M i i)
                          @[simp, deprecated]
                          theorem Matrix.bit1_apply_ne {n : Type u_3} {α : Type v} [DecidableEq n] [AddZeroClass α] [One α] (M : Matrix n n α) {i : n} {j : n} (h : i j) :
                          bit1 (Matrix n n α) Matrix.one Matrix.add M i j = bit0 (M i j)
                          def Matrix.diag {n : Type u_3} {α : Type v} (A : Matrix n n α) (i : n) :
                          α

                          The diagonal of a square matrix.

                          Equations
                          Instances For
                            @[simp]
                            theorem Matrix.diag_apply {n : Type u_3} {α : Type v} (A : Matrix n n α) (i : n) :
                            Matrix.diag A i = A i i
                            @[simp]
                            theorem Matrix.diag_diagonal {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] (a : nα) :
                            @[simp]
                            theorem Matrix.diag_transpose {n : Type u_3} {α : Type v} (A : Matrix n n α) :
                            @[simp]
                            theorem Matrix.diag_zero {n : Type u_3} {α : Type v} [Zero α] :
                            @[simp]
                            theorem Matrix.diag_add {n : Type u_3} {α : Type v} [Add α] (A : Matrix n n α) (B : Matrix n n α) :
                            @[simp]
                            theorem Matrix.diag_sub {n : Type u_3} {α : Type v} [Sub α] (A : Matrix n n α) (B : Matrix n n α) :
                            @[simp]
                            theorem Matrix.diag_neg {n : Type u_3} {α : Type v} [Neg α] (A : Matrix n n α) :
                            @[simp]
                            theorem Matrix.diag_smul {n : Type u_3} {R : Type u_7} {α : Type v} [SMul R α] (r : R) (A : Matrix n n α) :
                            @[simp]
                            theorem Matrix.diag_one {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] [One α] :
                            @[simp]
                            theorem Matrix.diagAddMonoidHom_apply (n : Type u_3) (α : Type v) [AddZeroClass α] (A : Matrix n n α) (i : n) :
                            def Matrix.diagAddMonoidHom (n : Type u_3) (α : Type v) [AddZeroClass α] :
                            Matrix n n α →+ nα

                            Matrix.diag as an AddMonoidHom.

                            Equations
                            • One or more equations did not get rendered due to their size.
                            Instances For
                              @[simp]
                              theorem Matrix.diagLinearMap_apply (n : Type u_3) (R : Type u_7) (α : Type v) [Semiring R] [AddCommMonoid α] [Module R α] :
                              ∀ (a : Matrix n n α) (a_1 : n), ↑(Matrix.diagLinearMap n R α) a a_1 = ZeroHom.toFun (Matrix n n α) (nα) AddZeroClass.toZero AddZeroClass.toZero (↑(Matrix.diagAddMonoidHom n α)) a a_1
                              def Matrix.diagLinearMap (n : Type u_3) (R : Type u_7) (α : Type v) [Semiring R] [AddCommMonoid α] [Module R α] :
                              Matrix n n α →ₗ[R] nα

                              Matrix.diag as a LinearMap.

                              Equations
                              • One or more equations did not get rendered due to their size.
                              Instances For
                                theorem Matrix.diag_map {n : Type u_3} {α : Type v} {β : Type w} {f : αβ} {A : Matrix n n α} :
                                @[simp]
                                @[simp]
                                theorem Matrix.diag_list_sum {n : Type u_3} {α : Type v} [AddMonoid α] (l : List (Matrix n n α)) :
                                Matrix.diag (List.sum l) = List.sum (List.map Matrix.diag l)
                                @[simp]
                                theorem Matrix.diag_multiset_sum {n : Type u_3} {α : Type v} [AddCommMonoid α] (s : Multiset (Matrix n n α)) :
                                @[simp]
                                theorem Matrix.diag_sum {n : Type u_3} {α : Type v} {ι : Type u_10} [AddCommMonoid α] (s : Finset ι) (f : ιMatrix n n α) :
                                Matrix.diag (Finset.sum s fun i => f i) = Finset.sum s fun i => Matrix.diag (f i)
                                def Matrix.dotProduct {m : Type u_2} {α : Type v} [Fintype m] [Mul α] [AddCommMonoid α] (v : mα) (w : mα) :
                                α

                                dotProduct v w is the sum of the entrywise products v i * w i

                                Equations
                                Instances For

                                  dotProduct v w is the sum of the entrywise products v i * w i

                                  Equations
                                  Instances For
                                    theorem Matrix.dotProduct_assoc {m : Type u_2} {n : Type u_3} {α : Type v} [Fintype m] [Fintype n] [NonUnitalSemiring α] (u : mα) (w : nα) (v : Matrix m n α) :
                                    Matrix.dotProduct (fun j => Matrix.dotProduct u fun i => v i j) w = Matrix.dotProduct u fun i => Matrix.dotProduct (v i) w
                                    theorem Matrix.dotProduct_comm {m : Type u_2} {α : Type v} [Fintype m] [AddCommMonoid α] [CommSemigroup α] (v : mα) (w : mα) :
                                    @[simp]
                                    theorem Matrix.dotProduct_one {n : Type u_3} {α : Type v} [Fintype n] [MulOneClass α] [AddCommMonoid α] (v : nα) :
                                    Matrix.dotProduct v 1 = Finset.sum Finset.univ fun i => v i
                                    theorem Matrix.one_dotProduct {n : Type u_3} {α : Type v} [Fintype n] [MulOneClass α] [AddCommMonoid α] (v : nα) :
                                    Matrix.dotProduct 1 v = Finset.sum Finset.univ fun i => v i
                                    @[simp]
                                    theorem Matrix.dotProduct_zero {m : Type u_2} {α : Type v} [Fintype m] [NonUnitalNonAssocSemiring α] (v : mα) :
                                    @[simp]
                                    theorem Matrix.dotProduct_zero' {m : Type u_2} {α : Type v} [Fintype m] [NonUnitalNonAssocSemiring α] (v : mα) :
                                    (Matrix.dotProduct v fun x => 0) = 0
                                    @[simp]
                                    theorem Matrix.zero_dotProduct {m : Type u_2} {α : Type v} [Fintype m] [NonUnitalNonAssocSemiring α] (v : mα) :
                                    @[simp]
                                    theorem Matrix.zero_dotProduct' {m : Type u_2} {α : Type v} [Fintype m] [NonUnitalNonAssocSemiring α] (v : mα) :
                                    Matrix.dotProduct (fun x => 0) v = 0
                                    @[simp]
                                    theorem Matrix.add_dotProduct {m : Type u_2} {α : Type v} [Fintype m] [NonUnitalNonAssocSemiring α] (u : mα) (v : mα) (w : mα) :
                                    @[simp]
                                    theorem Matrix.dotProduct_add {m : Type u_2} {α : Type v} [Fintype m] [NonUnitalNonAssocSemiring α] (u : mα) (v : mα) (w : mα) :
                                    @[simp]
                                    theorem Matrix.sum_elim_dotProduct_sum_elim {m : Type u_2} {n : Type u_3} {α : Type v} [Fintype m] [Fintype n] [NonUnitalNonAssocSemiring α] (u : mα) (v : mα) (x : nα) (y : nα) :
                                    @[simp]
                                    theorem Matrix.comp_equiv_symm_dotProduct {m : Type u_2} {n : Type u_3} {α : Type v} [Fintype m] [Fintype n] [NonUnitalNonAssocSemiring α] (u : mα) (x : nα) (e : m n) :
                                    Matrix.dotProduct (u e.symm) x = Matrix.dotProduct u (x e)

                                    Permuting a vector on the left of a dot product can be transferred to the right.

                                    @[simp]
                                    theorem Matrix.dotProduct_comp_equiv_symm {m : Type u_2} {n : Type u_3} {α : Type v} [Fintype m] [Fintype n] [NonUnitalNonAssocSemiring α] (u : mα) (x : nα) (e : n m) :
                                    Matrix.dotProduct u (x e.symm) = Matrix.dotProduct (u e) x

                                    Permuting a vector on the right of a dot product can be transferred to the left.

                                    @[simp]
                                    theorem Matrix.comp_equiv_dotProduct_comp_equiv {m : Type u_2} {n : Type u_3} {α : Type v} [Fintype m] [Fintype n] [NonUnitalNonAssocSemiring α] (x : nα) (y : nα) (e : m n) :

                                    Permuting vectors on both sides of a dot product is a no-op.

                                    @[simp]
                                    theorem Matrix.diagonal_dotProduct {m : Type u_2} {α : Type v} [Fintype m] [DecidableEq m] [NonUnitalNonAssocSemiring α] (v : mα) (w : mα) (i : m) :
                                    @[simp]
                                    theorem Matrix.dotProduct_diagonal {m : Type u_2} {α : Type v} [Fintype m] [DecidableEq m] [NonUnitalNonAssocSemiring α] (v : mα) (w : mα) (i : m) :
                                    @[simp]
                                    theorem Matrix.dotProduct_diagonal' {m : Type u_2} {α : Type v} [Fintype m] [DecidableEq m] [NonUnitalNonAssocSemiring α] (v : mα) (w : mα) (i : m) :
                                    (Matrix.dotProduct v fun j => Matrix.diagonal w j i) = v i * w i
                                    @[simp]
                                    theorem Matrix.single_dotProduct {m : Type u_2} {α : Type v} [Fintype m] [DecidableEq m] [NonUnitalNonAssocSemiring α] (v : mα) (x : α) (i : m) :
                                    @[simp]
                                    theorem Matrix.dotProduct_single {m : Type u_2} {α : Type v} [Fintype m] [DecidableEq m] [NonUnitalNonAssocSemiring α] (v : mα) (x : α) (i : m) :
                                    @[simp]
                                    @[simp]
                                    theorem Matrix.neg_dotProduct {m : Type u_2} {α : Type v} [Fintype m] [NonUnitalNonAssocRing α] (v : mα) (w : mα) :
                                    @[simp]
                                    theorem Matrix.dotProduct_neg {m : Type u_2} {α : Type v} [Fintype m] [NonUnitalNonAssocRing α] (v : mα) (w : mα) :
                                    @[simp]
                                    theorem Matrix.sub_dotProduct {m : Type u_2} {α : Type v} [Fintype m] [NonUnitalNonAssocRing α] (u : mα) (v : mα) (w : mα) :
                                    @[simp]
                                    theorem Matrix.dotProduct_sub {m : Type u_2} {α : Type v} [Fintype m] [NonUnitalNonAssocRing α] (u : mα) (v : mα) (w : mα) :
                                    @[simp]
                                    theorem Matrix.smul_dotProduct {m : Type u_2} {R : Type u_7} {α : Type v} [Fintype m] [Monoid R] [Mul α] [AddCommMonoid α] [DistribMulAction R α] [IsScalarTower R α α] (x : R) (v : mα) (w : mα) :
                                    @[simp]
                                    theorem Matrix.dotProduct_smul {m : Type u_2} {R : Type u_7} {α : Type v} [Fintype m] [Monoid R] [Mul α] [AddCommMonoid α] [DistribMulAction R α] [SMulCommClass R α α] (x : R) (v : mα) (w : mα) :
                                    theorem Matrix.star_dotProduct_star {m : Type u_2} {α : Type v} [Fintype m] [NonUnitalSemiring α] [StarRing α] (v : mα) (w : mα) :
                                    theorem Matrix.star_dotProduct {m : Type u_2} {α : Type v} [Fintype m] [NonUnitalSemiring α] [StarRing α] (v : mα) (w : mα) :
                                    theorem Matrix.dotProduct_star {m : Type u_2} {α : Type v} [Fintype m] [NonUnitalSemiring α] [StarRing α] (v : mα) (w : mα) :
                                    @[defaultInstance 100]
                                    instance Matrix.instHMulMatrixMatrixMatrix {l : Type u_1} {m : Type u_2} {n : Type u_3} {α : Type v} [Fintype m] [Mul α] [AddCommMonoid α] :
                                    HMul (Matrix l m α) (Matrix m n α) (Matrix l n α)

                                    M * N is the usual product of matrices M and N, i.e. we have that (M * N) i k is the dot product of the i-th row of M by the k-th column of N. This is currently only defined when m is finite.

                                    Equations
                                    • Matrix.instHMulMatrixMatrixMatrix = { hMul := fun M N i k => Matrix.dotProduct (fun j => M i j) fun j => N j k }
                                    theorem Matrix.mul_apply {l : Type u_1} {m : Type u_2} {n : Type u_3} {α : Type v} [Fintype m] [Mul α] [AddCommMonoid α] {M : Matrix l m α} {N : Matrix m n α} {i : l} {k : n} :
                                    (Matrix l m α * Matrix m n α) (Matrix l n α) Matrix.instHMulMatrixMatrixMatrix M N i k = Finset.sum Finset.univ fun j => M i j * N j k
                                    instance Matrix.instMulMatrix {n : Type u_3} {α : Type v} [Fintype n] [Mul α] [AddCommMonoid α] :
                                    Mul (Matrix n n α)
                                    Equations
                                    • Matrix.instMulMatrix = { mul := fun M N => M * N }
                                    theorem Matrix.mul_apply' {l : Type u_1} {m : Type u_2} {n : Type u_3} {α : Type v} [Fintype m] [Mul α] [AddCommMonoid α] {M : Matrix l m α} {N : Matrix m n α} {i : l} {k : n} :
                                    (Matrix l m α * Matrix m n α) (Matrix l n α) Matrix.instHMulMatrixMatrixMatrix M N i k = Matrix.dotProduct (fun j => M i j) fun j => N j k
                                    @[simp]
                                    theorem Matrix.diagonal_neg {n : Type u_3} {α : Type v} [DecidableEq n] [AddGroup α] (d : nα) :
                                    theorem Matrix.sum_apply {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} [AddCommMonoid α] (i : m) (j : n) (s : Finset β) (g : βMatrix m n α) :
                                    Finset.sum (Matrix m n α) β Matrix.addCommMonoid s (fun c => g c) i j = Finset.sum s fun c => g c i j
                                    theorem Matrix.two_mul_expl {R : Type u_10} [CommRing R] (A : Matrix (Fin 2) (Fin 2) R) (B : Matrix (Fin 2) (Fin 2) R) :
                                    (Matrix (Fin 2) (Fin 2) R * Matrix (Fin 2) (Fin 2) R) (Matrix (Fin 2) (Fin 2) R) Matrix.instHMulMatrixMatrixMatrix A B 0 0 = A 0 0 * B 0 0 + A 0 1 * B 1 0 (Matrix (Fin 2) (Fin 2) R * Matrix (Fin 2) (Fin 2) R) (Matrix (Fin 2) (Fin 2) R) Matrix.instHMulMatrixMatrixMatrix A B 0 1 = A 0 0 * B 0 1 + A 0 1 * B 1 1 (Matrix (Fin 2) (Fin 2) R * Matrix (Fin 2) (Fin 2) R) (Matrix (Fin 2) (Fin 2) R) Matrix.instHMulMatrixMatrixMatrix A B 1 0 = A 1 0 * B 0 0 + A 1 1 * B 1 0 (Matrix (Fin 2) (Fin 2) R * Matrix (Fin 2) (Fin 2) R) (Matrix (Fin 2) (Fin 2) R) Matrix.instHMulMatrixMatrixMatrix A B 1 1 = A 1 0 * B 0 1 + A 1 1 * B 1 1
                                    @[simp]
                                    theorem Matrix.smul_mul {l : Type u_1} {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} [AddCommMonoid α] [Mul α] [Fintype n] [Monoid R] [DistribMulAction R α] [IsScalarTower R α α] (a : R) (M : Matrix m n α) (N : Matrix n l α) :
                                    a M * N = a (M * N)
                                    @[simp]
                                    theorem Matrix.mul_smul {l : Type u_1} {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} [AddCommMonoid α] [Mul α] [Fintype n] [Monoid R] [DistribMulAction R α] [SMulCommClass R α α] (M : Matrix m n α) (a : R) (N : Matrix n l α) :
                                    M * a N = a (M * N)
                                    @[simp]
                                    theorem Matrix.mul_zero {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype n] (M : Matrix m n α) :
                                    M * 0 = 0
                                    @[simp]
                                    theorem Matrix.zero_mul {l : Type u_1} {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype m] (M : Matrix m n α) :
                                    0 * M = 0
                                    theorem Matrix.mul_add {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype n] (L : Matrix m n α) (M : Matrix n o α) (N : Matrix n o α) :
                                    L * (M + N) = L * M + L * N
                                    theorem Matrix.add_mul {l : Type u_1} {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype m] (L : Matrix l m α) (M : Matrix l m α) (N : Matrix m n α) :
                                    (L + M) * N = L * N + M * N
                                    Equations
                                    • One or more equations did not get rendered due to their size.
                                    @[simp]
                                    theorem Matrix.diagonal_mul {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype m] [DecidableEq m] (d : mα) (M : Matrix m n α) (i : m) (j : n) :
                                    (Matrix m m α * Matrix m n α) (Matrix m n α) Matrix.instHMulMatrixMatrixMatrix (Matrix.diagonal d) M i j = d i * M i j
                                    @[simp]
                                    theorem Matrix.mul_diagonal {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype n] [DecidableEq n] (d : nα) (M : Matrix m n α) (i : m) (j : n) :
                                    (Matrix m n α * Matrix n n α) (Matrix m n α) Matrix.instHMulMatrixMatrixMatrix M (Matrix.diagonal d) i j = M i j * d j
                                    @[simp]
                                    theorem Matrix.diagonal_mul_diagonal {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype n] [DecidableEq n] (d₁ : nα) (d₂ : nα) :
                                    Matrix.diagonal d₁ * Matrix.diagonal d₂ = Matrix.diagonal fun i => d₁ i * d₂ i
                                    theorem Matrix.diagonal_mul_diagonal' {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype n] [DecidableEq n] (d₁ : nα) (d₂ : nα) :
                                    Matrix.diagonal d₁ * Matrix.diagonal d₂ = Matrix.diagonal fun i => d₁ i * d₂ i
                                    theorem Matrix.smul_eq_diagonal_mul {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype m] [DecidableEq m] (M : Matrix m n α) (a : α) :
                                    a M = (Matrix.diagonal fun x => a) * M
                                    @[simp]
                                    theorem Matrix.diag_col_mul_row {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] (a : nα) (b : nα) :
                                    @[simp]
                                    theorem Matrix.addMonoidHomMulLeft_apply {l : Type u_1} {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype m] (M : Matrix l m α) (x : Matrix m n α) :
                                    def Matrix.addMonoidHomMulLeft {l : Type u_1} {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype m] (M : Matrix l m α) :
                                    Matrix m n α →+ Matrix l n α

                                    Left multiplication by a matrix, as an AddMonoidHom from matrices to matrices.

                                    Equations
                                    Instances For
                                      @[simp]
                                      theorem Matrix.addMonoidHomMulRight_apply {l : Type u_1} {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype m] (M : Matrix m n α) (x : Matrix l m α) :
                                      def Matrix.addMonoidHomMulRight {l : Type u_1} {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype m] (M : Matrix m n α) :
                                      Matrix l m α →+ Matrix l n α

                                      Right multiplication by a matrix, as an AddMonoidHom from matrices to matrices.

                                      Equations
                                      Instances For
                                        theorem Matrix.sum_mul {l : Type u_1} {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} [NonUnitalNonAssocSemiring α] [Fintype m] (s : Finset β) (f : βMatrix l m α) (M : Matrix m n α) :
                                        (Finset.sum s fun a => f a) * M = Finset.sum s fun a => f a * M
                                        theorem Matrix.mul_sum {l : Type u_1} {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} [NonUnitalNonAssocSemiring α] [Fintype m] (s : Finset β) (f : βMatrix m n α) (M : Matrix l m α) :
                                        (M * Finset.sum s fun a => f a) = Finset.sum s fun a => M * f a
                                        @[simp]
                                        theorem Matrix.one_mul {m : Type u_2} {n : Type u_3} {α : Type v} [NonAssocSemiring α] [Fintype m] [DecidableEq m] (M : Matrix m n α) :
                                        1 * M = M
                                        @[simp]
                                        theorem Matrix.mul_one {m : Type u_2} {n : Type u_3} {α : Type v} [NonAssocSemiring α] [Fintype n] [DecidableEq n] (M : Matrix m n α) :
                                        M * 1 = M
                                        instance Matrix.nonAssocSemiring {n : Type u_3} {α : Type v} [NonAssocSemiring α] [Fintype n] [DecidableEq n] :
                                        Equations
                                        @[simp]
                                        theorem Matrix.map_mul {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} {β : Type w} [NonAssocSemiring α] [Fintype n] {L : Matrix m n α} {M : Matrix n o α} [NonAssocSemiring β] {f : α →+* β} :
                                        Matrix.map (L * M) f = Matrix.map L f * Matrix.map M f
                                        @[simp]
                                        theorem Matrix.diagonalRingHom_apply (n : Type u_3) (α : Type v) [NonAssocSemiring α] [Fintype n] [DecidableEq n] (d : nα) :
                                        def Matrix.diagonalRingHom (n : Type u_3) (α : Type v) [NonAssocSemiring α] [Fintype n] [DecidableEq n] :
                                        (nα) →+* Matrix n n α

                                        Matrix.diagonal as a RingHom.

                                        Equations
                                        • One or more equations did not get rendered due to their size.
                                        Instances For
                                          theorem Matrix.mul_assoc {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [NonUnitalSemiring α] [Fintype m] [Fintype n] (L : Matrix l m α) (M : Matrix m n α) (N : Matrix n o α) :
                                          L * M * N = L * (M * N)
                                          instance Matrix.nonUnitalSemiring {n : Type u_3} {α : Type v} [NonUnitalSemiring α] [Fintype n] :
                                          Equations
                                          instance Matrix.semiring {n : Type u_3} {α : Type v} [Semiring α] [Fintype n] [DecidableEq n] :
                                          Semiring (Matrix n n α)
                                          Equations
                                          • Matrix.semiring = let src := Matrix.nonUnitalSemiring; let src_1 := Matrix.nonAssocSemiring; Semiring.mk (_ : ∀ (a : Matrix n n α), 1 * a = a) (_ : ∀ (a : Matrix n n α), a * 1 = a) npowRec
                                          @[simp]
                                          theorem Matrix.neg_mul {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [NonUnitalNonAssocRing α] [Fintype n] (M : Matrix m n α) (N : Matrix n o α) :
                                          -M * N = -(M * N)
                                          @[simp]
                                          theorem Matrix.mul_neg {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [NonUnitalNonAssocRing α] [Fintype n] (M : Matrix m n α) (N : Matrix n o α) :
                                          M * -N = -(M * N)
                                          theorem Matrix.sub_mul {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [NonUnitalNonAssocRing α] [Fintype n] (M : Matrix m n α) (M' : Matrix m n α) (N : Matrix n o α) :
                                          (M - M') * N = M * N - M' * N
                                          theorem Matrix.mul_sub {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [NonUnitalNonAssocRing α] [Fintype n] (M : Matrix m n α) (N : Matrix n o α) (N' : Matrix n o α) :
                                          M * (N - N') = M * N - M * N'
                                          Equations
                                          • One or more equations did not get rendered due to their size.
                                          instance Matrix.instNonUnitalRing {n : Type u_3} {α : Type v} [Fintype n] [NonUnitalRing α] :
                                          Equations
                                          • Matrix.instNonUnitalRing = let src := Matrix.nonUnitalSemiring; let src_1 := Matrix.addCommGroup; NonUnitalRing.mk (_ : ∀ (a b c : Matrix n n α), a * b * c = a * (b * c))
                                          instance Matrix.instNonAssocRing {n : Type u_3} {α : Type v} [Fintype n] [DecidableEq n] [NonAssocRing α] :
                                          Equations
                                          • Matrix.instNonAssocRing = let src := Matrix.nonAssocSemiring; let src_1 := Matrix.addCommGroup; NonAssocRing.mk (_ : ∀ (a : Matrix n n α), 1 * a = a) (_ : ∀ (a : Matrix n n α), a * 1 = a)
                                          instance Matrix.instRing {n : Type u_3} {α : Type v} [Fintype n] [DecidableEq n] [Ring α] :
                                          Ring (Matrix n n α)
                                          Equations
                                          • Matrix.instRing = let src := Matrix.semiring; let src_1 := Matrix.addCommGroup; Ring.mk SubNegMonoid.zsmul (_ : ∀ (a : Matrix n n α), -a + a = 0)
                                          theorem Matrix.diagonal_pow {n : Type u_3} {α : Type v} [Semiring α] [Fintype n] [DecidableEq n] (v : nα) (k : ) :
                                          @[simp]
                                          theorem Matrix.mul_mul_left {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [Semiring α] [Fintype n] (M : Matrix m n α) (N : Matrix n o α) (a : α) :
                                          (Matrix.of fun i j => a * M i j) * N = a (M * N)
                                          def Matrix.scalar {α : Type v} [Semiring α] (n : Type u) [DecidableEq n] [Fintype n] :
                                          α →+* Matrix n n α

                                          The ring homomorphism α →+* Matrix n n α sending a to the diagonal matrix with a on the diagonal.

                                          Equations
                                          • One or more equations did not get rendered due to their size.
                                          Instances For
                                            @[simp]
                                            theorem Matrix.coe_scalar {n : Type u_3} {α : Type v} [Semiring α] [DecidableEq n] [Fintype n] :
                                            ↑(Matrix.scalar n) = fun a => a 1
                                            theorem Matrix.scalar_apply_eq {n : Type u_3} {α : Type v} [Semiring α] [DecidableEq n] [Fintype n] (a : α) (i : n) :
                                            ↑(Matrix.scalar n) a i i = a
                                            theorem Matrix.scalar_apply_ne {n : Type u_3} {α : Type v} [Semiring α] [DecidableEq n] [Fintype n] (a : α) (i : n) (j : n) (h : i j) :
                                            ↑(Matrix.scalar n) a i j = 0
                                            theorem Matrix.scalar_inj {n : Type u_3} {α : Type v} [Semiring α] [DecidableEq n] [Fintype n] [Nonempty n] {r : α} {s : α} :
                                            ↑(Matrix.scalar n) r = ↑(Matrix.scalar n) s r = s
                                            theorem Matrix.smul_eq_mul_diagonal {m : Type u_2} {n : Type u_3} {α : Type v} [CommSemiring α] [Fintype n] [DecidableEq n] (M : Matrix m n α) (a : α) :
                                            a M = M * Matrix.diagonal fun x => a
                                            @[simp]
                                            theorem Matrix.mul_mul_right {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [CommSemiring α] [Fintype n] (M : Matrix m n α) (N : Matrix n o α) (a : α) :
                                            (M * Matrix.of fun i j => a * N i j) = a (M * N)
                                            theorem Matrix.scalar.commute {n : Type u_3} {α : Type v} [CommSemiring α] [Fintype n] [DecidableEq n] (r : α) (M : Matrix n n α) :
                                            Commute (↑(Matrix.scalar n) r) M
                                            instance Matrix.instAlgebra {n : Type u_3} {R : Type u_7} {α : Type v} [Fintype n] [DecidableEq n] [CommSemiring R] [Semiring α] [Algebra R α] :
                                            Algebra R (Matrix n n α)
                                            Equations
                                            • One or more equations did not get rendered due to their size.
                                            theorem Matrix.algebraMap_matrix_apply {n : Type u_3} {R : Type u_7} {α : Type v} [Fintype n] [DecidableEq n] [CommSemiring R] [Semiring α] [Algebra R α] {r : R} {i : n} {j : n} :
                                            ↑(algebraMap R (Matrix n n α)) r i j = if i = j then ↑(algebraMap R α) r else 0
                                            theorem Matrix.algebraMap_eq_diagonal {n : Type u_3} {R : Type u_7} {α : Type v} [Fintype n] [DecidableEq n] [CommSemiring R] [Semiring α] [Algebra R α] (r : R) :
                                            ↑(algebraMap R (Matrix n n α)) r = Matrix.diagonal (↑(algebraMap R (nα)) r)
                                            @[simp]
                                            theorem Matrix.algebraMap_eq_smul {n : Type u_3} {R : Type u_7} [Fintype n] [DecidableEq n] [CommSemiring R] (r : R) :
                                            ↑(algebraMap R (Matrix n n R)) r = r 1
                                            theorem Matrix.algebraMap_eq_diagonalRingHom {n : Type u_3} {R : Type u_7} {α : Type v} [Fintype n] [DecidableEq n] [CommSemiring R] [Semiring α] [Algebra R α] :
                                            @[simp]
                                            theorem Matrix.map_algebraMap {n : Type u_3} {R : Type u_7} {α : Type v} {β : Type w} [Fintype n] [DecidableEq n] [CommSemiring R] [Semiring α] [Semiring β] [Algebra R α] [Algebra R β] (r : R) (f : αβ) (hf : f 0 = 0) (hf₂ : f (↑(algebraMap R α) r) = ↑(algebraMap R β) r) :
                                            Matrix.map (↑(algebraMap R (Matrix n n α)) r) f = ↑(algebraMap R (Matrix n n β)) r
                                            @[simp]
                                            theorem Matrix.diagonalAlgHom_apply {n : Type u_3} (R : Type u_7) {α : Type v} [Fintype n] [DecidableEq n] [CommSemiring R] [Semiring α] [Algebra R α] (d : nα) :
                                            def Matrix.diagonalAlgHom {n : Type u_3} (R : Type u_7) {α : Type v} [Fintype n] [DecidableEq n] [CommSemiring R] [Semiring α] [Algebra R α] :
                                            (nα) →ₐ[R] Matrix n n α

                                            Matrix.diagonal as an AlgHom.

                                            Equations
                                            • One or more equations did not get rendered due to their size.
                                            Instances For

                                              Bundled versions of Matrix.map #

                                              @[simp]
                                              theorem Equiv.mapMatrix_apply {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} (f : α β) (M : Matrix m n α) :
                                              ↑(Equiv.mapMatrix f) M = Matrix.map M f
                                              def Equiv.mapMatrix {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} (f : α β) :
                                              Matrix m n α Matrix m n β

                                              The Equiv between spaces of matrices induced by an Equiv between their coefficients. This is Matrix.map as an Equiv.

                                              Equations
                                              • One or more equations did not get rendered due to their size.
                                              Instances For
                                                @[simp]
                                                theorem Equiv.mapMatrix_refl {m : Type u_2} {n : Type u_3} {α : Type v} :
                                                @[simp]
                                                theorem Equiv.mapMatrix_symm {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} (f : α β) :
                                                @[simp]
                                                theorem Equiv.mapMatrix_trans {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} {γ : Type u_9} (f : α β) (g : β γ) :
                                                @[simp]
                                                theorem AddMonoidHom.mapMatrix_apply {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} [AddZeroClass α] [AddZeroClass β] (f : α →+ β) (M : Matrix m n α) :
                                                def AddMonoidHom.mapMatrix {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} [AddZeroClass α] [AddZeroClass β] (f : α →+ β) :
                                                Matrix m n α →+ Matrix m n β

                                                The AddMonoidHom between spaces of matrices induced by an AddMonoidHom between their coefficients. This is Matrix.map as an AddMonoidHom.

                                                Equations
                                                • One or more equations did not get rendered due to their size.
                                                Instances For
                                                  @[simp]
                                                  @[simp]
                                                  theorem AddEquiv.mapMatrix_apply {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} [Add α] [Add β] (f : α ≃+ β) (M : Matrix m n α) :
                                                  def AddEquiv.mapMatrix {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} [Add α] [Add β] (f : α ≃+ β) :
                                                  Matrix m n α ≃+ Matrix m n β

                                                  The AddEquiv between spaces of matrices induced by an AddEquiv between their coefficients. This is Matrix.map as an AddEquiv.

                                                  Equations
                                                  • One or more equations did not get rendered due to their size.
                                                  Instances For
                                                    @[simp]
                                                    theorem AddEquiv.mapMatrix_refl {m : Type u_2} {n : Type u_3} {α : Type v} [Add α] :
                                                    @[simp]
                                                    theorem AddEquiv.mapMatrix_symm {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} [Add α] [Add β] (f : α ≃+ β) :
                                                    @[simp]
                                                    theorem AddEquiv.mapMatrix_trans {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} {γ : Type u_9} [Add α] [Add β] [Add γ] (f : α ≃+ β) (g : β ≃+ γ) :
                                                    @[simp]
                                                    theorem LinearMap.mapMatrix_apply {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} {β : Type w} [Semiring R] [AddCommMonoid α] [AddCommMonoid β] [Module R α] [Module R β] (f : α →ₗ[R] β) (M : Matrix m n α) :
                                                    def LinearMap.mapMatrix {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} {β : Type w} [Semiring R] [AddCommMonoid α] [AddCommMonoid β] [Module R α] [Module R β] (f : α →ₗ[R] β) :
                                                    Matrix m n α →ₗ[R] Matrix m n β

                                                    The LinearMap between spaces of matrices induced by a LinearMap between their coefficients. This is Matrix.map as a LinearMap.

                                                    Equations
                                                    • One or more equations did not get rendered due to their size.
                                                    Instances For
                                                      @[simp]
                                                      theorem LinearMap.mapMatrix_id {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} [Semiring R] [AddCommMonoid α] [Module R α] :
                                                      LinearMap.mapMatrix LinearMap.id = LinearMap.id
                                                      @[simp]
                                                      theorem LinearMap.mapMatrix_comp {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} {β : Type w} {γ : Type u_9} [Semiring R] [AddCommMonoid α] [AddCommMonoid β] [AddCommMonoid γ] [Module R α] [Module R β] [Module R γ] (f : β →ₗ[R] γ) (g : α →ₗ[R] β) :
                                                      @[simp]
                                                      theorem LinearEquiv.mapMatrix_apply {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} {β : Type w} [Semiring R] [AddCommMonoid α] [AddCommMonoid β] [Module R α] [Module R β] (f : α ≃ₗ[R] β) (M : Matrix m n α) :
                                                      def LinearEquiv.mapMatrix {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} {β : Type w} [Semiring R] [AddCommMonoid α] [AddCommMonoid β] [Module R α] [Module R β] (f : α ≃ₗ[R] β) :
                                                      Matrix m n α ≃ₗ[R] Matrix m n β

                                                      The LinearEquiv between spaces of matrices induced by a LinearEquiv between their coefficients. This is Matrix.map as a LinearEquiv.

                                                      Equations
                                                      • One or more equations did not get rendered due to their size.
                                                      Instances For
                                                        @[simp]
                                                        theorem LinearEquiv.mapMatrix_refl {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} [Semiring R] [AddCommMonoid α] [Module R α] :
                                                        @[simp]
                                                        theorem LinearEquiv.mapMatrix_symm {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} {β : Type w} [Semiring R] [AddCommMonoid α] [AddCommMonoid β] [Module R α] [Module R β] (f : α ≃ₗ[R] β) :
                                                        @[simp]
                                                        theorem LinearEquiv.mapMatrix_trans {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} {β : Type w} {γ : Type u_9} [Semiring R] [AddCommMonoid α] [AddCommMonoid β] [AddCommMonoid γ] [Module R α] [Module R β] [Module R γ] (f : α ≃ₗ[R] β) (g : β ≃ₗ[R] γ) :
                                                        @[simp]
                                                        theorem RingHom.mapMatrix_apply {m : Type u_2} {α : Type v} {β : Type w} [Fintype m] [DecidableEq m] [NonAssocSemiring α] [NonAssocSemiring β] (f : α →+* β) (M : Matrix m m α) :
                                                        def RingHom.mapMatrix {m : Type u_2} {α : Type v} {β : Type w} [Fintype m] [DecidableEq m] [NonAssocSemiring α] [NonAssocSemiring β] (f : α →+* β) :
                                                        Matrix m m α →+* Matrix m m β

                                                        The RingHom between spaces of square matrices induced by a RingHom between their coefficients. This is Matrix.map as a RingHom.

                                                        Equations
                                                        • One or more equations did not get rendered due to their size.
                                                        Instances For
                                                          @[simp]
                                                          @[simp]
                                                          theorem RingEquiv.mapMatrix_apply {m : Type u_2} {α : Type v} {β : Type w} [Fintype m] [DecidableEq m] [NonAssocSemiring α] [NonAssocSemiring β] (f : α ≃+* β) (M : Matrix m m α) :
                                                          def RingEquiv.mapMatrix {m : Type u_2} {α : Type v} {β : Type w} [Fintype m] [DecidableEq m] [NonAssocSemiring α] [NonAssocSemiring β] (f : α ≃+* β) :
                                                          Matrix m m α ≃+* Matrix m m β

                                                          The RingEquiv between spaces of square matrices induced by a RingEquiv between their coefficients. This is Matrix.map as a RingEquiv.

                                                          Equations
                                                          • One or more equations did not get rendered due to their size.
                                                          Instances For
                                                            @[simp]
                                                            theorem AlgHom.mapMatrix_apply {m : Type u_2} {R : Type u_7} {α : Type v} {β : Type w} [Fintype m] [DecidableEq m] [CommSemiring R] [Semiring α] [Semiring β] [Algebra R α] [Algebra R β] (f : α →ₐ[R] β) (M : Matrix m m α) :
                                                            ↑(AlgHom.mapMatrix f) M = Matrix.map M f
                                                            def AlgHom.mapMatrix {m : Type u_2} {R : Type u_7} {α : Type v} {β : Type w} [Fintype m] [DecidableEq m] [CommSemiring R] [Semiring α] [Semiring β] [Algebra R α] [Algebra R β] (f : α →ₐ[R] β) :
                                                            Matrix m m α →ₐ[R] Matrix m m β

                                                            The AlgHom between spaces of square matrices induced by an AlgHom between their coefficients. This is Matrix.map as an AlgHom.

                                                            Equations
                                                            • One or more equations did not get rendered due to their size.
                                                            Instances For
                                                              @[simp]
                                                              theorem AlgHom.mapMatrix_id {m : Type u_2} {R : Type u_7} {α : Type v} [Fintype m] [DecidableEq m] [CommSemiring R] [Semiring α] [Algebra R α] :
                                                              @[simp]
                                                              theorem AlgHom.mapMatrix_comp {m : Type u_2} {R : Type u_7} {α : Type v} {β : Type w} {γ : Type u_9} [Fintype m] [DecidableEq m] [CommSemiring R] [Semiring α] [Semiring β] [Semiring γ] [Algebra R α] [Algebra R β] [Algebra R γ] (f : β →ₐ[R] γ) (g : α →ₐ[R] β) :
                                                              @[simp]
                                                              theorem AlgEquiv.mapMatrix_apply {m : Type u_2} {R : Type u_7} {α : Type v} {β : Type w} [Fintype m] [DecidableEq m] [CommSemiring R] [Semiring α] [Semiring β] [Algebra R α] [Algebra R β] (f : α ≃ₐ[R] β) (M : Matrix m m α) :
                                                              def AlgEquiv.mapMatrix {m : Type u_2} {R : Type u_7} {α : Type v} {β : Type w} [Fintype m] [DecidableEq m] [CommSemiring R] [Semiring α] [Semiring β] [Algebra R α] [Algebra R β] (f : α ≃ₐ[R] β) :
                                                              Matrix m m α ≃ₐ[R] Matrix m m β

                                                              The AlgEquiv between spaces of square matrices induced by an AlgEquiv between their coefficients. This is Matrix.map as an AlgEquiv.

                                                              Equations
                                                              • One or more equations did not get rendered due to their size.
                                                              Instances For
                                                                @[simp]
                                                                theorem AlgEquiv.mapMatrix_refl {m : Type u_2} {R : Type u_7} {α : Type v} [Fintype m] [DecidableEq m] [CommSemiring R] [Semiring α] [Algebra R α] :
                                                                AlgEquiv.mapMatrix AlgEquiv.refl = AlgEquiv.refl
                                                                @[simp]
                                                                theorem AlgEquiv.mapMatrix_symm {m : Type u_2} {R : Type u_7} {α : Type v} {β : Type w} [Fintype m] [DecidableEq m] [CommSemiring R] [Semiring α] [Semiring β] [Algebra R α] [Algebra R β] (f : α ≃ₐ[R] β) :
                                                                @[simp]
                                                                theorem AlgEquiv.mapMatrix_trans {m : Type u_2} {R : Type u_7} {α : Type v} {β : Type w} {γ : Type u_9} [Fintype m] [DecidableEq m] [CommSemiring R] [Semiring α] [Semiring β] [Semiring γ] [Algebra R α] [Algebra R β] [Algebra R γ] (f : α ≃ₐ[R] β) (g : β ≃ₐ[R] γ) :
                                                                def Matrix.vecMulVec {m : Type u_2} {n : Type u_3} {α : Type v} [Mul α] (w : mα) (v : nα) :
                                                                Matrix m n α

                                                                For two vectors w and v, vecMulVec w v i j is defined to be w i * v j. Put another way, vecMulVec w v is exactly col w * row v.

                                                                Equations
                                                                Instances For
                                                                  theorem Matrix.vecMulVec_apply {m : Type u_2} {n : Type u_3} {α : Type v} [Mul α] (w : mα) (v : nα) (i : m) (j : n) :
                                                                  Matrix.vecMulVec w v i j = w i * v j
                                                                  theorem Matrix.vecMulVec_eq {m : Type u_2} {n : Type u_3} {α : Type v} [Mul α] [AddCommMonoid α] (w : mα) (v : nα) :
                                                                  def Matrix.mulVec {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype n] (M : Matrix m n α) (v : nα) :
                                                                  mα

                                                                  mulVec M v is the matrix-vector product of M and v, where v is seen as a column matrix. Put another way, mulVec M v is the vector whose entries are those of M * col v (see col_mulVec).

                                                                  Equations
                                                                  Instances For
                                                                    def Matrix.vecMul {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype m] (v : mα) (M : Matrix m n α) :
                                                                    nα

                                                                    vecMul v M is the vector-matrix product of v and M, where v is seen as a row matrix. Put another way, vecMul v M is the vector whose entries are those of row v * M (see row_vecMul).

                                                                    Equations
                                                                    Instances For
                                                                      @[simp]
                                                                      theorem Matrix.mulVec.addMonoidHomLeft_apply {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype n] (v : nα) (M : Matrix m n α) :
                                                                      ∀ (a : m), ↑(Matrix.mulVec.addMonoidHomLeft v) M a = Matrix.mulVec M v a
                                                                      def Matrix.mulVec.addMonoidHomLeft {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype n] (v : nα) :
                                                                      Matrix m n α →+ mα

                                                                      Left multiplication by a matrix, as an AddMonoidHom from vectors to vectors.

                                                                      Equations
                                                                      • One or more equations did not get rendered due to their size.
                                                                      Instances For
                                                                        theorem Matrix.mulVec_diagonal {m : Type u_2} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype m] [DecidableEq m] (v : mα) (w : mα) (x : m) :
                                                                        theorem Matrix.vecMul_diagonal {m : Type u_2} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype m] [DecidableEq m] (v : mα) (w : mα) (x : m) :
                                                                        theorem Matrix.dotProduct_mulVec {m : Type u_2} {n : Type u_3} {R : Type u_7} [Fintype n] [Fintype m] [NonUnitalSemiring R] (v : mR) (A : Matrix m n R) (w : nR) :

                                                                        Associate the dot product of mulVec to the left.

                                                                        @[simp]
                                                                        theorem Matrix.mulVec_zero {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype n] (A : Matrix m n α) :
                                                                        @[simp]
                                                                        theorem Matrix.zero_vecMul {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype m] (A : Matrix m n α) :
                                                                        @[simp]
                                                                        theorem Matrix.zero_mulVec {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype n] (v : nα) :
                                                                        @[simp]
                                                                        theorem Matrix.vecMul_zero {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype m] (v : mα) :
                                                                        theorem Matrix.smul_mulVec_assoc {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype n] [Monoid R] [DistribMulAction R α] [IsScalarTower R α α] (a : R) (A : Matrix m n α) (b : nα) :
                                                                        theorem Matrix.mulVec_add {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype n] (A : Matrix m n α) (x : nα) (y : nα) :
                                                                        theorem Matrix.add_mulVec {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype n] (A : Matrix m n α) (B : Matrix m n α) (x : nα) :
                                                                        theorem Matrix.vecMul_add {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype m] (A : Matrix m n α) (B : Matrix m n α) (x : mα) :
                                                                        theorem Matrix.add_vecMul {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocSemiring α] [Fintype m] (A : Matrix m n α) (x : mα) (y : mα) :
                                                                        theorem Matrix.vecMul_smul {m : Type u_2} {n : Type u_3} {R : Type u_7} {S : Type u_8} [Fintype n] [Monoid R] [NonUnitalNonAssocSemiring S] [DistribMulAction R S] [IsScalarTower R S S] (M : Matrix n m S) (b : R) (v : nS) :
                                                                        theorem Matrix.mulVec_smul {m : Type u_2} {n : Type u_3} {R : Type u_7} {S : Type u_8} [Fintype n] [Monoid R] [NonUnitalNonAssocSemiring S] [DistribMulAction R S] [SMulCommClass R S S] (M : Matrix m n S) (b : R) (v : nS) :
                                                                        @[simp]
                                                                        theorem Matrix.mulVec_single {m : Type u_2} {n : Type u_3} {R : Type u_7} [Fintype n] [DecidableEq n] [NonUnitalNonAssocSemiring R] (M : Matrix m n R) (j : n) (x : R) :
                                                                        Matrix.mulVec M (Pi.single j x) = fun i => M i j * x
                                                                        @[simp]
                                                                        theorem Matrix.single_vecMul {m : Type u_2} {n : Type u_3} {R : Type u_7} [Fintype m] [DecidableEq m] [NonUnitalNonAssocSemiring R] (M : Matrix m n R) (i : m) (x : R) :
                                                                        Matrix.vecMul (Pi.single i x) M = fun j => x * M i j
                                                                        theorem Matrix.diagonal_mulVec_single {n : Type u_3} {R : Type u_7} [Fintype n] [DecidableEq n] [NonUnitalNonAssocSemiring R] (v : nR) (j : n) (x : R) :
                                                                        theorem Matrix.single_vecMul_diagonal {n : Type u_3} {R : Type u_7} [Fintype n] [DecidableEq n] [NonUnitalNonAssocSemiring R] (v : nR) (j : n) (x : R) :
                                                                        @[simp]
                                                                        theorem Matrix.vecMul_vecMul {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [NonUnitalSemiring α] [Fintype n] [Fintype m] (v : mα) (M : Matrix m n α) (N : Matrix n o α) :
                                                                        @[simp]
                                                                        theorem Matrix.mulVec_mulVec {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [NonUnitalSemiring α] [Fintype n] [Fintype o] (v : oα) (M : Matrix m n α) (N : Matrix n o α) :
                                                                        theorem Matrix.star_mulVec {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalSemiring α] [Fintype n] [StarRing α] (M : Matrix m n α) (v : nα) :
                                                                        theorem Matrix.star_vecMul {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalSemiring α] [Fintype m] [StarRing α] (M : Matrix m n α) (v : mα) :
                                                                        theorem Matrix.mulVec_conjTranspose {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalSemiring α] [Fintype m] [StarRing α] (A : Matrix m n α) (x : mα) :
                                                                        theorem Matrix.vecMul_conjTranspose {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalSemiring α] [Fintype n] [StarRing α] (A : Matrix m n α) (x : nα) :
                                                                        theorem Matrix.mul_mul_apply {n : Type u_3} {α : Type v} [NonUnitalSemiring α] [Fintype n] (A : Matrix n n α) (B : Matrix n n α) (C : Matrix n n α) (i : n) (j : n) :
                                                                        (Matrix n n α * Matrix n n α) (Matrix n n α) Matrix.instHMulMatrixMatrixMatrix (A * B) C i j = Matrix.dotProduct (A i) (Matrix.mulVec B (Matrix.transpose C j))
                                                                        theorem Matrix.mulVec_one {m : Type u_2} {n : Type u_3} {α : Type v} [NonAssocSemiring α] [Fintype n] (A : Matrix m n α) :
                                                                        Matrix.mulVec A 1 = fun i => Finset.sum Finset.univ fun j => A i j
                                                                        theorem Matrix.vec_one_mul {m : Type u_2} {n : Type u_3} {α : Type v} [NonAssocSemiring α] [Fintype m] (A : Matrix m n α) :
                                                                        Matrix.vecMul 1 A = fun j => Finset.sum Finset.univ fun i => A i j
                                                                        @[simp]
                                                                        theorem Matrix.one_mulVec {m : Type u_2} {α : Type v} [NonAssocSemiring α] [Fintype m] [DecidableEq m] (v : mα) :
                                                                        @[simp]
                                                                        theorem Matrix.vecMul_one {m : Type u_2} {α : Type v} [NonAssocSemiring α] [Fintype m] [DecidableEq m] (v : mα) :
                                                                        theorem Matrix.neg_vecMul {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocRing α] [Fintype m] (v : mα) (A : Matrix m n α) :
                                                                        theorem Matrix.vecMul_neg {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocRing α] [Fintype m] (v : mα) (A : Matrix m n α) :
                                                                        theorem Matrix.neg_mulVec {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocRing α] [Fintype n] (v : nα) (A : Matrix m n α) :
                                                                        theorem Matrix.mulVec_neg {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocRing α] [Fintype n] (v : nα) (A : Matrix m n α) :
                                                                        theorem Matrix.sub_mulVec {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocRing α] [Fintype n] (A : Matrix m n α) (B : Matrix m n α) (x : nα) :
                                                                        theorem Matrix.vecMul_sub {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalNonAssocRing α] [Fintype m] (A : Matrix m n α) (B : Matrix m n α) (x : mα) :
                                                                        theorem Matrix.mulVec_transpose {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalCommSemiring α] [Fintype m] (A : Matrix m n α) (x : mα) :
                                                                        theorem Matrix.vecMul_transpose {m : Type u_2} {n : Type u_3} {α : Type v} [NonUnitalCommSemiring α] [Fintype n] (A : Matrix m n α) (x : nα) :
                                                                        theorem Matrix.mulVec_vecMul {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [NonUnitalCommSemiring α] [Fintype n] [Fintype o] (A : Matrix m n α) (B : Matrix o n α) (x : oα) :
                                                                        theorem Matrix.vecMul_mulVec {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [NonUnitalCommSemiring α] [Fintype m] [Fintype n] (A : Matrix m n α) (B : Matrix m o α) (x : nα) :
                                                                        theorem Matrix.mulVec_smul_assoc {m : Type u_2} {n : Type u_3} {α : Type v} [CommSemiring α] [Fintype n] (A : Matrix m n α) (b : nα) (a : α) :
                                                                        @[simp]
                                                                        theorem Matrix.transpose_transpose {m : Type u_2} {n : Type u_3} {α : Type v} (M : Matrix m n α) :
                                                                        theorem Matrix.transpose_injective {m : Type u_2} {n : Type u_3} {α : Type v} :
                                                                        Function.Injective Matrix.transpose
                                                                        @[simp]
                                                                        theorem Matrix.transpose_inj {m : Type u_2} {n : Type u_3} {α : Type v} {A : Matrix m n α} {B : Matrix m n α} :
                                                                        @[simp]
                                                                        theorem Matrix.transpose_zero {m : Type u_2} {n : Type u_3} {α : Type v} [Zero α] :
                                                                        @[simp]
                                                                        theorem Matrix.transpose_eq_zero {m : Type u_2} {n : Type u_3} {α : Type v} [Zero α] {M : Matrix m n α} :
                                                                        @[simp]
                                                                        theorem Matrix.transpose_one {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] [One α] :
                                                                        @[simp]
                                                                        theorem Matrix.transpose_eq_one {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] [One α] {M : Matrix n n α} :
                                                                        @[simp]
                                                                        theorem Matrix.transpose_add {m : Type u_2} {n : Type u_3} {α : Type v} [Add α] (M : Matrix m n α) (N : Matrix m n α) :
                                                                        @[simp]
                                                                        theorem Matrix.transpose_sub {m : Type u_2} {n : Type u_3} {α : Type v} [Sub α] (M : Matrix m n α) (N : Matrix m n α) :
                                                                        @[simp]
                                                                        theorem Matrix.transpose_mul {l : Type u_1} {m : Type u_2} {n : Type u_3} {α : Type v} [AddCommMonoid α] [CommSemigroup α] [Fintype n] (M : Matrix m n α) (N : Matrix n l α) :
                                                                        @[simp]
                                                                        theorem Matrix.transpose_smul {m : Type u_2} {n : Type u_3} {α : Type v} {R : Type u_10} [SMul R α] (c : R) (M : Matrix m n α) :
                                                                        @[simp]
                                                                        theorem Matrix.transpose_neg {m : Type u_2} {n : Type u_3} {α : Type v} [Neg α] (M : Matrix m n α) :
                                                                        theorem Matrix.transpose_map {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} {f : αβ} {M : Matrix m n α} :
                                                                        @[simp]
                                                                        theorem Matrix.transposeAddEquiv_apply (m : Type u_2) (n : Type u_3) (α : Type v) [Add α] (M : Matrix m n α) :
                                                                        def Matrix.transposeAddEquiv (m : Type u_2) (n : Type u_3) (α : Type v) [Add α] :
                                                                        Matrix m n α ≃+ Matrix n m α

                                                                        Matrix.transpose as an AddEquiv

                                                                        Equations
                                                                        • One or more equations did not get rendered due to their size.
                                                                        Instances For
                                                                          @[simp]
                                                                          theorem Matrix.transpose_list_sum {m : Type u_2} {n : Type u_3} {α : Type v} [AddMonoid α] (l : List (Matrix m n α)) :
                                                                          Matrix.transpose (List.sum l) = List.sum (List.map Matrix.transpose l)
                                                                          theorem Matrix.transpose_multiset_sum {m : Type u_2} {n : Type u_3} {α : Type v} [AddCommMonoid α] (s : Multiset (Matrix m n α)) :
                                                                          theorem Matrix.transpose_sum {m : Type u_2} {n : Type u_3} {α : Type v} [AddCommMonoid α] {ι : Type u_10} (s : Finset ι) (M : ιMatrix m n α) :
                                                                          Matrix.transpose (Finset.sum s fun i => M i) = Finset.sum s fun i => Matrix.transpose (M i)
                                                                          @[simp]
                                                                          theorem Matrix.transposeLinearEquiv_apply (m : Type u_2) (n : Type u_3) (R : Type u_7) (α : Type v) [Semiring R] [AddCommMonoid α] [Module R α] :
                                                                          ∀ (a : Matrix m n α), ↑(Matrix.transposeLinearEquiv m n R α) a = Equiv.toFun (Matrix.transposeAddEquiv m n α).toEquiv a
                                                                          def Matrix.transposeLinearEquiv (m : Type u_2) (n : Type u_3) (R : Type u_7) (α : Type v) [Semiring R] [AddCommMonoid α] [Module R α] :
                                                                          Matrix m n α ≃ₗ[R] Matrix n m α

                                                                          Matrix.transpose as a LinearMap

                                                                          Equations
                                                                          • One or more equations did not get rendered due to their size.
                                                                          Instances For
                                                                            @[simp]
                                                                            def Matrix.transposeRingEquiv (m : Type u_2) (α : Type v) [AddCommMonoid α] [CommSemigroup α] [Fintype m] :
                                                                            Matrix m m α ≃+* (Matrix m m α)ᵐᵒᵖ

                                                                            Matrix.transpose as a RingEquiv to the opposite ring

                                                                            Equations
                                                                            • One or more equations did not get rendered due to their size.
                                                                            Instances For
                                                                              @[simp]
                                                                              theorem Matrix.transpose_pow {m : Type u_2} {α : Type v} [CommSemiring α] [Fintype m] [DecidableEq m] (M : Matrix m m α) (k : ) :
                                                                              theorem Matrix.transpose_list_prod {m : Type u_2} {α : Type v} [CommSemiring α] [Fintype m] [DecidableEq m] (l : List (Matrix m m α)) :
                                                                              @[simp]
                                                                              theorem Matrix.transposeAlgEquiv_apply (m : Type u_2) (R : Type u_7) (α : Type v) [CommSemiring R] [CommSemiring α] [Fintype m] [DecidableEq m] [Algebra R α] (M : Matrix m m α) :
                                                                              @[simp]
                                                                              theorem Matrix.transposeAlgEquiv_symm_apply (m : Type u_2) (R : Type u_7) (α : Type v) [CommSemiring R] [CommSemiring α] [Fintype m] [DecidableEq m] [Algebra R α] :
                                                                              ∀ (a : (Matrix m m α)ᵐᵒᵖ), ↑(AlgEquiv.symm (Matrix.transposeAlgEquiv m R α)) a = Equiv.invFun (AddEquiv.trans (Matrix.transposeAddEquiv m m α) MulOpposite.opAddEquiv).toEquiv a
                                                                              def Matrix.transposeAlgEquiv (m : Type u_2) (R : Type u_7) (α : Type v) [CommSemiring R] [CommSemiring α] [Fintype m] [DecidableEq m] [Algebra R α] :

                                                                              Matrix.transpose as an AlgEquiv to the opposite ring

                                                                              Equations
                                                                              • One or more equations did not get rendered due to their size.
                                                                              Instances For
                                                                                @[simp]
                                                                                theorem Matrix.conjTranspose_apply {m : Type u_2} {n : Type u_3} {α : Type v} [Star α] (M : Matrix m n α) (i : m) (j : n) :

                                                                                Tell simp what the entries are in a conjugate transposed matrix.

                                                                                Compare with mul_apply, diagonal_apply_eq, etc.

                                                                                @[simp]
                                                                                theorem Matrix.conjTranspose_injective {m : Type u_2} {n : Type u_3} {α : Type v} [InvolutiveStar α] :
                                                                                Function.Injective Matrix.conjTranspose
                                                                                @[simp]
                                                                                theorem Matrix.conjTranspose_inj {m : Type u_2} {n : Type u_3} {α : Type v} [InvolutiveStar α] {A : Matrix m n α} {B : Matrix m n α} :
                                                                                @[simp]
                                                                                theorem Matrix.conjTranspose_zero {m : Type u_2} {n : Type u_3} {α : Type v} [AddMonoid α] [StarAddMonoid α] :
                                                                                @[simp]
                                                                                theorem Matrix.conjTranspose_eq_zero {m : Type u_2} {n : Type u_3} {α : Type v} [AddMonoid α] [StarAddMonoid α] {M : Matrix m n α} :
                                                                                @[simp]
                                                                                @[simp]
                                                                                theorem Matrix.conjTranspose_eq_one {n : Type u_3} {α : Type v} [DecidableEq n] [Semiring α] [StarRing α] {M : Matrix n n α} :
                                                                                @[simp]
                                                                                theorem Matrix.conjTranspose_add {m : Type u_2} {n : Type u_3} {α : Type v} [AddMonoid α] [StarAddMonoid α] (M : Matrix m n α) (N : Matrix m n α) :
                                                                                @[simp]
                                                                                theorem Matrix.conjTranspose_sub {m : Type u_2} {n : Type u_3} {α : Type v} [AddGroup α] [StarAddMonoid α] (M : Matrix m n α) (N : Matrix m n α) :
                                                                                @[simp]
                                                                                theorem Matrix.conjTranspose_smul_non_comm {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} [Star R] [Star α] [SMul R α] [SMul Rᵐᵒᵖ α] (c : R) (M : Matrix m n α) (h : ∀ (r : R) (a : α), star (r a) = MulOpposite.op (star r) star a) :
                                                                                theorem Matrix.conjTranspose_smul_self {m : Type u_2} {n : Type u_3} {α : Type v} [Mul α] [StarMul α] (c : α) (M : Matrix m n α) :
                                                                                @[simp]
                                                                                theorem Matrix.conjTranspose_nsmul {m : Type u_2} {n : Type u_3} {α : Type v} [AddMonoid α] [StarAddMonoid α] (c : ) (M : Matrix m n α) :
                                                                                @[simp]
                                                                                theorem Matrix.conjTranspose_zsmul {m : Type u_2} {n : Type u_3} {α : Type v} [AddGroup α] [StarAddMonoid α] (c : ) (M : Matrix m n α) :
                                                                                @[simp]
                                                                                theorem Matrix.conjTranspose_natCast_smul {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} [Semiring R] [AddCommMonoid α] [StarAddMonoid α] [Module R α] (c : ) (M : Matrix m n α) :
                                                                                @[simp]
                                                                                theorem Matrix.conjTranspose_intCast_smul {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} [Ring R] [AddCommGroup α] [StarAddMonoid α] [Module R α] (c : ) (M : Matrix m n α) :
                                                                                @[simp]
                                                                                theorem Matrix.conjTranspose_inv_natCast_smul {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} [DivisionSemiring R] [AddCommMonoid α] [StarAddMonoid α] [Module R α] (c : ) (M : Matrix m n α) :
                                                                                @[simp]
                                                                                theorem Matrix.conjTranspose_inv_intCast_smul {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} [DivisionRing R] [AddCommGroup α] [StarAddMonoid α] [Module R α] (c : ) (M : Matrix m n α) :
                                                                                @[simp]
                                                                                theorem Matrix.conjTranspose_ratCast_smul {m : Type u_2} {n : Type u_3} {R : Type u_7} {α : Type v} [DivisionRing R] [AddCommGroup α] [StarAddMonoid α] [Module R α] (c : ) (M : Matrix m n α) :
                                                                                @[simp]
                                                                                theorem Matrix.conjTranspose_rat_smul {m : Type u_2} {n : Type u_3} {α : Type v} [AddCommGroup α] [StarAddMonoid α] [Module α] (c : ) (M : Matrix m n α) :
                                                                                @[simp]
                                                                                theorem Matrix.conjTranspose_mul {l : Type u_1} {m : Type u_2} {n : Type u_3} {α : Type v} [Fintype n] [NonUnitalSemiring α] [StarRing α] (M : Matrix m n α) (N : Matrix n l α) :
                                                                                @[simp]
                                                                                theorem Matrix.conjTranspose_neg {m : Type u_2} {n : Type u_3} {α : Type v} [AddGroup α] [StarAddMonoid α] (M : Matrix m n α) :
                                                                                theorem Matrix.conjTranspose_map {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} [Star α] [Star β] {A : Matrix m n α} (f : αβ) (hf : Function.Semiconj f star star) :
                                                                                @[simp]

                                                                                When star x = x on the coefficients (such as the real numbers) conjTranspose and transpose are the same operation.

                                                                                @[simp]
                                                                                theorem Matrix.conjTransposeAddEquiv_apply (m : Type u_2) (n : Type u_3) (α : Type v) [AddMonoid α] [StarAddMonoid α] (M : Matrix m n α) :
                                                                                def Matrix.conjTransposeAddEquiv (m : Type u_2) (n : Type u_3) (α : Type v) [AddMonoid α] [StarAddMonoid α] :
                                                                                Matrix m n α ≃+ Matrix n m α

                                                                                Matrix.conjTranspose as an AddEquiv

                                                                                Equations
                                                                                • One or more equations did not get rendered due to their size.
                                                                                Instances For
                                                                                  theorem Matrix.conjTranspose_list_sum {m : Type u_2} {n : Type u_3} {α : Type v} [AddMonoid α] [StarAddMonoid α] (l : List (Matrix m n α)) :
                                                                                  Matrix.conjTranspose (List.sum l) = List.sum (List.map Matrix.conjTranspose l)
                                                                                  theorem Matrix.conjTranspose_multiset_sum {m : Type u_2} {n : Type u_3} {α : Type v} [AddCommMonoid α] [StarAddMonoid α] (s : Multiset (Matrix m n α)) :
                                                                                  theorem Matrix.conjTranspose_sum {m : Type u_2} {n : Type u_3} {α : Type v} [AddCommMonoid α] [StarAddMonoid α] {ι : Type u_10} (s : Finset ι) (M : ιMatrix m n α) :
                                                                                  @[simp]
                                                                                  theorem Matrix.conjTransposeLinearEquiv_apply (m : Type u_2) (n : Type u_3) (R : Type u_7) (α : Type v) [CommSemiring R] [StarRing R] [AddCommMonoid α] [StarAddMonoid α] [Module R α] [StarModule R α] :
                                                                                  ∀ (a : Matrix m n α), ↑(Matrix.conjTransposeLinearEquiv m n R α) a = Equiv.toFun (Matrix.conjTransposeAddEquiv m n α).toEquiv a
                                                                                  def Matrix.conjTransposeLinearEquiv (m : Type u_2) (n : Type u_3) (R : Type u_7) (α : Type v) [CommSemiring R] [StarRing R] [AddCommMonoid α] [StarAddMonoid α] [Module R α] [StarModule R α] :
                                                                                  Matrix m n α ≃ₗ⋆[R] Matrix n m α

                                                                                  Matrix.conjTranspose as a LinearMap

                                                                                  Equations
                                                                                  • One or more equations did not get rendered due to their size.
                                                                                  Instances For
                                                                                    def Matrix.conjTransposeRingEquiv (m : Type u_2) (α : Type v) [Semiring α] [StarRing α] [Fintype m] :
                                                                                    Matrix m m α ≃+* (Matrix m m α)ᵐᵒᵖ

                                                                                    Matrix.conjTranspose as a RingEquiv to the opposite ring

                                                                                    Equations
                                                                                    • One or more equations did not get rendered due to their size.
                                                                                    Instances For
                                                                                      @[simp]
                                                                                      theorem Matrix.conjTranspose_pow {m : Type u_2} {α : Type v} [Semiring α] [StarRing α] [Fintype m] [DecidableEq m] (M : Matrix m m α) (k : ) :
                                                                                      theorem Matrix.conjTranspose_list_prod {m : Type u_2} {α : Type v} [Semiring α] [StarRing α] [Fintype m] [DecidableEq m] (l : List (Matrix m m α)) :
                                                                                      instance Matrix.instStarMatrix {n : Type u_3} {α : Type v} [Star α] :
                                                                                      Star (Matrix n n α)

                                                                                      When α has a star operation, square matrices Matrix n n α have a star operation equal to Matrix.conjTranspose.

                                                                                      Equations
                                                                                      • Matrix.instStarMatrix = { star := Matrix.conjTranspose }
                                                                                      theorem Matrix.star_eq_conjTranspose {m : Type u_2} {α : Type v} [Star α] (M : Matrix m m α) :
                                                                                      @[simp]
                                                                                      theorem Matrix.star_apply {n : Type u_3} {α : Type v} [Star α] (M : Matrix n n α) (i : n) (j : n) :
                                                                                      star (Matrix n n α) Matrix.instStarMatrix M i j = star (M j i)
                                                                                      Equations

                                                                                      When α is a *-additive monoid, Matrix.star is also a *-additive monoid.

                                                                                      Equations

                                                                                      When α is a *-(semi)ring, Matrix.star is also a *-(semi)ring.

                                                                                      Equations
                                                                                      • One or more equations did not get rendered due to their size.
                                                                                      theorem Matrix.star_mul {n : Type u_3} {α : Type v} [Fintype n] [NonUnitalSemiring α] [StarRing α] (M : Matrix n n α) (N : Matrix n n α) :
                                                                                      star (M * N) = star N * star M

                                                                                      A version of star_mul for * instead of *.

                                                                                      def Matrix.submatrix {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} (A : Matrix m n α) (r_reindex : lm) (c_reindex : on) :
                                                                                      Matrix l o α

                                                                                      Given maps (r_reindex : l → m) and (c_reindex : o → n) reindexing the rows and columns of a matrix M : Matrix m n α, the matrix M.submatrix r_reindex c_reindex : Matrix l o α is defined by (M.submatrix r_reindex c_reindex) i j = M (r_reindex i) (c_reindex j) for (i,j) : l × o. Note that the total number of row and columns does not have to be preserved.

                                                                                      Equations
                                                                                      • Matrix.submatrix A r_reindex c_reindex = Matrix.of fun i j => A (r_reindex i) (c_reindex j)
                                                                                      Instances For
                                                                                        @[simp]
                                                                                        theorem Matrix.submatrix_apply {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} (A : Matrix m n α) (r_reindex : lm) (c_reindex : on) (i : l) (j : o) :
                                                                                        Matrix.submatrix A r_reindex c_reindex i j = A (r_reindex i) (c_reindex j)
                                                                                        @[simp]
                                                                                        theorem Matrix.submatrix_id_id {m : Type u_2} {n : Type u_3} {α : Type v} (A : Matrix m n α) :
                                                                                        @[simp]
                                                                                        theorem Matrix.submatrix_submatrix {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} {l₂ : Type u_10} {o₂ : Type u_11} (A : Matrix m n α) (r₁ : lm) (c₁ : on) (r₂ : l₂l) (c₂ : o₂o) :
                                                                                        Matrix.submatrix (Matrix.submatrix A r₁ c₁) r₂ c₂ = Matrix.submatrix A (r₁ r₂) (c₁ c₂)
                                                                                        @[simp]
                                                                                        theorem Matrix.transpose_submatrix {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} (A : Matrix m n α) (r_reindex : lm) (c_reindex : on) :
                                                                                        Matrix.transpose (Matrix.submatrix A r_reindex c_reindex) = Matrix.submatrix (Matrix.transpose A) c_reindex r_reindex
                                                                                        @[simp]
                                                                                        theorem Matrix.conjTranspose_submatrix {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [Star α] (A : Matrix m n α) (r_reindex : lm) (c_reindex : on) :
                                                                                        Matrix.conjTranspose (Matrix.submatrix A r_reindex c_reindex) = Matrix.submatrix (Matrix.conjTranspose A) c_reindex r_reindex
                                                                                        theorem Matrix.submatrix_add {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [Add α] (A : Matrix m n α) (B : Matrix m n α) :
                                                                                        theorem Matrix.submatrix_neg {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [Neg α] (A : Matrix m n α) :
                                                                                        theorem Matrix.submatrix_sub {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [Sub α] (A : Matrix m n α) (B : Matrix m n α) :
                                                                                        @[simp]
                                                                                        theorem Matrix.submatrix_zero {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [Zero α] :
                                                                                        theorem Matrix.submatrix_smul {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} {R : Type u_10} [SMul R α] (r : R) (A : Matrix m n α) :
                                                                                        theorem Matrix.submatrix_map {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} {β : Type w} (f : αβ) (e₁ : lm) (e₂ : on) (A : Matrix m n α) :
                                                                                        Matrix.submatrix (Matrix.map A f) e₁ e₂ = Matrix.map (Matrix.submatrix A e₁ e₂) f
                                                                                        theorem Matrix.submatrix_diagonal {l : Type u_1} {m : Type u_2} {α : Type v} [Zero α] [DecidableEq m] [DecidableEq l] (d : mα) (e : lm) (he : Function.Injective e) :

                                                                                        Given a (m × m) diagonal matrix defined by a map d : m → α, if the reindexing map e is injective, then the resulting matrix is again diagonal.

                                                                                        theorem Matrix.submatrix_one {l : Type u_1} {m : Type u_2} {α : Type v} [Zero α] [One α] [DecidableEq m] [DecidableEq l] (e : lm) (he : Function.Injective e) :
                                                                                        theorem Matrix.submatrix_mul {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [Fintype n] [Fintype o] [Mul α] [AddCommMonoid α] {p : Type u_10} {q : Type u_11} (M : Matrix m n α) (N : Matrix n p α) (e₁ : lm) (e₂ : on) (e₃ : qp) (he₂ : Function.Bijective e₂) :
                                                                                        Matrix.submatrix (M * N) e₁ e₃ = Matrix.submatrix M e₁ e₂ * Matrix.submatrix N e₂ e₃
                                                                                        theorem Matrix.diag_submatrix {l : Type u_1} {m : Type u_2} {α : Type v} (A : Matrix m m α) (e : lm) :

                                                                                        simp lemmas for Matrix.submatrixs interaction with Matrix.diagonal, 1, and Matrix.mul for when the mappings are bundled.

                                                                                        @[simp]
                                                                                        theorem Matrix.submatrix_diagonal_embedding {l : Type u_1} {m : Type u_2} {α : Type v} [Zero α] [DecidableEq m] [DecidableEq l] (d : mα) (e : l m) :
                                                                                        @[simp]
                                                                                        theorem Matrix.submatrix_diagonal_equiv {l : Type u_1} {m : Type u_2} {α : Type v} [Zero α] [DecidableEq m] [DecidableEq l] (d : mα) (e : l m) :
                                                                                        @[simp]
                                                                                        theorem Matrix.submatrix_one_embedding {l : Type u_1} {m : Type u_2} {α : Type v} [Zero α] [One α] [DecidableEq m] [DecidableEq l] (e : l m) :
                                                                                        Matrix.submatrix 1 e e = 1
                                                                                        @[simp]
                                                                                        theorem Matrix.submatrix_one_equiv {l : Type u_1} {m : Type u_2} {α : Type v} [Zero α] [One α] [DecidableEq m] [DecidableEq l] (e : l m) :
                                                                                        Matrix.submatrix 1 e e = 1
                                                                                        @[simp]
                                                                                        theorem Matrix.submatrix_mul_equiv {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [Fintype n] [Fintype o] [AddCommMonoid α] [Mul α] {p : Type u_10} {q : Type u_11} (M : Matrix m n α) (N : Matrix n p α) (e₁ : lm) (e₂ : o n) (e₃ : qp) :
                                                                                        Matrix.submatrix M e₁ e₂ * Matrix.submatrix N (e₂) e₃ = Matrix.submatrix (M * N) e₁ e₃
                                                                                        theorem Matrix.submatrix_mulVec_equiv {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [Fintype n] [Fintype o] [NonUnitalNonAssocSemiring α] (M : Matrix m n α) (v : oα) (e₁ : lm) (e₂ : o n) :
                                                                                        Matrix.mulVec (Matrix.submatrix M e₁ e₂) v = Matrix.mulVec M (v e₂.symm) e₁
                                                                                        theorem Matrix.submatrix_vecMul_equiv {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [Fintype l] [Fintype m] [NonUnitalNonAssocSemiring α] (M : Matrix m n α) (v : lα) (e₁ : l m) (e₂ : on) :
                                                                                        Matrix.vecMul v (Matrix.submatrix M (e₁) e₂) = Matrix.vecMul (v e₁.symm) M e₂
                                                                                        theorem Matrix.mul_submatrix_one {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [Fintype n] [Finite o] [NonAssocSemiring α] [DecidableEq o] (e₁ : n o) (e₂ : lo) (M : Matrix m n α) :
                                                                                        M * Matrix.submatrix 1 (e₁) e₂ = Matrix.submatrix M id (e₁.symm e₂)
                                                                                        theorem Matrix.one_submatrix_mul {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [Fintype m] [Finite o] [NonAssocSemiring α] [DecidableEq o] (e₁ : lo) (e₂ : m o) (M : Matrix m n α) :
                                                                                        Matrix.submatrix 1 e₁ e₂ * M = Matrix.submatrix M (e₂.symm e₁) id
                                                                                        def Matrix.reindex {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} (eₘ : m l) (eₙ : n o) :
                                                                                        Matrix m n α Matrix l o α

                                                                                        The natural map that reindexes a matrix's rows and columns with equivalent types is an equivalence.

                                                                                        Equations
                                                                                        • One or more equations did not get rendered due to their size.
                                                                                        Instances For
                                                                                          @[simp]
                                                                                          theorem Matrix.reindex_apply {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} (eₘ : m l) (eₙ : n o) (M : Matrix m n α) :
                                                                                          ↑(Matrix.reindex eₘ eₙ) M = Matrix.submatrix M eₘ.symm eₙ.symm
                                                                                          theorem Matrix.reindex_refl_refl {m : Type u_2} {n : Type u_3} {α : Type v} (A : Matrix m n α) :
                                                                                          @[simp]
                                                                                          theorem Matrix.reindex_symm {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} (eₘ : m l) (eₙ : n o) :
                                                                                          (Matrix.reindex eₘ eₙ).symm = Matrix.reindex eₘ.symm eₙ.symm
                                                                                          @[simp]
                                                                                          theorem Matrix.reindex_trans {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} {l₂ : Type u_10} {o₂ : Type u_11} (eₘ : m l) (eₙ : n o) (eₘ₂ : l l₂) (eₙ₂ : o o₂) :
                                                                                          (Matrix.reindex eₘ eₙ).trans (Matrix.reindex eₘ₂ eₙ₂) = Matrix.reindex (eₘ.trans eₘ₂) (eₙ.trans eₙ₂)
                                                                                          theorem Matrix.transpose_reindex {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} (eₘ : m l) (eₙ : n o) (M : Matrix m n α) :
                                                                                          Matrix.transpose (↑(Matrix.reindex eₘ eₙ) M) = ↑(Matrix.reindex eₙ eₘ) (Matrix.transpose M)
                                                                                          theorem Matrix.conjTranspose_reindex {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [Star α] (eₘ : m l) (eₙ : n o) (M : Matrix m n α) :
                                                                                          theorem Matrix.submatrix_mul_transpose_submatrix {m : Type u_2} {n : Type u_3} {α : Type v} [Fintype m] [Fintype n] [AddCommMonoid α] [Mul α] (e : m n) (M : Matrix m n α) :
                                                                                          @[reducible]
                                                                                          def Matrix.subLeft {α : Type v} {m : } {l : } {r : } (A : Matrix (Fin m) (Fin (l + r)) α) :
                                                                                          Matrix (Fin m) (Fin l) α

                                                                                          The left n × l part of an n × (l+r) matrix.

                                                                                          Equations
                                                                                          Instances For
                                                                                            @[reducible]
                                                                                            def Matrix.subRight {α : Type v} {m : } {l : } {r : } (A : Matrix (Fin m) (Fin (l + r)) α) :
                                                                                            Matrix (Fin m) (Fin r) α

                                                                                            The right n × r part of an n × (l+r) matrix.

                                                                                            Equations
                                                                                            Instances For
                                                                                              @[reducible]
                                                                                              def Matrix.subUp {α : Type v} {d : } {u : } {n : } (A : Matrix (Fin (u + d)) (Fin n) α) :
                                                                                              Matrix (Fin u) (Fin n) α

                                                                                              The top u × n part of a (u+d) × n matrix.

                                                                                              Equations
                                                                                              Instances For
                                                                                                @[reducible]
                                                                                                def Matrix.subDown {α : Type v} {d : } {u : } {n : } (A : Matrix (Fin (u + d)) (Fin n) α) :
                                                                                                Matrix (Fin d) (Fin n) α

                                                                                                The bottom d × n part of a (u+d) × n matrix.

                                                                                                Equations
                                                                                                Instances For
                                                                                                  @[reducible]
                                                                                                  def Matrix.subUpRight {α : Type v} {d : } {u : } {l : } {r : } (A : Matrix (Fin (u + d)) (Fin (l + r)) α) :
                                                                                                  Matrix (Fin u) (Fin r) α

                                                                                                  The top-right u × r part of a (u+d) × (l+r) matrix.

                                                                                                  Equations
                                                                                                  Instances For
                                                                                                    @[reducible]
                                                                                                    def Matrix.subDownRight {α : Type v} {d : } {u : } {l : } {r : } (A : Matrix (Fin (u + d)) (Fin (l + r)) α) :
                                                                                                    Matrix (Fin d) (Fin r) α

                                                                                                    The bottom-right d × r part of a (u+d) × (l+r) matrix.

                                                                                                    Equations
                                                                                                    Instances For
                                                                                                      @[reducible]
                                                                                                      def Matrix.subUpLeft {α : Type v} {d : } {u : } {l : } {r : } (A : Matrix (Fin (u + d)) (Fin (l + r)) α) :
                                                                                                      Matrix (Fin u) (Fin l) α

                                                                                                      The top-left u × l part of a (u+d) × (l+r) matrix.

                                                                                                      Equations
                                                                                                      Instances For
                                                                                                        @[reducible]
                                                                                                        def Matrix.subDownLeft {α : Type v} {d : } {u : } {l : } {r : } (A : Matrix (Fin (u + d)) (Fin (l + r)) α) :
                                                                                                        Matrix (Fin d) (Fin l) α

                                                                                                        The bottom-left d × l part of a (u+d) × (l+r) matrix.

                                                                                                        Equations
                                                                                                        Instances For

                                                                                                          row_col section #

                                                                                                          Simplification lemmas for Matrix.row and Matrix.col.

                                                                                                          theorem Matrix.col_injective {m : Type u_2} {α : Type v} :
                                                                                                          @[simp]
                                                                                                          theorem Matrix.col_inj {m : Type u_2} {α : Type v} {v : mα} {w : mα} :
                                                                                                          @[simp]
                                                                                                          theorem Matrix.col_zero {m : Type u_2} {α : Type v} [Zero α] :
                                                                                                          @[simp]
                                                                                                          theorem Matrix.col_eq_zero {m : Type u_2} {α : Type v} [Zero α] (v : mα) :
                                                                                                          Matrix.col v = 0 v = 0
                                                                                                          @[simp]
                                                                                                          theorem Matrix.col_add {m : Type u_2} {α : Type v} [Add α] (v : mα) (w : mα) :
                                                                                                          @[simp]
                                                                                                          theorem Matrix.col_smul {m : Type u_2} {R : Type u_7} {α : Type v} [SMul R α] (x : R) (v : mα) :
                                                                                                          theorem Matrix.row_injective {n : Type u_3} {α : Type v} :
                                                                                                          @[simp]
                                                                                                          theorem Matrix.row_inj {n : Type u_3} {α : Type v} {v : nα} {w : nα} :
                                                                                                          @[simp]
                                                                                                          theorem Matrix.row_zero {n : Type u_3} {α : Type v} [Zero α] :
                                                                                                          @[simp]
                                                                                                          theorem Matrix.row_eq_zero {n : Type u_3} {α : Type v} [Zero α] (v : nα) :
                                                                                                          Matrix.row v = 0 v = 0
                                                                                                          @[simp]
                                                                                                          theorem Matrix.row_add {m : Type u_2} {α : Type v} [Add α] (v : mα) (w : mα) :
                                                                                                          @[simp]
                                                                                                          theorem Matrix.row_smul {m : Type u_2} {R : Type u_7} {α : Type v} [SMul R α] (x : R) (v : mα) :
                                                                                                          @[simp]
                                                                                                          theorem Matrix.transpose_col {m : Type u_2} {α : Type v} (v : mα) :
                                                                                                          @[simp]
                                                                                                          theorem Matrix.transpose_row {m : Type u_2} {α : Type v} (v : mα) :
                                                                                                          @[simp]
                                                                                                          theorem Matrix.conjTranspose_col {m : Type u_2} {α : Type v} [Star α] (v : mα) :
                                                                                                          @[simp]
                                                                                                          theorem Matrix.conjTranspose_row {m : Type u_2} {α : Type v} [Star α] (v : mα) :
                                                                                                          theorem Matrix.row_vecMul {m : Type u_2} {n : Type u_3} {α : Type v} [Fintype m] [NonUnitalNonAssocSemiring α] (M : Matrix m n α) (v : mα) :
                                                                                                          theorem Matrix.col_vecMul {m : Type u_2} {n : Type u_3} {α : Type v} [Fintype m] [NonUnitalNonAssocSemiring α] (M : Matrix m n α) (v : mα) :
                                                                                                          theorem Matrix.col_mulVec {m : Type u_2} {n : Type u_3} {α : Type v} [Fintype n] [NonUnitalNonAssocSemiring α] (M : Matrix m n α) (v : nα) :
                                                                                                          theorem Matrix.row_mulVec {m : Type u_2} {n : Type u_3} {α : Type v} [Fintype n] [NonUnitalNonAssocSemiring α] (M : Matrix m n α) (v : nα) :
                                                                                                          @[simp]
                                                                                                          theorem Matrix.row_mul_col_apply {m : Type u_2} {α : Type v} [Fintype m] [Mul α] [AddCommMonoid α] (v : mα) (w : mα) (i : Unit) (j : Unit) :
                                                                                                          (Matrix Unit m α * Matrix m Unit α) (Matrix Unit Unit α) Matrix.instHMulMatrixMatrixMatrix (Matrix.row v) (Matrix.col w) i j = Matrix.dotProduct v w
                                                                                                          def Matrix.updateRow {m : Type u_2} {n : Type u_3} {α : Type v} [DecidableEq m] (M : Matrix m n α) (i : m) (b : nα) :
                                                                                                          Matrix m n α

                                                                                                          Update, i.e. replace the ith row of matrix A with the values in b.

                                                                                                          Equations
                                                                                                          Instances For
                                                                                                            def Matrix.updateColumn {m : Type u_2} {n : Type u_3} {α : Type v} [DecidableEq n] (M : Matrix m n α) (j : n) (b : mα) :
                                                                                                            Matrix m n α

                                                                                                            Update, i.e. replace the jth column of matrix A with the values in b.

                                                                                                            Equations
                                                                                                            Instances For
                                                                                                              @[simp]
                                                                                                              theorem Matrix.updateRow_self {m : Type u_2} {n : Type u_3} {α : Type v} {M : Matrix m n α} {i : m} {b : nα} [DecidableEq m] :
                                                                                                              @[simp]
                                                                                                              theorem Matrix.updateColumn_self {m : Type u_2} {n : Type u_3} {α : Type v} {M : Matrix m n α} {i : m} {j : n} {c : mα} [DecidableEq n] :
                                                                                                              Matrix.updateColumn M j c i j = c i
                                                                                                              @[simp]
                                                                                                              theorem Matrix.updateRow_ne {m : Type u_2} {n : Type u_3} {α : Type v} {M : Matrix m n α} {i : m} {b : nα} [DecidableEq m] {i' : m} (i_ne : i' i) :
                                                                                                              Matrix.updateRow M i b i' = M i'
                                                                                                              @[simp]
                                                                                                              theorem Matrix.updateColumn_ne {m : Type u_2} {n : Type u_3} {α : Type v} {M : Matrix m n α} {i : m} {j : n} {c : mα} [DecidableEq n] {j' : n} (j_ne : j' j) :
                                                                                                              Matrix.updateColumn M j c i j' = M i j'
                                                                                                              theorem Matrix.updateRow_apply {m : Type u_2} {n : Type u_3} {α : Type v} {M : Matrix m n α} {i : m} {j : n} {b : nα} [DecidableEq m] {i' : m} :
                                                                                                              Matrix.updateRow M i b i' j = if i' = i then b j else M i' j
                                                                                                              theorem Matrix.updateColumn_apply {m : Type u_2} {n : Type u_3} {α : Type v} {M : Matrix m n α} {i : m} {j : n} {c : mα} [DecidableEq n] {j' : n} :
                                                                                                              Matrix.updateColumn M j c i j' = if j' = j then c i else M i j'
                                                                                                              @[simp]
                                                                                                              theorem Matrix.updateColumn_subsingleton {m : Type u_2} {n : Type u_3} {R : Type u_7} [Subsingleton n] (A : Matrix m n R) (i : n) (b : mR) :
                                                                                                              @[simp]
                                                                                                              theorem Matrix.updateRow_subsingleton {m : Type u_2} {n : Type u_3} {R : Type u_7} [Subsingleton m] (A : Matrix m n R) (i : m) (b : nR) :
                                                                                                              theorem Matrix.map_updateRow {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} {M : Matrix m n α} {i : m} {b : nα} [DecidableEq m] (f : αβ) :
                                                                                                              theorem Matrix.map_updateColumn {m : Type u_2} {n : Type u_3} {α : Type v} {β : Type w} {M : Matrix m n α} {j : n} {c : mα} [DecidableEq n] (f : αβ) :
                                                                                                              theorem Matrix.updateRow_transpose {m : Type u_2} {n : Type u_3} {α : Type v} {M : Matrix m n α} {j : n} {c : mα} [DecidableEq n] :
                                                                                                              theorem Matrix.updateColumn_transpose {m : Type u_2} {n : Type u_3} {α : Type v} {M : Matrix m n α} {i : m} {b : nα} [DecidableEq m] :
                                                                                                              theorem Matrix.updateRow_conjTranspose {m : Type u_2} {n : Type u_3} {α : Type v} {M : Matrix m n α} {j : n} {c : mα} [DecidableEq n] [Star α] :
                                                                                                              theorem Matrix.updateColumn_conjTranspose {m : Type u_2} {n : Type u_3} {α : Type v} {M : Matrix m n α} {i : m} {b : nα} [DecidableEq m] [Star α] :
                                                                                                              @[simp]
                                                                                                              theorem Matrix.updateRow_eq_self {m : Type u_2} {n : Type u_3} {α : Type v} [DecidableEq m] (A : Matrix m n α) (i : m) :
                                                                                                              Matrix.updateRow A i (A i) = A
                                                                                                              @[simp]
                                                                                                              theorem Matrix.updateColumn_eq_self {m : Type u_2} {n : Type u_3} {α : Type v} [DecidableEq n] (A : Matrix m n α) (i : n) :
                                                                                                              (Matrix.updateColumn A i fun j => A j i) = A
                                                                                                              theorem Matrix.diagonal_updateColumn_single {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] (v : nα) (i : n) (x : α) :
                                                                                                              theorem Matrix.diagonal_updateRow_single {n : Type u_3} {α : Type v} [DecidableEq n] [Zero α] (v : nα) (i : n) (x : α) :

                                                                                                              Updating rows and columns commutes in the obvious way with reindexing the matrix.

                                                                                                              theorem Matrix.updateRow_submatrix_equiv {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [DecidableEq l] [DecidableEq m] (A : Matrix m n α) (i : l) (r : oα) (e : l m) (f : o n) :
                                                                                                              Matrix.updateRow (Matrix.submatrix A e f) i r = Matrix.submatrix (Matrix.updateRow A (e i) fun j => r (f.symm j)) e f
                                                                                                              theorem Matrix.submatrix_updateRow_equiv {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [DecidableEq l] [DecidableEq m] (A : Matrix m n α) (i : m) (r : nα) (e : l m) (f : o n) :
                                                                                                              Matrix.submatrix (Matrix.updateRow A i r) e f = Matrix.updateRow (Matrix.submatrix A e f) (e.symm i) fun i => r (f i)
                                                                                                              theorem Matrix.updateColumn_submatrix_equiv {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [DecidableEq o] [DecidableEq n] (A : Matrix m n α) (j : o) (c : lα) (e : l m) (f : o n) :
                                                                                                              Matrix.updateColumn (Matrix.submatrix A e f) j c = Matrix.submatrix (Matrix.updateColumn A (f j) fun i => c (e.symm i)) e f
                                                                                                              theorem Matrix.submatrix_updateColumn_equiv {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [DecidableEq o] [DecidableEq n] (A : Matrix m n α) (j : n) (c : mα) (e : l m) (f : o n) :
                                                                                                              Matrix.submatrix (Matrix.updateColumn A j c) e f = Matrix.updateColumn (Matrix.submatrix A e f) (f.symm j) fun i => c (e i)

                                                                                                              reindex versions of the above submatrix lemmas for convenience.

                                                                                                              theorem Matrix.updateRow_reindex {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [DecidableEq l] [DecidableEq m] (A : Matrix m n α) (i : l) (r : oα) (e : m l) (f : n o) :
                                                                                                              Matrix.updateRow (↑(Matrix.reindex e f) A) i r = ↑(Matrix.reindex e f) (Matrix.updateRow A (e.symm i) fun j => r (f j))
                                                                                                              theorem Matrix.reindex_updateRow {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [DecidableEq l] [DecidableEq m] (A : Matrix m n α) (i : m) (r : nα) (e : m l) (f : n o) :
                                                                                                              ↑(Matrix.reindex e f) (Matrix.updateRow A i r) = Matrix.updateRow (↑(Matrix.reindex e f) A) (e i) fun i => r (f.symm i)
                                                                                                              theorem Matrix.updateColumn_reindex {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [DecidableEq o] [DecidableEq n] (A : Matrix m n α) (j : o) (c : lα) (e : m l) (f : n o) :
                                                                                                              Matrix.updateColumn (↑(Matrix.reindex e f) A) j c = ↑(Matrix.reindex e f) (Matrix.updateColumn A (f.symm j) fun i => c (e i))
                                                                                                              theorem Matrix.reindex_updateColumn {l : Type u_1} {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} [DecidableEq o] [DecidableEq n] (A : Matrix m n α) (j : n) (c : mα) (e : m l) (f : n o) :
                                                                                                              ↑(Matrix.reindex e f) (Matrix.updateColumn A j c) = Matrix.updateColumn (↑(Matrix.reindex e f) A) (f j) fun i => c (e.symm i)
                                                                                                              theorem RingHom.map_matrix_mul {m : Type u_2} {n : Type u_3} {o : Type u_4} {α : Type v} {β : Type w} [Fintype n] [NonAssocSemiring α] [NonAssocSemiring β] (M : Matrix m n α) (N : Matrix n o α) (i : m) (j : o) (f : α →+* β) :
                                                                                                              f ((Matrix m n α * Matrix n o α) (Matrix m o α) Matrix.instHMulMatrixMatrixMatrix M N i j) = (Matrix m n β * Matrix n o β) (Matrix m o β) Matrix.instHMulMatrixMatrixMatrix (Matrix.map M f) (Matrix.map N f) i j
                                                                                                              theorem RingHom.map_dotProduct {n : Type u_3} {R : Type u_7} {S : Type u_8} [Fintype n] [NonAssocSemiring R] [NonAssocSemiring S] (f : R →+* S) (v : nR) (w : nR) :
                                                                                                              f (Matrix.dotProduct v w) = Matrix.dotProduct (f v) (f w)
                                                                                                              theorem RingHom.map_vecMul {m : Type u_2} {n : Type u_3} {R : Type u_7} {S : Type u_8} [Fintype n] [NonAssocSemiring R] [NonAssocSemiring S] (f : R →+* S) (M : Matrix n m R) (v : nR) (i : m) :
                                                                                                              f (Matrix.vecMul v M i) = Matrix.vecMul (f v) (Matrix.map M f) i
                                                                                                              theorem RingHom.map_mulVec {m : Type u_2} {n : Type u_3} {R : Type u_7} {S : Type u_8} [Fintype n] [NonAssocSemiring R] [NonAssocSemiring S] (f : R →+* S) (M : Matrix m n R) (v : nR) (i : m) :
                                                                                                              f (Matrix.mulVec M v i) = Matrix.mulVec (Matrix.map M f) (f v) i