### The Hadamard gate in quantum computing overview

In this series of articles on quantum computing, we are going to learn more about the Hadamard gate, what it is and what it is used for.

**What is a Hadamard gate?**

The purpose of the Hadamard gate is to put a qubit into a state of superposition. In previous articles we had discussed what this state is and why it is useful in quantum computing. It takes the basis state |0> and maps is to a and |1> to a , resulting looks like:

Which is written as , . It is also important to remember that both the Hadamard gate and CNOT gate are considered both orthogonal and unitary, which simply boils down to rotations and flips of bits in the matrix.

**What does the Hadamard gate do?**

Simply put, as previously shown, it is used to create superpositions of a qubit. In addition, it can be combined with another unitary gate known as the CNOT gate which is used to create entanglement using two qubits. This is known as a bell circuit, which is shown here:

The ‘H’ character is the Hadamard gate. The cross looking vertical line is the CNOT gate, which operates on two qubits. Let us step through the process on just how this works:

- We start with two qubits, |0> and |0>
- The top qubit (first one) is acted on by the Hadamard gate
- This places the qubit into a superposition, which will be written as
- The qubits then pass through the CNOT gate. Remember the CNOT gate works by flipping two of the bits in the matrix, in essence it is flipping the |10> to a |11> as a result
- Now we have an entangled state written as

A quick reference:

Both gates can also work as their own inverse, which means that they can undo the operation. To do this, you would need a circuit that looks like this:

The following would be a Hadamard => CNOT => CNOT => Hadamard. This would result in the original state. In addition to this the Hadamard gate will also undo its operation with H => H.

In future articles we will consider other gates and quantum algorithms and their potential uses.