PhyslibSearch

QuantumInfo.ForMathlib.HermitianMat.Trace

34 declarations

definition

Trace of a Hermitian matrix AHermitianMatn(α)A \in \text{HermitianMat}_n(\alpha) as an element of the self-adjoint base RR

#trace

Let α\alpha be a \ast-ring and RR be a subring of its self-adjoint elements such that RR is the maximal self-adjoint part of α\alpha. For a Hermitian matrix AHermitianMatn(α)A \in \text{HermitianMat}_n(\alpha), the function trace(A)\text{trace}(A) returns the trace of AA as an element of RR. For example, if α=C\alpha = \mathbb{C}, then the trace is returned as a real number in R=RR = \mathbb{R}.

theorem

algebraMap(A.trace)=Tr(A.mat)\text{algebraMap}(A.\text{trace}) = \text{Tr}(A.\text{mat})

#trace_eq_trace

Let AA be a Hermitian matrix with entries in α\alpha, where α\alpha is an algebra over a ring RR. Let A.matA.\text{mat} denote the underlying matrix of AA, and A.traceA.\text{trace} denote the trace of the Hermitian matrix as an element of RR. Then the image of the Hermitian trace under the horizontal map algebraMap:Rα\text{algebraMap} : R \to \alpha is equal to the standard matrix trace Tr(A.mat)\text{Tr}(A.\text{mat}).

theorem

Linearity of Trace under Scalar Multiplication for Hermitian Matrices

#trace_smul

Let AA be a Hermitian matrix with entries in α\alpha, and let rr be a scalar from a self-adjoint ring RR. The trace of the scalar multiplication of rr and AA is equal to the product of rr and the trace of AA: tr(rA)=rtr(A)\text{tr}(r \cdot A) = r \cdot \text{tr}(A) where tr\text{tr} denotes the trace specialized for Hermitian matrices that maps to the self-adjoint part RR of the base ring α\alpha.

theorem

The trace of the zero Hermitian matrix is zero

#trace_zero

The trace of the zero Hermitian matrix 0HermitianMatn(α)0 \in \text{HermitianMat}_n(\alpha) is equal to 00 in the base ring RR, where RR is the subring of self-adjoint elements.

theorem

trace(A+B)=trace(A)+trace(B)\text{trace}(A + B) = \text{trace}(A) + \text{trace}(B) for Hermitian matrices A,BA, B

#trace_add

Let AA and BB be Hermitian matrices of size nn with entries in α\alpha. The trace of the sum of these matrices is equal to the sum of their individual traces, namely trace(A+B)=trace(A)+trace(B)\text{trace}(A + B) = \text{trace}(A) + \text{trace}(B). Here, the trace is defined such that it maps to the self-adjoint part RR of the scalar ring α\alpha.

theorem

Trace of A-A is tr(A)-\text{tr}(A) for Hermitian Matrices

#trace_neg

Let AA be a Hermitian matrix of size n×nn \times n over a star-ring α\alpha. The trace of the negative of the matrix is equal to the negation of the trace of the matrix, i.e., tr(A)=tr(A)\text{tr}(-A) = -\text{tr}(A), where the trace is defined as a self-adjoint element of the underlying scalar structure.

theorem

tr(AB)=tr(A)tr(B)\text{tr}(A - B) = \text{tr}(A) - \text{tr}(B) for Hermitian matrices A,BA, B

#trace_sub

For any two Hermitian matrices AA and BB of the same size, the trace of their difference is equal to the difference of their traces, i.e., tr(AB)=tr(A)tr(B)\text{tr}(A - B) = \text{tr}(A) - \text{tr}(B). Here, the trace of a Hermitian matrix is defined as a self-adjoint element of the underlying scalar ring (for example, a real number when the matrices are over the complex numbers).

theorem

The trace of a Hermitian matrix is self-adjoint

#isSelfAdjoint_trace

Let AA be an n×nn \times n matrix over a star-ring α\alpha. If AA is Hermitian, then its trace tr(A)\text{tr}(A) is a self-adjoint element of α\alpha.

theorem

trace(AkB)=trace(A)trace(B)\text{trace}(A \otimes_k B) = \text{trace}(A) \cdot \text{trace}(B) for Hermitian Matrices

#trace_kronecker

