[Math] Viscous Burgers’ equation using Lax-Wendroff scheme

numerical methodspartial differential equationsviscosity-solutions

I was assigned to find a solution for the Burgers' equation

$$u_t+uu_x=\upsilon u_{xx}$$

with initial condition $u(x,0) = \sin(x)$ and with boundary conditions
$u(0,t)=u(\epsilon,t)$ with $\epsilon > 20$ fixed, using matlab/octave.

I cannot use the Lax-Wendroff scheme "as-is", so I was told to use Crank-Nicholson scheme togheter with LW to handle the viscosity. I'm a bit confused, so I wish someone could clarify how to do this.

Thanks

Best Answer

The Lax-Wendroff scheme is designed for the advection equation, so you can not apply it to advection-diffusion equations as Burgers' equation. On other hand Crank-Nicholson scheme can be applied to advection-diffusion equations. But there is a problem, to apply Crank-Nicholson scheme to a nonlinear equation you have to evaluate a nonlinear first order term implicitly. Let's take a look at the trapezoidal rule (the basis of Crank-Nicholson scheme) applied to the Burgers' equation: $$ \frac{U^{n+1}(x) - U^{n}(x)}{\Delta t} + \frac{U^{n+1}(x)U_x^{n+1}(x) + U^{n}(x)U_x^{n}(x)}{2} = \upsilon\frac{U_{xx}^{n+1}(x) + U_{xx}^{n}(x)}{2}. $$ I think you are working with the quasilinear and not with the conservative form of the Burgers' equation. Observe that in this approach we use the same quadrature rule to the first and second spatial derivatives. But you can change the integration of the nonlinear term and evaluate explicitly. Thus, $$ \frac{U^{n+1}(x) - U^{n}(x)}{\Delta t} + U^{n}(x)U_x^{n}(x) = \upsilon\frac{U_{xx}^{n+1}(x) + U_{xx}^{n}(x)}{2}. $$ Now you can discretizate the space and apply the Lax-Wendroff flux. I think you will get $$ \frac{U^{n+1}_j - U^{n}_j}{\Delta t} + U^{n}_j \frac{U^{n}_{j+1}-U^{n}_{j-1}}{2\Delta x} - (U^{n}_j)^2 \frac{\Delta t^2}{2} \frac{U^{n}_{j+1}-2U^{n}_j + U^{n}_{j-1}}{\Delta x^2} = \upsilon\frac{1}{2}\left[\frac{U^{n+1}_{j+1}-2U^{n+1}_j + U^{n+1}_{j-1}}{\Delta x^2} + \frac{U^{n}_{j+1}-2U^{n}_j + U^{n}_{j-1}}{\Delta x^2}\right]. $$ This scheme is a semi-implicit method. There is a range of other possibilities to combine the two methods (LW and CN), but I hope I've helped you.

Related Question