Documentation

Mathlib.Analysis.Matrix.Order

The partial order on matrices #

This file constructs the partial order and star ordered instances on matrices on ๐•œ. This allows us to use more general results from Cโ‹†-algebras, like CFC.sqrt.

Main results #

Implementation notes #

Note that the partial order instance is scoped to MatrixOrder. Please open scoped MatrixOrder to use this.

@[reducible, inline]
abbrev Matrix.instPreOrder {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] :
Preorder (Matrix n n ๐•œ)

The preorder on matrices given by A โ‰ค B := (B - A).PosSemidef.

Instances For
    theorem Matrix.le_iff {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] {A B : Matrix n n ๐•œ} :
    theorem Matrix.nonneg_iff_posSemidef {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] {A : Matrix n n ๐•œ} :
    theorem Matrix.LE.le.posSemidef {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] {A : Matrix n n ๐•œ} :
    0 โ‰ค A โ†’ A.PosSemidef

    Alias of the forward direction of Matrix.nonneg_iff_posSemidef.

    theorem Matrix.PosSemidef.nonneg {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] {A : Matrix n n ๐•œ} :
    A.PosSemidef โ†’ 0 โ‰ค A

    Alias of the reverse direction of Matrix.nonneg_iff_posSemidef.

    @[reducible, inline]
    abbrev Matrix.instPartialOrder {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] :
    PartialOrder (Matrix n n ๐•œ)

    The partial order on matrices given by A โ‰ค B := (B - A).PosSemidef.

    Instances For
      theorem Matrix.instIsOrderedAddMonoid {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] :
      IsOrderedAddMonoid (Matrix n n ๐•œ)
      theorem Matrix.posSemidef_is_closed {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] :
      IsClosed {A : Matrix n n ๐•œ | A.PosSemidef}
      theorem Matrix.instOrderClosedTopology {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] :
      OrderClosedTopology (Matrix n n ๐•œ)
      theorem Matrix.instNonnegSpectrumClass {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] [Fintype n] :
      theorem Matrix.instStarOrderedRing {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] [Fintype n] :
      StarOrderedRing (Matrix n n ๐•œ)
      theorem Matrix.PosSemidef.inv_sqrt {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] [Fintype n] [DecidableEq n] {A : Matrix n n ๐•œ} (hA : A.PosSemidef) :
      theorem Matrix.PosSemidef.det_sqrt {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] [Fintype n] [DecidableEq n] {A : Matrix n n ๐•œ} (hA : A.PosSemidef) :
      theorem Matrix.IsHermitian.det_abs {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] [Fintype n] [DecidableEq n] {A : Matrix n n ๐•œ} (hA : A.IsHermitian) :
      theorem Matrix.posSemidef_iff_isHermitian_and_spectrum_nonneg {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] [Fintype n] [DecidableEq n] {A : Matrix n n ๐•œ} :
      A.PosSemidef โ†” A.IsHermitian โˆง spectrum ๐•œ A โІ {a : ๐•œ | 0 โ‰ค a}
      theorem Matrix.PosSemidef.posDef_iff_isUnit {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] [Fintype n] [DecidableEq n] {x : Matrix n n ๐•œ} (hx : x.PosSemidef) :

      A positive semi-definite matrix is positive definite if and only if it is invertible.

      theorem Matrix.isStrictlyPositive_iff_posDef {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] [Fintype n] [DecidableEq n] {x : Matrix n n ๐•œ} :
      theorem Matrix.PosDef.isStrictlyPositive {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] [Fintype n] [DecidableEq n] {x : Matrix n n ๐•œ} :

      Alias of the reverse direction of Matrix.isStrictlyPositive_iff_posDef.

      theorem Matrix.IsStrictlyPositive.posDef {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] [Fintype n] [DecidableEq n] {x : Matrix n n ๐•œ} :

      Alias of the forward direction of Matrix.isStrictlyPositive_iff_posDef.

      theorem Matrix.PosSemidef.posDef_iff_det_ne_zero {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] [Fintype n] [DecidableEq n] {A : Matrix n n ๐•œ} (hA : A.PosSemidef) :
      theorem Matrix.PosSemidef.kronecker {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] [Finite n] {m : Type u_3} [Finite m] {x : Matrix n n ๐•œ} {y : Matrix m m ๐•œ} (hx : x.PosSemidef) (hy : y.PosSemidef) :
      (kroneckerMap (fun (x1 x2 : ๐•œ) => x1 * x2) x y).PosSemidef

      The kronecker product of two positive semi-definite matrices is positive semi-definite.

      theorem Matrix.PosDef.kronecker {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] [Finite n] {m : Type u_3} [Finite m] {x : Matrix n n ๐•œ} {y : Matrix m m ๐•œ} (hx : x.PosDef) (hy : y.PosDef) :
      (kroneckerMap (fun (x1 x2 : ๐•œ) => x1 * x2) x y).PosDef

      The kronecker of two positive definite matrices is positive definite.

      theorem Matrix.PosSemidef.hadamard {๐•œ : Type u_1} [RCLike ๐•œ] {ฮน : Type u_3} {A B : Matrix ฮน ฮน ๐•œ} (hA : A.PosSemidef) (hB : B.PosSemidef) :

      [Schur product theorem][schur1911] (positive semidefinite version): the Hadamard (entrywise) product of positive semidefinite matrices is positive semidefinite.

      theorem Matrix.PosDef.hadamard {๐•œ : Type u_1} [RCLike ๐•œ] {ฮน : Type u_3} {A B : Matrix ฮน ฮน ๐•œ} (hA : A.PosDef) (hB : B.PosDef) :

      Schur product theorem: the Hadamard (entrywise) product of positive definite matrices is positive definite.

      def Matrix.tracePositiveLinearMap (n : Type u_3) (ฮฑ : Type u_4) (๐•œ : Type u_5) [Fintype n] [Semiring ฮฑ] [RCLike ๐•œ] [Module ฮฑ ๐•œ] :
      Matrix n n ๐•œ โ†’โ‚š[ฮฑ] ๐•œ

      Matrix.trace as a positive linear map.

      Instances For
        @[simp]
        theorem Matrix.toLinearMap_tracePositiveLinearMap (n : Type u_3) (ฮฑ : Type u_4) (๐•œ : Type u_5) [Fintype n] [Semiring ฮฑ] [RCLike ๐•œ] [Module ฮฑ ๐•œ] :
        (tracePositiveLinearMap n ฮฑ ๐•œ).toLinearMap = traceLinearMap n ฮฑ ๐•œ
        @[simp]
        theorem Matrix.tracePositiveLinearMap_apply (n : Type u_3) (ฮฑ : Type u_4) (๐•œ : Type u_5) [Fintype n] [Semiring ฮฑ] [RCLike ๐•œ] [Module ฮฑ ๐•œ] (x : Matrix n n ๐•œ) :
        (tracePositiveLinearMap n ฮฑ ๐•œ) x = x.trace
        @[instance_reducible]
        noncomputable def Matrix.toMatrixSeminormedAddCommGroup {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] [Fintype n] (M : Matrix n n ๐•œ) (hM : M.PosSemidef) :

        A positive definite matrix M induces a norm on Matrix n n ๐•œ โ€–xโ€– = sqrt (x * M * xแดด).trace.

        Instances For
          @[instance_reducible]
          noncomputable def Matrix.toMatrixNormedAddCommGroup {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] [Fintype n] (M : Matrix n n ๐•œ) (hM : M.PosDef) :
          NormedAddCommGroup (Matrix n n ๐•œ)

          A positive definite matrix M induces a norm on Matrix n n ๐•œ: โ€–xโ€– = sqrt (x * M * xแดด).trace.

          Instances For
            @[instance_reducible]
            def Matrix.toMatrixInnerProductSpace {๐•œ : Type u_1} {n : Type u_2} [RCLike ๐•œ] [Fintype n] (M : Matrix n n ๐•œ) (hM : M.PosSemidef) :
            InnerProductSpace ๐•œ (Matrix n n ๐•œ)

            A positive semi-definite matrix M induces an inner product on Matrix n n ๐•œ: โŸชx, yโŸซ = (y * M * xแดด).trace.

            Instances For

              The isometric continuous functional calculus on Matrix n n ๐•œ arising from the operator norm given by the identification with (continuous) linear endomorphisms of EuclideanSpace ๐•œ n.