theorem
Matrix.fromBlocks_gram_posSemidef
{m : Type u_3}
{n : Type u_4}
{k : Type u_5}
[Fintype m]
[Fintype n]
[Fintype k]
(X : Matrix k n ℂ)
(Y : Matrix k m ℂ)
:
(fromBlocks (Y.conjTranspose * Y) (Y.conjTranspose * X) (X.conjTranspose * Y) (X.conjTranspose * X)).PosSemidef
The block Gram matrix [[YᴴY, YᴴX], [XᴴY, XᴴX]] is positive semidefinite.
theorem
Matrix.IsHermitian.smul_selfAdjoint
{n : Type u_1}
{𝕜 : Type u_2}
[RCLike 𝕜]
{A : Matrix n n 𝕜}
(hA : A.IsHermitian)
{c : 𝕜}
(hc : IsSelfAdjoint c)
:
(c • A).IsHermitian
theorem
Matrix.IsHermitian.smul_im_zero
{n : Type u_1}
{𝕜 : Type u_2}
[RCLike 𝕜]
{A : Matrix n n 𝕜}
(hA : A.IsHermitian)
{c : 𝕜}
(h : RCLike.im c = 0)
:
(c • A).IsHermitian
theorem
Matrix.IsHermitian.smul_real
{n : Type u_1}
{𝕜 : Type u_2}
[RCLike 𝕜]
{A : Matrix n n 𝕜}
(hA : A.IsHermitian)
(c : ℝ)
:
(c • A).IsHermitian
theorem
Matrix.IsHermitian.sum_eigenvalues_eq_trace
{n : Type u_1}
{𝕜 : Type u_2}
[RCLike 𝕜]
[DecidableEq n]
{A : Matrix n n 𝕜}
(hA : A.IsHermitian)
[Fintype n]
:
The sum of the eigenvalues of a Hermitian matrix is equal to its trace.
theorem
Matrix.IsHermitian.eigenvalues_zero_eq_zero
{n : Type u_1}
{𝕜 : Type u_2}
[RCLike 𝕜]
[DecidableEq n]
{A : Matrix n n 𝕜}
(hA : A.IsHermitian)
[Fintype n]
(h : ∀ (i : n), hA.eigenvalues i = 0)
:
If all eigenvalues are equal to zero, then the matrix is zero.
theorem
Matrix.kroneckerMap_conjTranspose
{R : Type u_3}
{m : Type u_4}
{n : Type u_1}
[CommRing R]
[StarRing R]
(A : Matrix m m R)
(B : Matrix n n R)
:
(kroneckerMap (fun (x1 x2 : R) => x1 * x2) A B).conjTranspose = kroneckerMap (fun (x1 x2 : R) => x1 * x2) A.conjTranspose B.conjTranspose
theorem
Matrix.kroneckerMap_IsHermitian
{R : Type u_3}
{m : Type u_4}
{n : Type u_1}
[CommRing R]
[StarRing R]
{A : Matrix m m R}
{B : Matrix n n R}
(hA : A.IsHermitian)
(hB : B.IsHermitian)
:
(kroneckerMap (fun (x1 x2 : R) => x1 * x2) A B).IsHermitian
theorem
Matrix.PosSemidef.outer_self_conj
{n : Type u_4}
{𝕜 : Type u_5}
[Fintype n]
[RCLike 𝕜]
(v : n → 𝕜)
:
(vecMulVec v ((starRingEnd (n → 𝕜)) v)).PosSemidef
theorem
Matrix.PosSemidef.convex_cone
{m : Type u_3}
{𝕜 : Type u_5}
[RCLike 𝕜]
{A B : Matrix m m 𝕜}
(hA : A.PosSemidef)
(hB : B.PosSemidef)
{c₁ c₂ : 𝕜}
(hc₁ : 0 ≤ c₁)
(hc₂ : 0 ≤ c₂)
:
(c₁ • A + c₂ • B).PosSemidef
theorem
Matrix.PosSemidef.stdBasisMatrix_iff_eq
{m : Type u_3}
{𝕜 : Type u_5}
[Fintype m]
[RCLike 𝕜]
[dm : DecidableEq m]
(i j : m)
{c : 𝕜}
(hc : 0 < c)
:
A standard basis matrix (with a positive entry) is positive semidefinite iff the entry is on the diagonal.
theorem
Matrix.PosSemidef.PosSemidef_kronecker
{m : Type u_3}
{n : Type u_4}
{𝕜 : Type u_5}
[Fintype m]
[Fintype n]
[RCLike 𝕜]
[dn : DecidableEq n]
{A : Matrix m m 𝕜}
{B : Matrix n n 𝕜}
(hA : A.PosSemidef)
(hB : B.PosSemidef)
:
(kroneckerMap (fun (x1 x2 : 𝕜) => x1 * x2) A B).PosSemidef
theorem
Matrix.PosSemidef.pos_smul
{m : Type u_3}
{𝕜 : Type u_5}
[RCLike 𝕜]
{A : Matrix m m 𝕜}
{c : 𝕜}
(hA : (c • A).PosSemidef)
(hc : 0 < c)
:
theorem
Matrix.PosDef.of_toLin_ker_eq_bot
{n : Type u_3}
{𝕜 : Type u_5}
[Fintype n]
[RCLike 𝕜]
[DecidableEq n]
{A : Matrix n n 𝕜}
(hA : (toLin' A).ker = ⊥)
(hA₂ : A.PosSemidef)
:
A.PosDef
theorem
Matrix.PosDef.ker_range_antitone
{d : Type u_6}
[Fintype d]
[DecidableEq d]
{A B : Matrix d d ℂ}
(hA : A.IsHermitian)
(hB : B.IsHermitian)
:
(toEuclideanLin A).ker ≤ (toEuclideanLin B).ker ↔ (toEuclideanLin B).range ≤ (toEuclideanLin A).range
theorem
Matrix.PosSemidef.le_of_nonneg_imp
{n : Type u_3}
{𝕜 : Type u_5}
[RCLike 𝕜]
{A B : Matrix n n 𝕜}
{R : Type u_6}
[AddCommGroup R]
[PartialOrder R]
[IsOrderedAddMonoid R]
(f : Matrix n n 𝕜 →+ R)
(h : ∀ (A : Matrix n n 𝕜), A.PosSemidef → 0 ≤ f A)
:
theorem
Matrix.PosSemidef.le_of_nonneg_imp'
{n : Type u_3}
{𝕜 : Type u_5}
[RCLike 𝕜]
{R : Type u_6}
[AddCommGroup R]
[PartialOrder R]
[IsOrderedAddMonoid R]
{x y : R}
(f : R →+ Matrix n n 𝕜)
(h : ∀ (x : R), 0 ≤ x → (f x).PosSemidef)
:
theorem
Matrix.PosSemidef.nonneg_iff_eigenvalue_nonneg
{n : Type u_3}
{𝕜 : Type u_5}
[Fintype n]
[RCLike 𝕜]
{A : Matrix n n 𝕜}
(hA : A.IsHermitian)
[DecidableEq n]
:
theorem
Matrix.PosSemidef.diagonal_monotone
{n : Type u_3}
{𝕜 : Type u_5}
[RCLike 𝕜]
[DecidableEq n]
:
theorem
Matrix.PosSemidef.diagonal_mono
{n : Type u_3}
{𝕜 : Type u_5}
[RCLike 𝕜]
[DecidableEq n]
{d₁ d₂ : n → 𝕜}
:
theorem
Matrix.PosSemidef.le_smul_one_of_eigenvalues_iff
{n : Type u_3}
{𝕜 : Type u_5}
[Fintype n]
[RCLike 𝕜]
{A : Matrix n n 𝕜}
[DecidableEq n]
(hA : A.IsHermitian)
(c : ℝ)
:
theorem
Matrix.PosSemidef.smul_one_le_of_eigenvalues_iff
{n : Type u_3}
{𝕜 : Type u_5}
[Fintype n]
[RCLike 𝕜]
{A : Matrix n n 𝕜}
[DecidableEq n]
(hA : A.IsHermitian)
(c : ℝ)
:
@[simp]
theorem
Matrix.traceRight_trace
{R : Type u_5}
{d₁ : Type u_4}
{d₂ : Type u_3}
[AddCommMonoid R]
[Fintype d₁]
[Fintype d₂]
(A : Matrix (d₁ × d₂) (d₁ × d₂) R)
:
theorem
Matrix.IsHermitian.traceLeft
{R : Type u_5}
{d : Type u_4}
[AddCommMonoid R]
[Fintype d]
[StarAddMonoid R]
{d₁ : Type u_3}
{A : Matrix (d × d₁) (d × d₁) R}
(hA : A.IsHermitian)
:
theorem
Matrix.IsHermitian.traceRight
{R : Type u_5}
{d : Type u_4}
[AddCommMonoid R]
[Fintype d]
[StarAddMonoid R]
{d₁ : Type u_3}
{A : Matrix (d₁ × d) (d₁ × d) R}
(hA : A.IsHermitian)
:
theorem
Matrix.PosSemidef.traceLeft
{𝕜 : Type u_2}
[RCLike 𝕜]
{d₁ : Type u_3}
{d₂ : Type u_4}
{A : Matrix (d₁ × d₂) (d₁ × d₂) 𝕜}
[Fintype d₂]
[Fintype d₁]
[DecidableEq d₁]
(hA : A.PosSemidef)
:
theorem
Matrix.PosSemidef.traceRight
{𝕜 : Type u_2}
[RCLike 𝕜]
{d₁ : Type u_3}
{d₂ : Type u_4}
{A : Matrix (d₁ × d₂) (d₁ × d₂) 𝕜}
[Fintype d₂]
[Fintype d₁]
[DecidableEq d₂]
(hA : A.PosSemidef)
:
theorem
Matrix.PosDef.kron
{d₁ : Type u_3}
{d₂ : Type u_4}
{𝕜 : Type u_5}
[Fintype d₁]
[DecidableEq d₁]
[Fintype d₂]
[DecidableEq d₂]
[RCLike 𝕜]
{A : Matrix d₁ d₁ 𝕜}
{B : Matrix d₂ d₂ 𝕜}
(hA : A.PosDef)
(hB : B.PosDef)
:
(kroneckerMap (fun (x1 x2 : 𝕜) => x1 * x2) A B).PosDef
theorem
Matrix.PosDef.submatrix
{d₁ : Type u_3}
{d₂ : Type u_4}
{𝕜 : Type u_5}
[Fintype d₁]
[DecidableEq d₁]
[Fintype d₂]
[DecidableEq d₂]
[RCLike 𝕜]
{M : Matrix d₁ d₁ 𝕜}
(hM : M.PosDef)
{e : d₂ → d₁}
(he : Function.Injective e)
:
theorem
Matrix.PosDef.reindex
{d₁ : Type u_3}
{d₂ : Type u_4}
{𝕜 : Type u_5}
[Fintype d₁]
[DecidableEq d₁]
[Fintype d₂]
[DecidableEq d₂]
[RCLike 𝕜]
{M : Matrix d₁ d₁ 𝕜}
(hM : M.PosDef)
(e : d₁ ≃ d₂)
:
((Matrix.reindex e e) M).PosDef
@[simp]
theorem
Matrix.PosDef.reindex_iff
{d₁ : Type u_3}
{d₂ : Type u_4}
{𝕜 : Type u_5}
[Fintype d₁]
[DecidableEq d₁]
[Fintype d₂]
[DecidableEq d₂]
[RCLike 𝕜]
{M : Matrix d₁ d₁ 𝕜}
(e : d₁ ≃ d₂)
:
theorem
Matrix.PosSemidef.rsmul
{n : Type u_3}
[Fintype n]
{M : Matrix n n ℂ}
(hM : M.PosSemidef)
{c : ℝ}
(hc : 0 ≤ c)
:
(c • M).PosSemidef
theorem
Matrix.PosDef_iff_eigenvalues'
{d : Type u_3}
{𝕜 : Type u_4}
[Fintype d]
[DecidableEq d]
[RCLike 𝕜]
(M : Matrix d d 𝕜)
:
theorem
Matrix.IsHermitian.cfc_eigenvalues
{d : Type u_3}
{𝕜 : Type u_4}
[Fintype d]
[DecidableEq d]
[RCLike 𝕜]
{M : Matrix d d 𝕜}
(hM : M.IsHermitian)
(f : ℝ → ℝ)
:
∃ (e : d ≃ d), eigenvalues ⋯ = f ∘ hM.eigenvalues ∘ ⇑e
theorem
Matrix.IsHermitian.eigenvalues_eq_of_unitary_similarity_diagonal
{d : Type u_5}
{𝕜 : Type u_6}
[Fintype d]
[DecidableEq d]
[RCLike 𝕜]
{A : Matrix d d 𝕜}
(hA : A.IsHermitian)
{U : Matrix d d 𝕜}
(hU : U ∈ unitaryGroup d 𝕜)
{f : d → ℝ}
(h : A = (U * diagonal fun (i : d) => ↑(f i)) * U.conjTranspose)
:
∃ (σ : d ≃ d), hA.eigenvalues ∘ ⇑σ = f
If a Hermitian matrix A is unitarily similar to a diagonal matrix with real entries f, then the eigenvalues of A are a permutation of f.
@[simp]
theorem
Matrix.toEuclideanLin_one
{α : Type u_3}
{n : Type u_4}
[RCLike α]
[Fintype n]
[DecidableEq n]
:
theorem
Matrix.PosSemidef.pos_of_mem_spectrum
{d : Type u_3}
{𝕜 : Type u_4}
[Fintype d]
[DecidableEq d]
[RCLike 𝕜]
{A : Matrix d d 𝕜}
(hA : A.PosSemidef)
(r : ℝ)
:
theorem
Matrix.spectrum_prod
{𝕜 : Type u_2}
[RCLike 𝕜]
{d : Type u_3}
{d₂ : Type u_4}
[Fintype d]
[DecidableEq d]
[Fintype d₂]
[DecidableEq d₂]
{A : Matrix d d 𝕜}
{B : Matrix d₂ d₂ 𝕜}
(hA : A.IsHermitian)
(hB : B.IsHermitian)
:
theorem
Matrix.IsHermitian.spectrum_eq_image_eigenvalues
{n : Type u_1}
[DecidableEq n]
[Fintype n]
{A : Matrix n n ℂ}
(hA : A.IsHermitian)
:
theorem
Matrix.IsHermitian.card_spectrum_eq_image
{n : Type u_1}
[DecidableEq n]
[Fintype n]
{A : Matrix n n ℂ}
(hA : A.IsHermitian)
[Fintype ↑(spectrum ℝ A)]
:
theorem
Matrix.IsHermitian.sub_iInf_eignevalues
{d : Type u_3}
[Fintype d]
[DecidableEq d]
{A : Matrix d d ℂ}
(hA : A.IsHermitian)
:
(A - iInf hA.eigenvalues • 1).PosSemidef
theorem
Matrix.IsHermitian.iInf_eigenvalues_le_dotProduct_mulVec
{d : Type u_3}
[Fintype d]
[DecidableEq d]
{A : Matrix d d ℂ}
(hA : A.IsHermitian)
(v : d → ℂ)
:
theorem
Matrix.IsHermitian.iInf_eigenvalues_le_of_posSemidef
{d : Type u_3}
[Fintype d]
[DecidableEq d]
{A B : Matrix d d ℂ}
(hAB : (B - A).PosSemidef)
(hA : A.IsHermitian)
(hB : B.IsHermitian)
:
theorem
Matrix.IsHermitian.iInf_eigenvalues_le
{d : Type u_3}
[Fintype d]
[DecidableEq d]
{A B : Matrix d d ℂ}
(hAB : A ≤ B)
(hA : A.IsHermitian)
(hB : B.IsHermitian)
:
theorem
Matrix.IsHermitian.iInf_eigenvalues_smul_one_le
{d : Type u_3}
[Fintype d]
[DecidableEq d]
{A : Matrix d d ℂ}
(hA : A.IsHermitian)
:
theorem
Matrix.IsHermitian.spectrum_subset_Ici_of_sub
{d : Type u_3}
{𝕜 : Type u_4}
[Fintype d]
[DecidableEq d]
[RCLike 𝕜]
{A x : Matrix d d 𝕜}
(hA : A.IsHermitian)
(hl : (x - A).PosSemidef)
:
theorem
Matrix.IsHermitian.spectrum_subset_Iic_of_sub
{d : Type u_3}
{𝕜 : Type u_4}
[Fintype d]
[DecidableEq d]
[RCLike 𝕜]
{A x : Matrix d d 𝕜}
(hA : A.IsHermitian)
(hl : (A - x).PosSemidef)
:
theorem
Matrix.IsHermitian.spectrum_subset_of_mem_Icc
{d : Type u_3}
{𝕜 : Type u_4}
[Fintype d]
[DecidableEq d]
[RCLike 𝕜]
{A B x : Matrix d d 𝕜}
(hA : A.IsHermitian)
(hB : B.IsHermitian)
(hl : (x - A).PosSemidef)
(hr : (B - x).PosSemidef)
:
theorem
Matrix.traceRight_eq_traceLeft_reindex
{n : Type u_3}
{m : Type u_4}
{R : Type u_5}
[Fintype m]
[AddCommMonoid R]
(M : Matrix (n × m) (n × m) R)
:
The right partial trace of a matrix is equal to the left partial trace of the matrix reindexed by swapping the tensor factors.
@[simp]
theorem
Matrix.traceRight_add
{n : Type u_1}
{m : Type u_3}
{α : Type u_4}
[AddCommGroup α]
[Fintype m]
{A B : Matrix (n × m) (n × m) α}
:
@[simp]
theorem
Matrix.traceRight_neg
{n : Type u_1}
{m : Type u_3}
{α : Type u_4}
[AddCommGroup α]
[Fintype m]
{A : Matrix (n × m) (n × m) α}
:
@[simp]
theorem
Matrix.traceRight_sub
{n : Type u_1}
{m : Type u_3}
{α : Type u_4}
[AddCommGroup α]
[Fintype m]
{A B : Matrix (n × m) (n × m) α}
:
@[simp]
theorem
Matrix.traceRight_smul
{n : Type u_1}
{m : Type u_3}
{α : Type u_4}
[AddCommGroup α]
[Fintype m]
{R : Type u_5}
[DistribSMul R α]
{A : Matrix (n × m) (n × m) α}
(r : R)
:
theorem
Matrix.unitaryGroup_row_norm
{n : Type u_1}
[DecidableEq n]
[Fintype n]
(U : ↥(unitaryGroup n ℂ))
(i : n)
:
def
Matrix.piProd
{ι : Type u_3}
{d : ι → Type u_4}
[fι : Fintype ι]
{R : Type u_5}
[CommMonoid R]
(A : (i : ι) → Matrix (d i) (d i) R)
:
Matrix ((i : ι) → d i) ((i : ι) → d i) R
Equations
- Matrix.piProd A = Matrix.of fun (j k : (i : ι) → d i) => ∏ i : ι, A i (j i) (k i)
Instances For
theorem
Matrix.IsHermitian.piProd
{ι : Type u_3}
{d : ι → Type u_4}
[fι : Fintype ι]
{R : Type u_5}
{A : (i : ι) → Matrix (d i) (d i) R}
[CommSemiring R]
[StarRing R]
(hA : ∀ (i : ι), (A i).IsHermitian)
:
theorem
Matrix.trace_piProd
{ι : Type u_3}
{d : ι → Type u_4}
[fι : Fintype ι]
{R : Type u_5}
{A : (i : ι) → Matrix (d i) (d i) R}
[DecidableEq ι]
[(i : ι) → Fintype (d i)]
[CommSemiring R]
:
theorem
Matrix.PosSemidef.piProd
{ι : Type u_3}
{d : ι → Type u_4}
[fι : Fintype ι]
{R : Type u_5}
{A : (i : ι) → Matrix (d i) (d i) R}
[DecidableEq ι]
[(i : ι) → Fintype (d i)]
[RCLike R]
(hA : ∀ (i : ι), (A i).PosSemidef)
:
theorem
Matrix.kronecker_conj_eq
{m : Type u_3}
{n : Type u_4}
{p : Type u_5}
{q : Type u_6}
{α : Type u_7}
[CommSemiring α]
[StarRing α]
[Fintype m]
[Fintype n]
(A : Matrix m m α)
(B : Matrix n n α)
(C : Matrix p m α)
(D : Matrix q n α)
:
kroneckerMap (fun (x1 x2 : α) => x1 * x2) C D * kroneckerMap (fun (x1 x2 : α) => x1 * x2) A B * (kroneckerMap (fun (x1 x2 : α) => x1 * x2) C D).conjTranspose = kroneckerMap (fun (x1 x2 : α) => x1 * x2) (C * A * C.conjTranspose) (D * B * D.conjTranspose)
The conjugate of a Kronecker product by a Kronecker product is the Kronecker product of the conjugates (for matrices).