qiskit.quantum_info.DensityMatrix.purity¶ DensityMatrix.purity()[Quellcode]¶ Return the purity of the quantum state.