This method is used to solve partial differential equations that result in advection, such as
\[ \frac{\partial u}{\partial t} = a \frac{\partial u}{\partial x} \]
Equations such as these are very easy to solve for (the initial condition just propagates forward/backward in time), but it is clear that finding a finite difference method to model the equation is less than trivial.
Input:
Domain in space
Domain in time
Time step
Space step
Constant \(a\) found in PDE
Boundary conditions \( \eta(x) \) at \(t_0\)
Output:
An image where space is represented vertically and time horizontally from left to right.
Usage/Example:
Output:
Notice the diffusion along the edges of the wave-front. This is due to the jump discontinuity found in the initial conditions and can be improved by adding a second-order diffusive property (as seen in the next Lax-Wendroff example).