This is documentation for Mathematica 8, which was
based on an earlier version of the Wolfram Language.
View current documentation (Version 11.2)

Norm

Norm[expr]
gives the norm of a number, vector or matrix.
Norm
gives the -norm.
  • For complex numbers, Norm[z] is Abs[z].
  • For matrices, Norm[m] gives the maximum singular value of m. »
Norm of a vector:
Norm of a complex number:
Norm of a vector:
In[1]:=
Click for copyable input
Out[1]=
 
Norm of a complex number:
In[1]:=
Click for copyable input
Out[1]=
is a vector of integers:
Use exact arithmetic to compute the norm:
Use approximate machine-number arithmetic:
Use 35-digit precision arithmetic:
is a SparseArray representation of :
The norm is always real even when the input is complex:
TraditionalForm formatting:
The -norm:
The -norm:
Norm of a matrix, equal to the largest singular value:
The 1-norm and -norm, respectively, for matrices:
The Frobenius norm for matrices:
Symbolic matrix norms for a real parameter :
Estimate the mean distance from the origin to random points in the unit square:
Compare to the asymptotic result:
Solve an ill-conditioned linear system with a known solution:
Get the norm of the residual:
Get the norm of the actual error:
Approximate the solution of using spatial points and time steps:
Find two solutions with fixed where the second has twice as many time steps:
Estimate the error by the norm of the difference:
Extrapolate to a better solution from the first-order convergence of the backward Euler method:
Compute a more accurate solution with NDSolve:
Compare the errors in the three solutions:
The norm of is equal to the square root of the Dot product :
is a decreasing function of :
The horizontal asymptote is the -norm, equal to Max[Abs[v]]:
The matrix 2-norm is the maximum 2-norm of for all unit vectors :
This is also equal to the largest singular value of :
The Frobenius norm is the same as the norm made up of the vector of the elements:
It is expensive to compute the 2-norm for large matrices:
If you need only an estimate, the 1-norm or -norm are very fast:
Unit balls for using 1, 2, 3, and norms:
Different norm functions:
New in 5