Vector Norm Calculator
Enter the components of an n-dimensional vector to compute its L2 (Euclidean), L1 (Manhattan), and L∞ (maximum) norms plus the unit vector.
Input
Enter each component of the vector. Separate them with commas, spaces, or new lines (e.g. 3, 4, 12).
Result
L2 norm (magnitude)
13
L1 norm
19
L∞ norm
12
Dimension
3
Components and unit vector
| Index | Component | Unit vector |
|---|---|---|
| 1 | 3 | 0.2308 |
| 2 | 4 | 0.3077 |
| 3 | 12 | 0.9231 |
How it works
- The L2 norm (Euclidean norm) is the square root of the sum of squared components, √(Σxᵢ²). It equals the straight-line distance from the origin to the tip of the vector (the vector's magnitude).
- The L1 norm (Manhattan norm) is the sum of the absolute values of the components, Σ|xᵢ|, corresponding to distance traveled along a grid.
- The L∞ norm (maximum norm) is the largest absolute value among the components, max|xᵢ|.
- The unit vector is obtained by dividing each component by the L2 norm; it points in the same direction but has magnitude 1. A zero vector (all components 0) has an L2 norm of 0, so its unit vector is undefined.
- Components may be separated by commas, spaces, or new lines, and the number of components entered becomes the dimension.
Reviews
Tell us what you think of this calculator.
Write a review
- Home
Vector Norm Calculator