I was recently looking at this Wikipedia page, and specifically the section explicit method for the heat equation. To summarise, it says we can use the numerical scheme below.

We have the differential equation $$U_t=U_{xx}$$ We want to numerically approximate the points at $(x_j,t_n)$ by $u_j^n$. By expressing the derivatives as $$U_t\approx\frac{u_j^{n+1}-u_j^n}{k}\text{ and }U_{xx}\approx\frac{u_{j+1}^n-2u_j^n+u_{j-1}^n}{h^2},$$ we can rearrange to get $$u_j^{n+1}=(1-2r)u_j^n+r u_{j-1}^n+r u_{j+1}^n$$ where $r=k/h^2$

What I don't understand is why this is stable for $r\leq 1/2$ and why it would be unstable if $r>1/2$ - what causes this instability? Is it something to do with the $1-2r$ term, which we need to keep $\leq0$? If so, why?

  • $\begingroup$ You may want to look at Von Neumann stability analysis. $\endgroup$
    – Eff
    Apr 28 '17 at 15:01
  • $\begingroup$ @Eff I just read that page, and it says: For linear differential equations with periodic boundary condition, the spatial variation of error may be expanded in a finite Fourier series $$\epsilon(x)=\sum_{m=1}^M A_m(t) e^{ik_mx}.$$ I can follow all the method after this, but why is this Fourier series justified? $\endgroup$
    – John Doe
    Apr 28 '17 at 15:13
  • $\begingroup$ The expansion is a complete set and so functions can be written as a linear combination of them. $\endgroup$
    – Gregory
    Apr 28 '17 at 15:20

As Eff pointed out, Von Neumann analysis is the way to go. Suppose $u_j^n = z^n e^{i j \xi}$. Plugging this into the equation $$ z = (1-2r) + r( e^{-i \xi} + e^{i \xi}) = (1-2r) + 2r \cos \xi. $$ The stability is only if $|z| < 1$ which implies $$ -1 < r (\cos \xi - 1) < 0. $$ Note here, that $\cos \xi - 1 \le 0$ and so $$ \frac{1}{1 - \cos \xi} > r > 0. $$ Finally, we want stability for all $\xi$ and so we take the minimum for the LHS which gives $$ \frac{1}{2} > r > 0. $$

  • $\begingroup$ You used $e^{ij\xi}$ terms, whereas the Wikipedia page used $e^{\frac{i\pi j\xi}{L}}$ - I think I am missing some understanding as to why either of these can be used? $\endgroup$
    – John Doe
    Apr 28 '17 at 15:34
  • $\begingroup$ Also, this answer doesn't say anything about the case $r=1/2$, which is stable $\endgroup$
    – John Doe
    Apr 28 '17 at 15:36
  • $\begingroup$ Technically it is better practice to use the form from wiki. I was just showing the process. The result should be the same. You can also see this by noting that changing $\xi \to c \xi$ gives the same result. Additionally, stability is actually given if $|z| \le 1$. Would you like me to edit or do you understand enough to take care of it? $\endgroup$
    – Gregory
    Apr 29 '17 at 19:08
  • $\begingroup$ Ahh, yes I can understand this (no need to edit), thanks very much for your help. :) $\endgroup$
    – John Doe
    Apr 29 '17 at 19:11

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.