# Norm (mathematics)

length in a vector space

In mathematics, the norm of a vector is its length. A vector is a mathematical object that has a size, called the magnitude, and a direction. For the real numbers the only norm is the absolute value. For spaces with more dimensions the norm can be any function ${\displaystyle p}$ with

1. Scales for real numbers ${\displaystyle a}$, that is ${\displaystyle p(ax)=|a|p(x)}$
2. Function of sum is less than sum of functions, that is ${\displaystyle p(x+y)\leq p(x)+p(y)}$ or the triangle inequality
3. ${\displaystyle p(x)=0}$ if and only if ${\displaystyle x=0}$.

## Definition

For a vector ${\displaystyle x}$ , the associated norm is written as ${\displaystyle ||x||_{p}}$  or L${\displaystyle p}$  where ${\displaystyle p}$  is some value. The value of the norm of ${\displaystyle x}$  with some length ${\displaystyle N}$  is as follows:

${\displaystyle ||x||_{p}={\sqrt[{p}]{x_{1}^{p}+x_{2}^{p}+...+x_{N}^{p}}}}$

The most common usage of this is the Euclidean norm, also called the standard distance formula.

## Examples

1. The one-norm is the sum of absolute values: ${\displaystyle \|x\|_{1}=|x_{1}|+|x_{2}|+...+|x_{N}|.}$  This is like finding the distance from one place on a grid to another by summing together the distances in all directions the grid goes; see Manhattan Distance
2. Euclidean norm is the sum of the squares of the values: ${\displaystyle \|x\|_{2}={\sqrt {x_{1}^{2}+x_{2}^{2}+...+x_{N}^{2}}}}$
3. Maximum norm is the maximum absolute value: ${\displaystyle \|x\|_{\infty }=\max(|x_{1}|,|x_{2}|,...,|x_{N}|)}$
4. When applied to matrices, the Euclidean norm is referred to as the Frobenius norm
5. L0 norm is the number of non-zero elements present in a vector