Let AA and BB be Hermitian matrices. Assuming a faithful scalar action of the base ring RR on the matrix entries α\alpha, the trace of the Kronecker product of AA and BB is equal to the product of their individual traces, denoted as trace(AkB)=trace(A)trace(B)\text{trace}(A \otimes_k B) = \text{trace}(A) \cdot \text{trace}(B). Here, the trace is defined such that it maps a Hermitian matrix to a self-adjoint element of its base ring.

theorem

`A.trace` equals tr(A)\text{tr}(A) for real Hermitian matrices

#trace_eq_trace_trivial

For any Hermitian matrix AA with entries in R\mathbb{R}, the value of the Hermitian trace `A.trace` is equal to the standard matrix trace tr(A)\text{tr}(A).

theorem

Trace of a Hermitian matrix over k\mathbb{k} equals Re(tr(A))\text{Re}(\text{tr}(A))

#trace_eq_re_trace

Let AA be a Hermitian matrix of size n×nn \times n over an `RCLike` field k\mathbb{k} (such as R\mathbb{R} or C\mathbb{C}). The trace of AA as a Hermitian matrix coincides with the real part of the standard matrix trace of AA. That is, trH(A)=Re(tr(A))\text{tr}_{H}(A) = \text{Re}(\text{tr}(A)), where trH\text{tr}_{H} denotes the trace operation specifically defined for Hermitian matrices.

theorem

The trace of the identity Hermitian matrix equals the size of the index set nn

#trace_one

Let nn be a finite index set with decidable equality. For the identity Hermitian matrix 11 over an R\mathbb{R}-clike field k\mathbb{k} (such as R\mathbb{R} or C\mathbb{C}), the trace of this matrix, denoted as trace(1)\text{trace}(1), is equal to the cardinality of the index set nn.

theorem

The Hermitian trace of AA equals the standard matrix trace for `RCLike` fields

#trace_eq_trace_rc

Let nn be an index type and k\mathbb{k} be an `RCLike` field (such as R\mathbb{R} or C\mathbb{C}). For any Hermitian matrix AHermitianMat(n,k)A \in \text{HermitianMat}(n, \mathbb{k}), the trace of the Hermitian matrix, trH(A)\text{tr}_{H}(A), is equal to the standard matrix trace of its underlying matrix, tr(A.mat)\text{tr}(A.mat).

theorem

The trace of a diagonal Hermitian matrix diag(f)\text{diag}(f) equals fi\sum f_i

#trace_diagonal

Let TT be a finite type and let f:TRf: T \to \mathbb{R} be a function. Let diagonalkf\verb|diagonal|_\mathbb{k} f be the Hermitian diagonal matrix over a field k\mathbb{k} whose diagonal entries are given by ff. Then the trace of this Hermitian matrix is equal to the sum of the elements of ff, i.e., trace(diag(f))=iTf(i)\text{trace}(\text{diag}(f)) = \sum_{i \in T} f(i).

theorem

eigenvalues(A)=tr(A)\sum \text{eigenvalues}(A) = \text{tr}(A) for Hermitian matrices over R\mathbb{R} or C\mathbb{C}

#sum_eigenvalues_eq_trace

Let AA be a Hermitian matrix with entries in an `RCLike` field k\mathbb{k} (such as R\mathbb{R} or C\mathbb{C}). The sum of the eigenvalues of AA is equal to the trace of AA, where the trace is considered as an element of the real numbers R\mathbb{R}. Formally, iλi=tr(A)\sum_{i} \lambda_i = \text{tr}(A), where tr(A)\text{tr}(A) is the specialized trace for Hermitian matrices that maps to the self-adjoint part of the base field.

theorem

The real trace of a Hermitian matrix AA is 00 iff its standard trace is 00

#trace_eq_zero_iff

Let AA be a Hermitian matrix with entries in an `RCLike` field k\mathbb{k} (such as R\mathbb{R} or C\mathbb{C}). The real-valued trace of AA, denoted as `A.trace`, is equal to 00 if and only if the standard matrix trace of AA, denoted as `A.mat.trace`, is equal to 00.

theorem

The self-adjoint trace of a Hermitian matrix AA is 11 iff its matrix trace is 11

#trace_eq_one_iff

