# How do we find the condition?

Suppose that we are given a numerical scheme.

In order to find the CFL condition , we set $U_j^n= \lambda ^ne^{ik x_j}$ and put it into the numerical scheme.

I have shown that the given method is unstable since $|\lambda|>1$.

In this case, how do we calculate the CFL condition?

I get $| \lambda |= \sqrt{1+\gamma^2 \nu^2 \sin^2{(kh)}}$. This can't be $<1$. What do we do in this case?

The given equation is $u_t+ \gamma u_x=0, \gamma>0$. We know that $k \in \mathbb{R}, \nu=\frac{\tau}{h}$ where $\tau$ is the step of the discretization of time. EDIT: Also suppose that we have a numerical scheme , put into it $U_j^n= \lambda^n e^{ik x_j}$ and get $a_i^n \nu \leq 1$. Can we then say that the method is stable if and only if $a_i^n \nu \leq 1$ ?

• choose |\lambda|<1? – Michael Medvinsky Dec 1 '15 at 20:49
• I get $| \lambda |= \sqrt{1+\gamma^2 \nu^2 \sin^2{(kh)}}$. This can't be <1. What do we do in this case?  The given equation is $u_t+ \gamma u_x=0, \gamma>0, x \in \mathbb{R}, t \in [0,T_f]$. @MichaelMedvinsky – Mary Star Dec 1 '15 at 20:53
• Add those details to your question – nicoguaro Dec 1 '15 at 20:56
• also add what is $\nu$ and $k$ – Michael Medvinsky Dec 1 '15 at 21:06
• exactly! The central differencing scheme you use is known to be unstable. You may want to try upwind differencing: $$\frac{u_i^{n+1}-u_i^n}{\Delta t}=\gamma\frac{u_{i+1}^n-u_i^n}{\Delta x}$$ or some form of implicit methods. – nluigi Dec 1 '15 at 21:57

You assert that for your scheme to be stable you need $|λ|≤1$ which is correct, however you find that all values for $c=γν$ will give $|λ|>1$. This means that the discretization you have applied is unstable and there is no CFL condition for stability. Consider using upwind differencing or an implicit method.