The inner product
An inner product can actually be any function that follows a few properties, but we are going to zero in on one definition of the inner product that we will use in quantum computing. Here it is:

Mathematicians use the preceding notation for the inner product, but Dirac defined it with a bra and ket, calling it a bracket:
Now, if we define a bra to be the conjugate transpose of its corresponding ket, so that if:

Then, ⟨x| is now:
We can then define a bracket as just matrix multiplication!

Pretty cool, eh? That is one of the reasons why bra-ket notation is so convenient! You should notice something else too. The bra ⟨x| is a linear functional. It will take any vector |y⟩ and give you a scalar according to the inner product formula!
Let's look at an example. Let's say |x⟩ and |y⟩ are defined this way:
