## Quantum Country exercise 1

This is the first in a series of posts working through the exercises in the Quantum Country online introduction to quantum computing and related topics. The exercises in the original document are not numbered; I have added my own numbers for convenience in referring to them.

Exercise 1. For the Hadamard matrix $H = \frac{1}{\sqrt{2}} \begin{bmatrix} 1 & 1 \\ 1& -1 \end{bmatrix}$, verify that $HH = I$ where $I$ is the identity matrix $\begin{bmatrix} 1 & 0 \\ 0 & 1 \end{bmatrix}$.

$HH = \frac{1}{\sqrt{2}} \begin{bmatrix} 1 & 1 \\ 1& -1 \end{bmatrix} \frac{1}{\sqrt{2}} \begin{bmatrix} 1 & 1 \\ 1& -1 \end{bmatrix}$
$= \frac{1}{2} \begin{bmatrix} 1 \cdot 1 + 1 \cdot 1 & 1 \cdot 1 + 1 \cdot (-1) \\ 1 \cdot 1 + (-1) \cdot 1 & 1 \cdot 1 + (-1) \cdot (-1) \end{bmatrix}$
$= \frac{1}{2} \begin{bmatrix} 1 + 1 & 1 - 1 \\ 1 - 1 & 1 + 1 \end{bmatrix}$
$= \frac{1}{2} \begin{bmatrix} 2 & 0 \\ 0 & 2 \end{bmatrix} = \begin{bmatrix} 1 & 0 \\ 0 & 1 \end{bmatrix} = I$
So we have shown that $HH = I$.