0
$\begingroup$

I am solving for solute transport in 1 D.

$$\frac{\partial C}{\partial t} = D\frac{\partial ^2 C}{\partial x^2} - v\frac{\partial C}{\partial x}$$ No-flux boundary condition is imposed at both the boundaries. $$ N = D\frac{\partial C}{\partial x} - vC = 0$$

I've solved the system in MATLAB's pdepe solver. I'd like to ask for a few suggestions for interpreting the results.

The following is the solution that is obtained from the solver. There are 11 nodes and each column contains the values of solute concentration observed over time. Row 0 is at time 0 and Row 6 is at tend, endpoint of the time interval in which solution is observed.

 5.0000    5.0000    5.0000    5.0000    5.0000    5.0000    5.0000    5.0000    5.0000    5.0000    5.0000
    0.0001    0.0002    0.0009    0.0037    0.0146    0.0586    0.2344    0.9375    3.7500   15.0000   60.0001
    0.0001    0.0002    0.0009    0.0037    0.0146    0.0586    0.2344    0.9375    3.7500   15.0000   60.0001
    0.0001    0.0002    0.0009    0.0037    0.0146    0.0586    0.2344    0.9375    3.7500   15.0000   60.0001
    0.0001    0.0002    0.0009    0.0037    0.0146    0.0586    0.2344    0.9375    3.7500   15.0000   60.0001
    0.0001    0.0002    0.0009    0.0037    0.0146    0.0586    0.2344    0.9375    3.7500   15.0000   60.0001

The code used for generating the above solution is the following

function sol=so()
format short
global D v c0
m = 0;

D = 50000;
v = 10000; 
x = 0:6:60;
t = 0:0.1:50;

sol = pdepe(m,@pdefun,@icfun,@bcfun,x,t)
    function [g,f,s] = pdefun(x,t,c,DcDx)
    g = 1;
    f = D*DcDx;
    s = -v*DcDx;
    end

    function c0 = icfun(x)
    c0 = 5;
    end

function [pl,ql,pr,qr] = bcfun(xl,cl,xr,cr,t)
    pl = cl;
    ql = -1/v;
    pr = cr;
    qr = -1/v;
end
end

I observe that the concentration at the last 2 nodes( last 2 columns) are really high. Is this an expected behaviour while using no-flux boundary condition?

I'd also like to understand why this occurs. Does this happen because all the solute is convected to the end and diffusion starts occurring in the opposite direction to prevent the convective flow in the positive direction?

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.