Let nn be an index type and k\mathbb{k} be an `RCLike` field (such as R\mathbb{R} or C\mathbb{C}). For any n×nn \times n Hermitian matrix AA over k\mathbb{k}, the self-adjoint trace trsa(A)\text{tr}_{\text{sa}}(A) is equal to 11 if and only if the standard matrix trace tr(A)\text{tr}(A) is equal to 11. Here, the self-adjoint trace trsa(A)\text{tr}_{\text{sa}}(A) is defined to be the real-valued trace (specifically, the real part of the matrix trace in the case of complex matrices).

theorem

The trace of a Hermitian matrix is invariant under reindexing: tr(A.reindex(e))=tr(A)\text{tr}(A.\text{reindex}(e)) = \text{tr}(A)

#trace_reindex

Let AA be a Hermitian matrix with complex entries indexed by nn. Given a bijection (equivalence) e:nme: n \simeq m between index sets nn and mm, let AA' be the Hermitian matrix obtained by reindexing AA by ee. Then the trace of AA' is equal to the trace of AA. Specifically, since the trace of a Hermitian matrix is defined as a real number, this equality holds in R\mathbb{R}.

definition

Left partial trace of a Hermitian matrix traceLeft(A)\text{traceLeft}(A)

#traceLeft

Given a Hermitian matrix AA over a star-ring α\alpha with indices in the product space m×nm \times n, the left partial trace traceLeft(A)\text{traceLeft}(A) is a Hermitian matrix with indices in nn. It is obtained by taking the left partial trace of the underlying matrix AmatA_{\text{mat}}, where the result remains Hermitian. For an entry indexed by (j1,j2)n×n(j_1, j_2) \in n \times n, the operation is defined by summing over the first subsystem: (traceLeft(A))j1,j2=im(Amat)(i,j1),(i,j2) (\text{traceLeft}(A))_{j_1, j_2} = \sum_{i \in m} (A_{\text{mat}})_{(i, j_1), (i, j_2)}

definition

Right partial trace of a Hermitian matrix AHm×n(α)A \in \mathcal{H}_{m \times n}(\alpha)

#traceRight

Given a Hermitian matrix AHm×n(α)A \in \mathcal{H}_{m \times n}(\alpha) over a star-ring α\alpha, where the index set is a product m×nm \times n, the right partial trace traceRight(A)\text{traceRight}(A) is a Hermitian matrix in Hm(α)\mathcal{H}_m(\alpha). It is defined by applying the matrix right partial trace to the underlying matrix of AA: (traceRight(A))i,j=knA(i,k),(j,k) (\text{traceRight}(A))_{i, j} = \sum_{k \in n} A_{(i, k), (j, k)} The result is guaranteed to be a Hermitian matrix of size m×mm \times m if the original matrix AA is Hermitian.

theorem

The underlying matrix of the left partial trace of a Hermitian matrix AA equals the left partial trace of A.matA.\text{mat}

#traceLeft_mat

Let AA be a Hermitian matrix with indices in m×nm \times n. Let A.matA.\text{mat} denote the underlying matrix in Mm×n×m×n(α)M_{m \times n \times m \times n}(\alpha). Then the underlying matrix of the left partial trace of AA is equal to the left partial trace of the underlying matrix AA. That is, (traceLeft(A)).mat=traceLeft(A.mat) (\text{traceLeft}(A)).\text{mat} = \text{traceLeft}(A.\text{mat}) where the left partial trace for a matrix MM is defined as (traceLeft(M))i1,j1=i2mM(i2,i1),(i2,j1)(\text{traceLeft}(M))_{i_1, j_1} = \sum_{i_2 \in m} M_{(i_2, i_1), (i_2, j_1)}.

theorem

Additivity of the left partial trace for Hermitian matrices: TrL(A+B)=TrL(A)+TrL(B)\text{Tr}_L(A + B) = \text{Tr}_L(A) + \text{Tr}_L(B)

#traceLeft_add

Let AA and BB be Hermitian matrices with row and column indices in d×nd \times n over a star-additive monoid. The left partial trace of their sum is equal to the sum of their individual left partial traces: TrL(A+B)=TrL(A)+TrL(B)\text{Tr}_L(A + B) = \text{Tr}_L(A) + \text{Tr}_L(B) where the left partial trace TrL\text{Tr}_L of a Hermitian matrix MM is defined such that its underlying matrix mat(TrL(M))\text{mat}(\text{Tr}_L(M)) coincides with the standard matrix partial trace over the first subsystem.

