Skip to main content

Basic Quantum Logic Gates


 Classic NOT Gate:

The NOT gate converts bit 0 to bit 1 and bit 1 to bit 0.


 

Sigma X Gate:

The X gate, also known as the Pauli X matrix, also refers to the NOT gate.
The X matrix and the expressions |0> and |1> are as follows.

 

If we make the X gate act on the qubits |0> and |1>;

 

In general, if we write;

For example, let's draw a 2-qubit circuit;

Sigma Z Gate: 

The Pauli Z gate does not change the result when it acts on the |0> qubit. However, when it acts on the |1> qubit, it changes phase, that is, it introduces a minus sign.

If we make the Z gate act on the qubits |0> and |1>;

Sigma Y Gate: 


If we make the Y gate act on the qubits |0> and |1>;

Hadamard Gate: 

The Hadamard gate [H] is used to superposition our qubit.

If we make the H gate act on the qubits |0> and |1>;


The gates you've read so far were single qubit gates. However, the CNOT gate we will see now is used for multiple qubits.

 

CNOT (Controlled NOT) Gate:

Notation of CNOT; 


There are two states at the CNOT gate:

Case 1: If the first qubit is |0> it does nothing to the second qubit.

Case 2: If the first qubit is |1>, it modifies the second qubit. That is if the second qubit is |0> it makes |1>, if |1> makes |0>.





Reference

https://learn.qiskit.org/course/ch-states/single-qubit-gates

 

Comments

Post a Comment

Popular posts from this blog

Bloch Sphere – Geometric Representation of Quantum State

    It is very difficult to visualize quantum states before our eyes. The Bloch sphere represents quantum state functions quite well. The Bloch sphere is named after physicist Felix Bloch. As you can see in the Bloch sphere figure below, it geometrically shows the pure states of two-level quantum mechanical systems. The poles of the Bloch sphere consist of bits |0⟩ and |1⟩. Classically, the point on the sphere indicates either 0 or 1. However, from a quantum mechanics point of view, quantum bits contain possibilities to be found on the entire surface of the sphere. Traditionally, the z-axis represents the |0⟩ qubit, and the z-axis the |1⟩ qubit. When the wave function in superposition is measured, the state function collapses to one of the two poles no matter where it is on the sphere. The probability of collapsing into either pole depends on which pole the vector representing the qubit is closest to. The angle θ that the vector makes with the z-axis determines this probabilit...

Quantum Phase Estimation - Calculating an Eigenvalue

    We continue our series of fundamental and ongoing quantum algorithms. In today's post, we'll look at the eigenvalue calculation that is familiar to anyone in both the basic sciences and engineering. We will consider a slightly different situation, of course, our work is quantum. Let's consider the quantum state of a system! When we make an observation, we obtain real observation values by calculating the eigenvalues and eigenvectors of the state in that system, the mathematical calculation that helps us to have information about the position, momentum, or energy of that system. So, how can we find the eigenvalues of the unitary operators, which act on a system without changing its size, that is, preserve its physical size? To solve this problem, we will examine the Quantum Phase Estimation solution. In order to find the eigenvalues of the unit operator U, we need to find the value of the phase ϕ, which is inside the exponential value. However, it is not that easy. A qua...

Bernstein–Vazirani Algorithm

  Quantum computers currently available are not sufficient to solve every existing classical problem due to their own characteristics. This does not mean that they are inferior to classical computers, or that, on the contrary, quantum computers should give all kinds of advantages over classical computers. Popular quantum algorithms solved in quantum computers are algorithms created by taking advantage of the superposition and entanglement properties of particles. So, they are algorithms created to show the prominent features of quantum properties. Today I will talk about an enjoyable algorithm that demonstrates the efficiency and speed of these quantum features. Known as the Bernstein - Vazirani algorithm is a quantum algorithm invented by Ethan Bernstein and Umesh Vazirani in 1992. The purpose of this algorithm, which is a game, is to find a desired number. To put it more clearly, let's keep in mind a string of binary numbers, for example, 1011001. Next, let's write an algori...