Error norm (source code)

= Error norm

An error norm measures a numerical error <vector> or error <function> in a specified <norm>. For nodal errors $e_j=U_j-u(x_j)$ on a one-dimensional uniform grid of spacing $h$, common choices are
$$
\|e\|_\infty=\max_j|e_j|,\qquad \|e\|_{2,h}=\left(h\sum_j|e_j|^2\right)^{1/2}.
$$
The first controls the largest nodal error. The second approximates a continuum <L2 norm> on a fixed domain. For nonuniform grids, quadrature or finite-element mass weights replace the common factor $h$.

Mesh weighting matters in a refinement study. If $e_j=\varepsilon$ on $N$ cells of a unit interval with $h=1/N$, then $\|e\|_{2,h}=|\varepsilon|$, whereas the unweighted <Euclidean norm> is $\sqrt N|\varepsilon|$. The latter grows solely because the number of entries grows. Compare the same norm on the same physical domain and, for an evolution problem, at the same physical time.