<SYSTEM_TASK:>
Given the following text description, write Python code to implement the functionality described below step by step
<END_TASK>
<USER_TASK:>
Description:
 Advection (conservative form)
Scalar advection problem in conservative form with  variable velocity field.
There are four Riemann solvers that can be tried out here, all described in 
LeVeque (Cambridge Press, 2002)
rp-solver=1 
Step1:  Or, run code in parallel mode (command may need to be customized, depending your on MPI installation.)
Step2:  Create PNG files for web-browser viewing, or animation.
Step3:  View PNG files in browser, using URL above, or create an animation of all PNG files, using code below.
<ASSISTANT_TASK:>
Python Code:
!swirlcons --user:example=2 --user:rp-solver=4
Explanation: Advection (conservative form)
Scalar advection problem in conservative form with  variable velocity field.
There are four Riemann solvers that can be tried out here, all described in 
LeVeque (Cambridge Press, 2002)
rp-solver=1 : Q-star approach in which a $q^*$ value is defined to enforce flux  continuity across the stationery wave. 
rp-solver=2 : Wave-decomposition approach based on solving the Riemann problem for system of two equations.
rp-solver=3 : Edge centered velocities are used to construct classic update based on flux formulation
rp=sovler=4 : F-wave approach.
Two examples are avaible.  In Example 1, the velocity field $u(x)$ is positive. In Example 2, the velocity field changes sign.  Both velocity fields have non-zero
divergence.
Run code in serial mode (will work, even if code is compiled with MPI)
End of explanation
#!mpirun -n 4 swirlcons
Explanation: Or, run code in parallel mode (command may need to be customized, depending your on MPI installation.)
End of explanation
%run make_plots.py
Explanation: Create PNG files for web-browser viewing, or animation.
End of explanation
%pylab inline
import glob
from matplotlib import image
from clawpack.visclaw.JSAnimation import IPython_display
from matplotlib import animation
figno = 0
fname = '_plots/*fig' + str(figno) + '.png'
filenames=sorted(glob.glob(fname))
fig = plt.figure()
im = plt.imshow(image.imread(filenames[0]))
def init():
    im.set_data(image.imread(filenames[0]))
    return im,
def animate(i):
    image_i=image.imread(filenames[i])
    im.set_data(image_i)
    return im,
animation.FuncAnimation(fig, animate, init_func=init,
                              frames=len(filenames), interval=500, blit=True)
Explanation: View PNG files in browser, using URL above, or create an animation of all PNG files, using code below.
End of explanation
<END_TASK>