qiskit.quantum_info.Operator.from_label¶
- classmethod Operator.from_label(label)[소스]¶
Return a tensor product of single-qubit operators.
- 매개변수
label (string) – single-qubit operator string.
- 반환
The N-qubit operator.
- 반환 형식
- 예외 발생
QiskitError – if the label contains invalid characters, or the length of the label is larger than an explicitly specified num_qubits.
- Additional Information:
The labels correspond to the single-qubit matrices: 〈I〉: [[1, 0], [0, 1]] 〈X〉: [[0, 1], [1, 0]] 〈Y〉: [[0, -1j], [1j, 0]] 〈Z〉: [[1, 0], [0, -1]] 〈H〉: [[1, 1], [1, -1]] / sqrt(2) 〈S〉: [[1, 0], [0 , 1j]] 〈T〉: [[1, 0], [0, (1+1j) / sqrt(2)]] 〈0〉: [[1, 0], [0, 0]] 〈1〉: [[0, 0], [0, 1]] 〈+〉: [[0.5, 0.5], [0.5 , 0.5]] 〈-〈: [[0.5, -0.5], [-0.5 , 0.5]] 〈r〉: [[0.5, -0.5j], [0.5j , 0.5]] 〈l〉: [[0.5, 0.5j], [-0.5j , 0.5]]