Vectors & Vector Spaces 101, for Quantum Computing

If your a classical developer you will have a basis in maths of some form in any case. To become a quantum developer you have to either refresh your knowledge or get back to learning some linear algebra. We start with some vectors and vector spaces.

To Vectors We Go

The vector is one of the most important mathematical quantities in quantum computing. It has both direction and magnitude. Consider below we have a vector V with x and y components,

\begin{equation*} V = \begin{pmatrix} 3 \\ 5 \end{pmatrix} \end{equation*}

Visually this is 3 units along the x-axis and 5 units along the y-axis pointing in a direction no matter where its tail starts.

In Quantum Computing , vectors are used to show a particular quantum state. These are called state vectors and are visualised using a Bloch Sphere.

The Bloch Sphere ( a.k.a The Unity Sphere )

The Block Sphere contains all the possible points, the state space, that represent a quantum state to which our state vectors can point. The red vector below for example |y> corresponds to a superposition between |0> and \1> . Imagine the red vector below being able to move and point to any point inside the sphere, representing a different quantum state essentially.

Quantum States And The Bloch Sphere | Quantum Untangled

A 3 minute video on the Block Sphere …

The Vector Space

A vector is an element of a vector space. A vector space is a set of objects where 2 conditions hold.

The first condition is that a Vector addition of 2 vectors with real numbers in the vector space V produces a 3rd vector with real numbers in the vector space V

\begin{equation*} \begin{pmatrix} x_1 \\ y_1 \end{pmatrix} + \begin{pmatrix} x_2 \\ y_2 \end{pmatrix} = \begin{pmatrix} x_1 + x_2 \\ y_1 + y_2 \end{pmatrix} \end{equation*}

The second condition says that the scalar multiplication of a real number vector and some real number value n, is also in the vector space, for all n contained in the real number set.

\begin{equation*} \left\lvert \begin{matrix} n|v \\ \end{matrix} \right\rangle = \begin{pmatrix} nx \\ ny \end{pmatrix} \in V \\ \forall n \in \mathbb{R} \end{equation*}

If you have come this far, your doing well. That’s all for now. Next up, Matrices and Matrix Operations !

Author: Andrew Penrose

IBM STSM, AI Applications Member, IBM Academy of Technology. IBM Master Inventor.