Está en la página 1de 5

ONE DIMENSIONAL ADVECTION & DIFFUSION NUMERICAL MODELLING IN CALCULATING THE

CHANGE OF POLLUTANT CONCENTRATION


Intan Trilestari
Faculty of Earth Sciences and Technology, Institute of Technology, Bandung, Indonesia
intan.t@students.itb.ac.id
Given a 3000m long canal with a source of pollutant located 500m from upstream. The concentration of the pollutant is
50 ppm. The stream of the canal flowing from the west to the east with current velocity of 0.5 m/s. Calculate the
pollutant concentration change based on time and space for 1200s with grid spacing of 20m if the source only produce
the pollutant once and if the source is continuously producing pollutant of 0.001 ppm/s. The case is illlustrated below as
Figure 1.

Figure 1. Case Illustration

Numerical method can be used to understand the change of concentration of a pollutant with respect to advection and
diffusion factors. Advection is the transport of a substance. Meanwhile diffusion is a movement of a substance from a
highly concentrated area to a low concentrated area. We can define the concentration of the pollutant as the equation
below :

F
F
2 F
=u
+ 2
t

x
Where F is the concentration of the pollutant,
and

x is space. The

discreted as the

u is the current velocity, is the diffusion coefficient, t is time,


previous equation can be
equation below :

Based on Equation 2, the time has to be solved by forward difference method, the advection can be solved by both
backward and forward difference method and the diffusion has to be solved by central difference method. The time step
has to be defined first. In defining the time step, there are two criteria that have to be followed in order to get stable
result. Those critera are shown as the equations below :

The purpose of this assignment is to produce a model which able to show the change of pollutant concentration in time
and space. By the mean of change in time and space, it will be related to advection and diffusion. In producing the
model, the calculation is made using MatlabR2008. The given parameters will be the input of the calculation. The
process of coding will be shown on the attachment section.
The result of the calculation is shown on the graphic below. Figure 2 shows graphs of pollutant change for the first case
in which pollutant only dropped once and Figure 3 is for the second case which pollutant is continuously being
produced for 0.001 ppm/s.

Figure 2 Case One in which pollutant only dropped once

Figure 3 Case Two in which pollutant continuously dropped


every second

Based on both figures we can see that both case have similar result in pollutant change based on time and space. It is
because the addition of pollutant which continuously produced is very small that it only gives minor impact to the
pollutant change in comparison to case one. Besides the similarity, both figures show that the concentration of pollutant
is decreasing in space and time.
By doing the calculation, a model which represents this phenomena is also created. On this assignment, the change of
concentration of the pollutant is due to advection and diffusion. Still and all, the factors which affect this phenomena are
not only the advection and the diffusion.

START

Input Parameters :
L=3000;dx=20;u=0.5;t=200;d
t=1;D=50

i=1,mmax

Initial condition :
F(i,1)=0

j=2,nmax-1

Variable Transfer

j=2,nmax-1

END
F(m,n) = F(m-1,i ) * (1abs(u)*dt/dx- 2*D*dt/dx^2) +
F(m-1,i-1)*(dt*(u+abs(u))/
(2*dx) + D*dt/dx^2)
Figure 4 Flowchart of Coding Process in Matlab

Boundary Condition:
F(mmax,n) = F(mmin,n) = 0;
Case one F(1,500) = 50; Case two F(:,500) =
+0.001

clear all; close all; clc;


%%
% Input Parameter
L=3000;
dx=20;
u=0.5;
t=200;
dt=1;
D=50;
% X-axis with dx 20 m
Xs=[0:20:3000];
X=Xs';
% Y-axis with 1200s
ts=[0:1:1200];
t=ts';
% Initial Condition
for i=1:length(X);
F(i,1)=0;
end
% Pollutant Input
F(26,1)=50;
%% CASE ONE
for i=2:length(t)
for m=2:length(X)-1
F(m,i)=F(m,i-1)-((u*dt/dx)*(F(m,i-1)-F(m-1,i-1)))+(((D*dt/(dx^2))*(F(m1,i-1)-(2*F(m,i-1))+F(m+1,i-1))));
end
end
% Pollutant Concentrations
F0=F(:,1);
F200=F(:,201);
F400=F(:,401);
F600=F(:,601);
F800=F(:,801);
F1000=F(:,1001);
F1200=F(:,1201);
figure
plot(X,F0,'y',X,F200,'m
',X,F400,'c',X,F600,'r',X,F800,'k',X,F1000,'g',X,F1200,'b')
legend('t=0','t=200','t=400','t=600','t=800','t=1000','t=1200','Location','north
east')
xlabel('Canal Length(m)');
ylabel('Pollutant Concentration (ppm)');
title('CASE ONE');
%% CASE TWO
% Initial Condition
for i=1:length(X);
F2(i,1)=0;
end

% Pollutant Input
F2(26,1)=50;
for i=2:length(t)
for m=2:length(X)-1
F2(26,i)=F2(26,i-1)-((u*dt/dx)*(F2(26,i-1)-F2(26-1,i-1)))+(((D*dt/
(dx^2))*(F2(26-1,i-1)-(2*F2(26,i-1))+F2(26+1,i-1))))+0.001;
% +0.001 ppm in x=500m
F2(m,i)=F2(m,i-1)-((u*dt/dx)*(F2(m,i-1)-F2(m-1,i-1)))+(((D*dt/
(dx^2))*(F2(m-1,i-1)-(2*F2(m,i-1))+F2(m+1,i-1))));
end
end
% Pollutant Concentrations
F2_0=F2(:,1);
F2_200=F(:,201);
F2_400=F(:,401);
F2_600=F(:,601);
F2_800=F(:,801);
F2_1000=F(:,1001);
F2_1200=F(:,1201);
figure
plot(X,F2_0,'y',X,F2_200,'m
',X,F2_400,'c',X,F2_600,'r',X,F2_800,'k',X,F2_1000,'g',X,F2_1200,'b')
legend('t=0','t=200','t=400','t=600','t=800','t=1000','t=1200','Location','north
east');
xlabel('Canal Length(m)');
ylabel('Pollutant Concentration (ppm)');
title('CASE TWO');

También podría gustarte