For an ODE:
$\frac{dy}{dt}=f(y(t),t)$
The Euler Explicit scheme reads:
$y_{n+1}=y_{n}+\Delta tf_n$
and it can be easily shown with a Taylor expension that:
$y_{n+1}=y_{n}+\Delta t \frac{dy}{dt}|_n+\Delta t^2 \frac{d^2y}{dt^2}|_n$
and therefore by comparing the scheme with the Taylor expansion we have:
$LTE= O(\Delta t^2)$
i.e. the local truncation error LTE for Euler explicit scales with $\Delta t^2$. Since we repeat this for $n$ times, with $n$ the number of grid points, the global truncation error is $n\Delta t^2$. Since $n=L/\Delta t$, with L the domain length, then the global truncation error scales with Δt, so Euler explicit is first order accurate. For an elliptic PDE:
$\frac{\partial^2\phi}{\partial x^2}+\frac{\partial^2\phi}{\partial y^2}=0$
if I use the central difference scheme:
$\frac{\partial^2\phi}{\partial x^2}= \frac{\phi_{i-1,j}-2\phi_{i,j}+\phi_{i+1,j}}{dx^2}+O(\Delta x^2)$
the error is second order as it can be shown by Taylor expanding $\phi_{i+1}$ and $\phi_{i-1}$ in the neighborhood of $\phi_{i}$. Similar reasoning in $y$ where:
$\frac{\partial^2\phi}{\partial y^2}= \frac{\phi_{i,j-1}-2\phi_{i,j}+\phi_{i,j+1}}{dy^2}+O(\Delta y^2)$
And here is were I am lost. The error in the derivative is second order, but what about the error in the function $\phi$ I am looking for? If I replace the discretization into the equation (let's assume $\Delta y = \Delta x$ for now) we have:
$\frac{\phi_{i,j-1}-2\phi_{i,j}+\phi_{i,j+1}}{dx^2}+ \frac{\phi_{i-$1,j}-2\phi_{i,j}+\phi_{i+1,j}}{dx^2}+2O(\Delta x^2)=0$
which, multiplying by $\Delta x^2$ reads:
$\phi_{i,j-1}-4\phi_{i,j}+\phi_{i,j+1}+ \phi_{i,i-1,j}+\phi_{i+1,j}+2O(\Delta x^4)=0$
So $O(\Delta x^4)$ shows up. From here, how can I prove that $\phi$ is obtained with second order accuracy? I guess the Local error for $\phi_{j}$ is 4th order (if all the 4 neighbours were known exactly) , but the global error is second error, I just do not know how to prove it. Any suggestion?