theorem

Left Partial Trace of a Negated Hermitian Matrix is (A)traceLeft=(AtraceLeft)(-A)^{\text{traceLeft}} = - (A^{\text{traceLeft}})

#traceLeft_neg

For any Hermitian matrix AA whose row and column indices are structured as products d×d1d \times d_1 and d×d2d \times d_2 respectively, the left partial trace operation commutes with negation: (A)traceLeft=(AtraceLeft)(-A)^{\text{traceLeft}} = -(A^{\text{traceLeft}}). Here, traceLeft\text{traceLeft} denotes the partial trace taken over the first component dd of the index products, resulting in a Hermitian matrix of size d1×d2d_1 \times d_2.

theorem

The left partial trace of Hermitian matrices is distributive over subtraction: (AB).traceLeft=A.traceLeftB.traceLeft(A - B).\text{traceLeft} = A.\text{traceLeft} - B.\text{traceLeft}

#traceLeft_sub

Let AA and BB be Hermitian matrices whose row and column indices are structured as the product of two index sets d×nd \times n. The left partial trace operation on Hermitian matrices, denoted traceLeft\text{traceLeft}, is distributive over subtraction: (AB).traceLeft=A.traceLeftB.traceLeft(A - B).\text{traceLeft} = A.\text{traceLeft} - B.\text{traceLeft} where the left partial trace of a Hermitian matrix is defined such that its entries are the sums over the first index component idi \in d, maintaining the Hermitian property in the resulting n×nn \times n matrix.

theorem

The Matrix Representation of the Right Partial Trace of a Hermitian Matrix AA is Equal to the Right Partial Trace of its Matrix A.matA.\text{mat}

#traceRight_mat

Let AA be a Hermitian matrix with row indices in m×nm \times n and column indices in m×nm \times n. The matrix representation of the right partial trace of AA, denoted as (traceRight(A)).mat(\text{traceRight}(A)).\text{mat}, is equal to the right partial trace of the matrix representation of AA, denoted as A.mat.traceRightA.\text{mat}.\text{traceRight}. Here, the right partial trace (traceRight(M))i,j(\text{traceRight}(M))_{i, j} of a matrix MM(m×n)×(m×n)M \in M_{(m \times n) \times (m \times n)} is defined as the sum over the second index: knM(i,k),(j,k)\sum_{k \in n} M_{(i, k), (j, k)}.

theorem

The right partial trace of Hermitian matrices is additive: (A+B)traceRight=AtraceRight+BtraceRight(A + B)^{\text{traceRight}} = A^{\text{traceRight}} + B^{\text{traceRight}}

#traceRight_add

For any Hermitian matrices AA and BB whose row and column indices are structured as m×nm \times n, the right partial trace satisfies the additivity property (A+B)traceRight=AtraceRight+BtraceRight(A + B)^{\text{traceRight}} = A^{\text{traceRight}} + B^{\text{traceRight}}. Here, the right partial trace traceRight\text{traceRight} denotes the operation of taking the trace over the second component nn of the index products, resulting in a Hermitian matrix with indices in mm.

theorem

traceRight(A)=traceRight(A)\text{traceRight}(-A) = -\text{traceRight}(A) for Hermitian matrices

#traceRight_neg

Let AA be a Hermitian matrix with row and column indices in m×nm \times n. The right partial trace of the negation of AA is equal to the negation of the right partial trace of AA, i.e., traceRight(A)=traceRight(A)\text{traceRight}(-A) = -\text{traceRight}(A).

theorem

The right partial trace of Hermitian matrices is distributive over subtraction: (AB)traceRight=AtraceRightBtraceRight(A - B)^{\text{traceRight}} = A^{\text{traceRight}} - B^{\text{traceRight}}

#traceRight_sub

Let AA and BB be Hermitian matrices whose row and column indices are structured as m×nm \times n. The right partial trace traceRight\text{traceRight} satisfies the distributive property over subtraction: (AB)traceRight=AtraceRightBtraceRight(A - B)^{\text{traceRight}} = A^{\text{traceRight}} - B^{\text{traceRight}} where AtraceRightA^{\text{traceRight}} denotes the Hermitian matrix obtained by taking the partial trace over the second subsystem (the nn component of the index product).

