I want to simulate the following programme on pdepe solver with third type inlet boundary of Heaviside nature with t0 = 140 days and a zero flux ourlet boundary
2 views (last 30 days)
Torsten on 5 Apr 2022
Edited: Torsten on 5 Apr 2022
pl = ul - C0 * ( 1 + exp(-2*k*t0) )/( 1 + exp(2*k*(t-t0)) );
ql = 0.0;
I suggest you plot the function
f(t) = C0 * ( 1 + exp(-2*k*t0) )/( 1 + exp(2*k*(t-t0)) )
to deduce a suitable value for k.
Are you sure about your setting for f in pdex1pde ?
Note that the flow velocity will be
v = 0.71*(1+0.2*x)
, but that this setting will generate an artificial source term
s = -0.71*0.2*u
in your model.