In my notes I have the following definition
If a numerical solution converges to the solution of PDE, then the order of convergence is $$ R = \frac{\log_2 \| \frac{e_{new}}{e_{old}}\|}{\log_2 \| \frac{\Delta x_{new}}{\Delta x_{old}} \|} $$
I'm trying to understand the notation of this formula. What do they mean by $e_{new},\Delta x_{new}, $ etc ? Take for example $v_t+v_x=0$ and suppose we approximate solution with any scheme, for example Crank-Nicolson or leapfrog. How can I compute $R$?
Best Answer
This formula assumes that for the major part, $$e=C\,(Δx)^R.$$ Then one can use the result for two different step sizes to eliminate $C$.
Note that the difference $e$ to the solution is a difference of functions, comparing the exact solution, which is a function, against the implied interpolated function of the discretized solution. This is easiest done within a finite-element framework. In the most simple example you get piecewise linear functions.
Then $\|e\|$ is a function norm. If you reduce it to the samples of the numerical solution and the corresponding samples of the exact solution, you need to compute the norm via a suitable discretization of the function space norm. In the easiest case of the supremums norm you get the maximum norm of the vector without additional factors, in the $L^p$ norms you need to replace the integral with Riemann sums.
With all this then compute