Interested in learning how to program quantum computers? Then check out our Qiskit textbook Introduction to Quantum Computing with Qiskit.
Introduction
In this tutorial we will see how to construct a quantum logic gate from a unitary matrix.
In quantum computing unitary matrices are very important as they describe how quantum logic gates and circuits affect qubit states.
In Qiskit a quantum logic gate can be created from a unitary matrix using the Unitary class:
Unitary(data)
Where:
For example the Pauli X gate can be described using the following matrix: