filter_functions.superoperator module
This module provides some functions related to superoperators and quantum maps.
Functions
liouville_representation()Calculate the Liouville representation of a unitary with respect to a basis
liouville_to_choi()Convert from Liouville to Choi matrix representation.
liouville_is_CP()Check if superoperator in Liouville representation is completely positive.
liouville_is_cCP()Check if superoperator in Liouville representation is conditional CP.
- liouville_is_CP(superoperator: ndarray, basis: Basis, return_eig: bool | None = False, atol: float | None = None) bool | Tuple[bool, Tuple[ndarray, ndarray]][source]
Test if a Liouville superoperator is completely positive (CP).
- Parameters:
- superoperator: ndarray, shape (…, d**2, d**2)
The superoperator in Liouville representation to be checked for CPness.
- basis: Basis, shape (d**2, d, d)
The operator basis defining the Liouville representation.
- return_eig: bool, optional
Return the tuple of eigenvalues and eigenvectors of the Choi matrix. The default is False.
- atol: float, optional
Absolute tolerance for the complete positivity.
- Returns:
- CP: bool, (shape (…,))
The (array, if broadcasted) of bools indicating if superoperator is CP.
- (D, V): Tuple[ndarray, ndarray]
The eigenvalues and eigenvectors of the Choi matrix (only if return_eig is True).
See also
liouville_representationCalculate Liouville representation of a unitary.
Liouville_to_choiConvert from Liouville to Choi matrix representation.
liouville_is_cCPTest if a superoperator is conditional CP.
Notes
A superoperator \(\mathcal{S}\) is completely positive (CP) if and only if its Choi matrix representation is positive semidefinite:
\[\mathcal{S}\text{ is CP }\Leftrightarrow \mathrm{choi}(\mathcal{S})\geq 0.\]
- liouville_is_cCP(superoperator: ndarray, basis: Basis, return_eig: bool | None = False, atol: float | None = None) bool | Tuple[bool, Tuple[ndarray, ndarray]][source]
Test if a Liouville superoperator is conditional completely positive.
- Parameters:
- superoperator: ndarray, shape (…, d**2, d**2)
The superoperator in Liouville representation to be checked for cCPness
- basis: Basis, shape (d**2, d, d)
The operator basis defining the Liouville representation.
- return_eig: bool, optional
Return the tuple of eigenvalues and eigenvectors of the Choi matrix projected on the complement of the maximally entangled state. The default is False.
- atol: float, optional
Absolute tolerance for the complete positivity.
- Returns:
- cCP: bool, (shape (…,))
The (array, if broadcasted) of bools indicating if superoperator is cCP
- (D, V): Tuple[ndarray, ndarray]
The eigenvalues and eigenvectors of the projected Choi matrix (only if return_eig is True).
See also
liouville_representationCalculate Liouville representation of a unitary.
Liouville_to_choiConvert from Liouville to Choi matrix representation.
liouville_is_CPTest if a superoperator is CP.
Notes
A superoperator \(\mathcal{S}\) is conditional completely positive (cCP) if and only if its Choi matrix projected on the complement of the maximally entangled state is positive semidefinite:
\[\mathcal{S}\text{ is cCP }\Leftrightarrow Q\mathrm{choi}(\mathcal{S})Q\geq 0\]with \(Q = \mathbb{I} - |\Omega\rangle\langle\Omega|\).
- liouville_representation(U: ndarray, basis: Basis) ndarray[source]
Get the Liouville representaion of the unitary U with respect to the basis.
- Parameters:
- U: ndarray, shape (…, d, d)
The unitary.
- basis: Basis, shape (d**2, d, d)
The basis used for the representation, e.g. a Pauli basis.
- Returns:
- R: ndarray, shape (…, d**2, d**2)
The Liouville representation of U.
Notes
The Liouville representation of a unitary quantum operation \(\mathcal{U}:\rho\rightarrow U\rho U^\dagger\) is given by
\[\mathcal{U}_{ij} = \mathrm{tr}(C_i U C_j U^\dagger)\]with \(C_i\) elements of the basis spanning \(\mathbb{C}^{d\times d}\) with \(d\) the dimension of the Hilbert space.
- liouville_to_choi(superoperator: ndarray, basis: Basis) ndarray[source]
Convert from Liouville to Choi matrix representation.
- Parameters:
- superoperator: ndarray, shape (…, d**2, d**2)
The Liouville representation of a superoperator.
- basis: Basis, shape (d**2, d, d)
The operator basis defining the Liouville representation.
- Returns:
- choi: ndarray, shape (…, d**2, d**2)
The Choi matrix representation of the superoperator.
See also
liouville_representationCalculate Liouville representation of a unitary.
liouville_is_CPTest if a superoperator is completely positive (CP).
liouville_is_cCPTest if a superoperator is conditional CP.
Notes
The Choi matrix is given by
\[\begin{split}\mathrm{choi}(\mathcal{S}) &= (\mathbb{I}\otimes\mathcal{S}) (|\Omega\rangle\langle\Omega|) \\ &= \sum_{ij} E_{ij}\otimes\mathcal{S}(E_{ij}) \\ &= \sum_{ij}\mathcal{S}_{ij} C_j^T\otimes C_i\end{split}\]where \(|\Omega\rangle\) is a maximally entangled state, \(E_{ij} = |i\rangle\langle j|\), and \(C_i\) are the basis elements that define the Liouville representation \(\mathcal{S}_{ij}\) [Mer13].
References
[Mer13]Merkel, S. T. et al. Self-consistent quantum process tomography. Physical Review A - Atomic, Molecular, and Optical Physics, 87, 062119 (2013). https://doi.org/10.1103/PhysRevA.87.062119