qml.pauli.are_pauli_words_qwc¶
-
are_pauli_words_qwc
(lst_pauli_words)[source]¶ Given a list of observables assumed to be valid Pauli words, determine if they are pairwise qubit-wise commuting.
This implementation has time complexity ~ O(m * n) for m Pauli words and n wires, where n is the number of distinct wire labels used to represent the Pauli words.
- Parameters
lst_pauli_words (list[Observable]) – List of observables (assumed to be valid Pauli words).
- Returns
True if they are all qubit-wise commuting, false otherwise.
- Return type
(bool)
code/api/pennylane.pauli.are_pauli_words_qwc
Download Python script
Download Notebook
View on GitHub