Korean
Languages
English
Bengali
French
German
Japanese
Korean
Portuguese
Spanish
Tamil

qiskit.quantum_info.PauliList.to_labels

PauliList.to_labels(array=False)[소스]

Convert a PauliList to a list Pauli string labels.

For large PauliLists converting using the array=True kwarg will be more efficient since it allocates memory for the full Numpy array of labels in advance.

Table 3 Pauli Representations

Label

Symplectic

Matrix

"I"

\([0, 0]\)

\(\begin{bmatrix} 1 & 0 \\ 0 & 1 \end{bmatrix}\)

"X"

\([1, 0]\)

\(\begin{bmatrix} 0 & 1 \\ 1 & 0 \end{bmatrix}\)

"Y"

\([1, 1]\)

\(\begin{bmatrix} 0 & -i \\ i & 0 \end{bmatrix}\)

"Z"

\([0, 1]\)

\(\begin{bmatrix} 1 & 0 \\ 0 & -1 \end{bmatrix}\)

매개변수

array (bool) – return a Numpy array if True, otherwise return a list (Default: False).

반환

The rows of the PauliList in label form.

반환 형식

list or array