Finite dimensional quantum mixed states, ρ.
The same comments apply as in Braket:
These could be done with a Hilbert space of Fintype, which would look like
(H : Type*) [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] [FiniteDimensional ℂ H]
or by choosing a particular Basis and asserting it is Fintype. But frankly it seems easier to
mostly focus on the basis-dependent notion of Matrix, which has the added benefit of an obvious
"classical" interpretation (as the basis elements, or diagonal elements of a mixed state). In that
sense, this quantum theory comes with the a particular classical theory always preferred.
Important definitions:
instMixable: theMixableinstance allowing convex combinations ofMStatesofClassical: Mixed states representing classical distributionspurity: The purityTr[ρ^2]of a statespectrum: The spectrum of the matrixuniform: The maximally mixed statemix: The total state corresponding to an ensembleaverage: Averages a function over an ensemble, with appropriate weights
A mixed quantum state is a PSD matrix with trace 1.
We don't extend (M : HermitianMat d ℂ) because that gives an annoying thing where
M is actually a Subtype, which means ρ.M.foo notation doesn't work.
- M : HermitianMat d ℂ
Instances For
Equations
- MState.instCoe = { coe := MState.M }
Every mixed state is Hermitian.
The map from mixed states to their matrices is injective
The matrices corresponding to MStates are Convex ℝ
The inner product of two MState's, as a real number between 0 and 1.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The expectation value of an operator on a quantum state.
Instances For
If a PSD observable A has expectation value of 0 on a state ρ, it must entirely contain the
support of ρ in its kernel.
If an observable A has expectation value of 1 on a state ρ, it must entirely contain the
support of ρ in its 1-eigenspace.
A mixed state can be constructed as a pure state arising from a ket.
Equations
- MState.pure ψ = { M := ⟨Matrix.vecMulVec ⇑ψ ⇑↑ψ, ⋯⟩, zero_le := ⋯, tr := ⋯ }
Instances For
The eigenvalue spectrum of a mixed quantum state, as a Distribution.
Equations
- ρ.spectrum = Distribution.mk' (fun (x : d) => ⋯.eigenvalues x) ⋯ ⋯
Instances For
The specturm of a pure state is (1,0,0,...), i.e. a constant distribution.
If the specturm of a mixed state is (1,0,0...) i.e. a constant distribution, it is a pure state.
A state ρ is pure iff its spectrum is (1,0,0,...) i.e. a constant distribution.
Equations
- MState.«term_⊗_» = Lean.ParserDescr.trailingNode `MState.«term_⊗_» 100 100 (Lean.ParserDescr.binary `andthen (Lean.ParserDescr.symbol " ⊗ ") (Lean.ParserDescr.cat `term 101))
Instances For
A representation of a classical distribution as a quantum state, diagonal in the given basis.
Equations
- MState.ofClassical dist = { M := HermitianMat.diagonal fun (x : d) => ↑(dist x), zero_le := ⋯, tr := ⋯ }
Instances For
The maximally mixed state.
Instances For
There is exactly one state on a dimension-1 system.
Equations
- MState.instUnique = { default := MState.uniform, uniq := ⋯ }
There exists a mixed state for every nonempty d.
Here, the maximally mixed one is chosen.
Equations
- MState.instInhabited = { default := MState.uniform }
Partial tracing out the right half of a system.
Equations
- ρ.traceRight = { M := ⟨ρ.m.traceRight, ⋯⟩, zero_le := ⋯, tr := ⋯ }
Instances For
Taking the direct product on the left and tracing it back out gives the same state.
Taking the direct product on the right and tracing it back out gives the same state.
Spectrum of direct product. There is a permutation σ so that the spectrum of the direct product of ρ₁ and ρ₂, as permuted under σ, is the pairwise products of the spectra of ρ₁ and ρ₂.
A mixed state is separable iff it can be written as a convex combination of product mixed states.
Equations
- One or more equations did not get rendered due to their size.
Instances For
A product state MState.prod is separable.
A pure state is separable iff the ket is a product state.
A pure state is separable iff the partial trace on the left is pure.
The purification of a mixed state. Always uses the full dimension of the Hilbert space (d) to
purify, so e.g. an existing pure state with d=4 still becomes d=16 in the purification. The defining
property is MState.traceRight_of_purify; see also MState.purify' for the bundled version.
Equations
Instances For
The defining property of purification, that tracing out the purifying system gives the original mixed state.
The heterogeneous SWAP gate that exchanges the left and right halves of a quantum system. This can apply even when the two "halves" are of different types, as opposed to (say) the SWAP gate on quantum circuits that leaves the qubit dimensions unchanged. Notably, it is not unitary.
Equations
- ρ.SWAP = ρ.relabel (Equiv.prodComm d₁ d₂).symm
Instances For
The associator that re-clusters the parts of a quantum system.
Equations
- ρ.assoc = ρ.relabel (Equiv.prodAssoc d₁ d₂ d₃).symm
Instances For
The associator that re-clusters the parts of a quantum system.
Instances For
Mixed states inherit the subspace topology from matrices
The projection from mixed states to their Hermitian matrices is an embedding
Equations
Instances For
The n-copy "power" of a mixed state, with the standard basis indexed by pi types.
Equations
- ρ⊗^n = MState.piProd fun (x : Fin n) => ρ
Instances For
The n-copy "power" of a mixed state, with the standard basis indexed by pi types.
Equations
- MState.«term_⊗^_» = Lean.ParserDescr.trailingNode `MState.«term_⊗^_» 110 110 (Lean.ParserDescr.binary `andthen (Lean.ParserDescr.symbol "⊗^") (Lean.ParserDescr.cat `term 111))