Hello everyone!
I've been trying to solve a 1D advection-diffusion-reaction PDE system of gas adsorption and can't really know what's going on. I've followed the approach in [1] using Crank-Nicholson for the diffusion step and FD for the reaction equation.
I've even tried to reproduce the solution for this
discussion. The riemann solver I've been using is below:
def conservative_advection_1D(q_l, q_r, aux_l, aux_r, problem_data):
num_rp = q_l.shape[1]
wave = np.empty((num_eqn, num_waves, num_rp))
s = np.empty((num_waves, num_rp))
amdq = np.zeros((num_eqn, num_rp))
apdq = np.zeros((num_eqn, num_rp))
s[0, :] = aux_l[0, :].copy()
for i in range(num_eqn):
wave[i, 0, :] = q_r[i, :] - q_l[i, :]
fmh1 = (s[0, :] >= 0) * s[0, :] * q_l[i, :]
fmh2 = (s[0, :] < 0) * s[0, :] * q_r[i, :]
fmh = fmh1 + fmh2
amdq[i, :] = fmh - s[0, :] * q_l[i, :]
apdq[i, :] = -fmh
return wave, s, amdq, apdq
Are there any other approach I can try?
[1] Tyson, R., Stern, L. G., & LeVeque, R. J. (2000). Fractional step methods applied to a chemotaxis model. Journal of mathematical biology, 41, 455-475.