Vectors have a magnitude and direction and are essentially matrices with one column (row vectors will be described as such). They point to a position in space, and are denoted with an arrow or bolded.

Our example vector for the below definitions and examples will be , but note that vectors can have a dimension outside of .

Two important operations involving vectors are the dot product and the cross product.

Important definitions

We define the norm (where denotes a Lebesgue space) as:

The norm is called the Euclidean norm. It finds so many uses in linear algebra and other fields that it’s usually just called the norm, or the magnitude or length of the vector. The norm can be computed in NumPy with np.linalg.norm(r), MATLAB with norm(r), and PyTorch with torch.norm(r)

We define a unit vector (also base vector) of as a vector with the same direction but with a magnitude of 1.

We define a vector in whose elements are only 0 as the zero vector:

The standard vector is a unit vector with zeros in all entries except for a one in the th entry.

See also