theorem

Trleft(rA)=rTrleft(A)\text{Tr}_{\text{left}}(r \cdot A) = r \cdot \text{Tr}_{\text{left}}(A) for Hermitian matrices and rRr \in \mathbb{R}

#traceLeft_smul

Let AA be a Hermitian matrix with indices in m×nm \times n, and let rr be a real number. The left partial trace of the scalar product rAr \cdot A is equal to the scalar product of rr and the left partial trace of AA, denoted as Trleft(rA)=rTrleft(A)\text{Tr}_{\text{left}}(r \cdot A) = r \cdot \text{Tr}_{\text{left}}(A). Here, the operation Trleft\text{Tr}_{\text{left}} maps a Hermitian matrix to a smaller Hermitian matrix by summing over the first subsystem's indices.

theorem

traceRight(rA)=rtraceRight(A)\text{traceRight}(r \cdot A) = r \cdot \text{traceRight}(A) for Hermitian matrices and real scalars rr

#traceRight_smul

Let AA be a Hermitian matrix in M(n×m)×(n×m)(α)M_{(n \times m) \times (n \times m)}(\alpha) and rr be a real number. The right partial trace of the scalar multiplication of AA by rr is equal to rr times the right partial trace of AA, that is, traceRight(rA)=rtraceRight(A)\text{traceRight}(r \cdot A) = r \cdot \text{traceRight}(A).

theorem

tr(traceLeft(A))=tr(A)\text{tr}(\text{traceLeft}(A)) = \text{tr}(A) for Hermitian matrices

#traceLeft_trace

Let AA be a Hermitian matrix with row and column indices in d1×d2d_1 \times d_2. The trace of the left partial trace of AA is equal to the trace of AA: tr(traceLeft(A))=tr(A)\text{tr}(\text{traceLeft}(A)) = \text{tr}(A) where traceLeft(A)\text{traceLeft}(A) denotes the partial trace of the Hermitian matrix over the first subsystem, and tr\text{tr} denotes the trace of a Hermitian matrix (which, for scalars in an `RCLike` field like C\mathbb{C}, corresponds to the real part of the standard matrix trace).

theorem

tr(traceRight(A))=tr(A)\text{tr}(\text{traceRight}(A)) = \text{tr}(A) for Hermitian matrices

#traceRight_trace

Let AA be a Hermitian matrix with row and column indices in d1×d2d_1 \times d_2. The trace of its right partial trace traceRight(A)\text{traceRight}(A) is equal to the trace of AA, i.e., tr(traceRight(A))=tr(A)\text{tr}(\text{traceRight}(A)) = \text{tr}(A) where the trace of a Hermitian matrix is take in the sense of `HermitianMat.trace` (mapping to the maximal self-adjoint part of the scalars).

theorem

Left Partial Trace of Kronecker Product ABA \otimes B equals Tr(A)B\text{Tr}(A) \cdot B

#traceLeft_kron

Let AA be a Hermitian matrix of size m×mm \times m and BB be a Hermitian matrix of size n×nn \times n over an R\mathbb{R}-clike field k\mathbb{k}. Assume the index set for mm is finite. Then the left partial trace of the Kronecker product ABA \otimes B is equal to the product of the trace of AA and the matrix BB, i.e., traceLeft(AB)=Tr(A)B \text{traceLeft}(A \otimes B) = \text{Tr}(A) \cdot B where Tr(A)\text{Tr}(A) is the real-valued trace of the Hermitian matrix AA.

theorem

Right Partial Trace of Kronecker Product (AkB)(A \otimes_k B) equals trace(B)A\text{trace}(B) \cdot A

#traceRight_kron

Let AA be an m×mm \times m Hermitian matrix and BB be an n×nn \times n Hermitian matrix. Let AkBA \otimes_k B denote the Kronecker product of AA and BB, which is a Hermitian matrix over the index set (m×n)(m \times n). Then the right partial trace of the Kronecker product is given by: traceRight(AkB)=trace(B)A \text{traceRight}(A \otimes_k B) = \text{trace}(B) \cdot A where trace(B)\text{trace}(B) is the trace of BB (viewed as an element of the self-adjoint part of the base ring) and \cdot denotes scalar multiplication.