1
$\begingroup$

I'm not sure I get what's going on here, and online resources are not helpful, at least I didn't find any helpful ones. For the problem:

$$ \frac{dy}{dt} = f(t, y(t))$$

a numerical solution for $y(t)$ can be given by:

$$y_{n+1} = y_n + h(f(t_{n+1}, y_{n+1})) $$

Where $h$ is the step size. If I want to calculate the local error of this method, I should take the difference between the numerical solution and the exact one after one step:

$$\tau = y_{n+1} - y(t_{n+1}) = y_n + h(f(t_{n+1}, y_{n+1})) - y(t_{n+1}) $$

The value $y_{n}$ is assumed to be exact, thus $y_{n} = y(t_n)$.

$\textbf{Question 1}$: How should I understand $y_{n+1} $? As I understand it, this is not a function, but the value I should calculate for an approximation of $y(t_{n+1}) $. Online I've seen people stating that we should replace the numerical solution with the exact one, so $f(t_{n+1}, y_{n+1}) = y'(t_{n+1})$. I don't see how this is justified.

$\textbf{Question 2}$: It seems $\tau$ is a function of $h$. Under the assumtion that $f(t_{n+1}, y_{n+1}) = y'(t_{n+1})$ holds, we have:

$$\tau(h) = y_{n+1} - y(t_n + h) = y_n + hy'(t_n+h) - y(t_n + h) $$

developing $\tau(h)$ around $h = 0$ (equivalently $y(t_n + h)$ around $t_n$) we get:

$$\tau(h) =y_n + h(y'(t_n) + hy''(t_n) + ...) - (y(t_n) + hy'(t_n) + \frac{h^2}2y''(t_n) + ...) $$

$$ = -\frac{h^2}2y''(t_n) + \mathcal{O}(h^3)$$

Seemingly correct. But wherever I look I get these explanations that I should develop around the point $t_{n+1}$. WHAT? $t_{n+1} = t_n + h$, depending on $h$, so that point will depend on whatever $h$ I choose. Fixing $h_0$ and running the same calculation got me into a HUGE mess, since the taylor series will change. For one, developing $\tau(h)$ around $h_0$ will give a factor of $(h - h_0)$ in front of each term.

How can I make sense of this? Can someone please walk be through this in clear way, if you are developing a function into a series, then be precise about what function it is, depending on what variable and developed around what point. I can't find a good explanation anywhere. People just write "Taylor expand around $t_{n+1}$"...

Thanks in advance.

$\endgroup$
0
$\begingroup$

The overarching idea for the computation of the global error is to consider the family of solutions to $(y^n)'=f(t,y^n)$ with initial values $y^n(t_n)=y_n$, where $(t_n,y_n)$ are the samples of the numerical integration method. This general scheme works for all one-step methods, thus also the explicit and the implicit Euler method.

Next one reduces, via Gronwall lemma, the steps $$ \|y_{N}-y(t_N)\|=\|y^N(t_N)-y^0(t_N)\|\le\sum_{n=0}^{N-1}\|y^{n+1}(t_N)-y^n(t_N)\| $$ of the global error at $t_N$ to the propagated contributions of the local error $$ \|y^{n+1}(t_N)-y^n(t_N)\|\le e^{L(t_N-t_{n+1})}\|y_{n+1}-y^n(t_{n+1})\| $$ for the explicit Euler method, or $$ \|y^{n+1}(t_N)-y^n(t_N)\|\le e^{L(t_N-t_{n})}\|y^{n+1}(t_n)-y_n\| $$ for the implicit Euler method.

This last formula is exactly the local error computation that you describe.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.