Vector Norms: quick explanation

Evgenia Karunus
3 min readMay 31, 2020

--

Vector norm is the magnitude (or length) of the vector.
It’s the glorified distance between two points, measured in more traditional (2-norm) and less traditional (1-norm, 3-norm, any-norm) ways.

The length of a vector is a nonnegative number that describes the extent of the vector in space, and is sometimes referred to as the vector’s magnitude or the norm.

All vector norms are described by a single formula.
Here is a formula for p-norm between points a and b (note the similarity with the Euclidean distance formula, Euclidean distance is 2-norm):

General formula for the p-norm of the vector from point a to point b.

|aₓ - bₓ| here is the absolute value of the difference between the coordinate of point a along the x-axis, and the coordinate of point b along the x-axis.
There can be as many dimensions as we’d like to (shown from x to z here).

We can calculate the distance between two points using any p-norm, however, there are multiple notable p-norms:

  • 0-norm: Hamming distance.
    Simply the number of nonzero coordinates of the ab vector.
Hamming distance
  • 1-norm: Manhattan distance, or city-block distance.
    The shortest distance a taxi cab driver would have to travel, if they were to ride on the grid-like roads of Manhattan.
Manhattan distance
  • 2-norm: Euclidean distance.
    This is what we traditionally understand as the distance between two points. That’s how space works for us!
Euclidean distance
  • ∞-norm: Chebyshev distance, or infinity distance.
    This is how a crane in the warehouse moves, - it can take one step vertically, one step horizontally, or one step both vertically and horizontally (all 3 versions are considered ‘steps’ as they take the same time). It means that we only need to know the maximum distance along one of the dimensions to know the time it will take the crane to get to its destination.
Chebyshev distance

If you prefer this in the form of the flashcards, you are welcome to use mine: memcode.com/courses/vector-norms.

Other good resources: https://www.youtube.com/watch?v=5fN2J8wYnfw.

--

--