Continuous system and finite cell models: A statistical comparison

Continuous system and finite cell models: A statistical comparison

Ecological Modelling, 25 (1984) 85-96 85 Elsevier Science Publishers B.V., Amsterdam - Printed in The Netherlands C O N T I N U O U S SYSTEM A N D ...

375KB Sizes 0 Downloads 55 Views

Ecological Modelling, 25 (1984) 85-96

85

Elsevier Science Publishers B.V., Amsterdam - Printed in The Netherlands

C O N T I N U O U S SYSTEM A N D FINITE CELL MODELS: A STATISTICAL C O M P A R I S O N

CHRISTOPHER G. UCHRIN and WILLIAM OLLINGER

Department of Environmental Science, Cook College, Rutgers University, P.O. Box 231, New Brunswick, NJ 08903 (U.S.A.) (Accepted for publication 7 July 1984)

ABSTRACT Uchrin, C.G. and Ollinger, W., 1984. Continuous system and finite cell models: a statistical comparison. Ecol. Modelling, 25: 85-96. Response functions to delta function inputs for plug-flow with dispersion systems and completely mixed cells-in-series systems are compared by treatment as statistical distributions. The resultant comparison of variances provided a relationship between the Peclet number for the plug flow system and the number of cells for the cells-in-series system. A comparison of the means showed that a time shift can be applied to the cells-in-series analysis to provide a closer correlation to the plug flow with dispersion system response.

INTRODUCTION

Mathematical modelers of natural ecosystems are frequently presented with the following dilemma: while it is desirable to construct a model as detailed and deterministic as possible, it is also desirable to keep the model as simple as possible, especially from a numerical point of view. Several approaches are available to the modeler, especially in relation to the definition of the spatial system. In some cases, the spatial resolution required dictates whether a continuous or a finite approach is required. A finite difference or cell approach introduces numerical dispersion which can be excessive. The modeler must ensure that the numerical dispersion is less than o r e q u a l to the n a t u r a l d i s p e r s i o n i n h e r e n t to the s y s t e m .

It can be recalled, from basic reactor design (Levenspiel, 1972), that continuous spatial system models are derivative from cell models, i.e., one begins with a completely mixed cell of infinitesimal dimensions and then shrinks the volume to zero, thus defining spatial derivatives. The resultant 0304-3800/84/$03.00

© 1984 Elsevier Science Publishers B.V.

86

continuous model equation for a one-dimensional case is commonly called a 'plug flow' system. A true plug flow system exhibits no dispersive effects in the axial direction. A dispersion term is often added to the model equation to represent real conditions in which dispersive effects are significant. Conversely, a completely mixed system exhibits infinite or total spatial dispersion. This dispersion can be reduced to finite levels by breaking up the system into a continuum of cells, or, in one dimension, a series of cells. This paper will demonstrate the intersection of these two approaches by examining each as a statistical distribution and comparing the relevant parameters, namely the mean and variance. MODEL

EQUATIONS

A schematic for a system of n cells of equal volume in series is displayed in Fig. 1. A mass balance equation around the ith cell can be formulated as

TABLE I Nomenclature A C C D M m n

Q Pe R F S t t* t"

i U v X

= = = = = = = = = = = = = = = = = = =

C r o s s s e c t i o n a l a r e a (L 2) C o n c e n t r a t i o n ( M / L 3) R e f e r e n c e c o n c e n t r a t i o n ( M / L 3) Dispersion coefficient (L2/T) Input mass (M) Moment (subscript dependent) N u m b e r o f cells ( d i m e n s i o n l e s s ) V o l u m e t r i c flow rate ( L 3 / T ) Peclet n u m b e r ( d i m e n s i o n l e s s ) Transfer function (dimensionless) R e a c t i o n rate ( M / L 3 - T ) V a r i a n c e ( T 2) T i m e (T) R e s i d e n c e t i m e (T) Dimensionless time M e a n t i m e (T) A v e r a g e velocity in x d i r e c t i o n ( L / T ) V o l u m e (L 3) d i s t a n c e (L)

Fig. 1. Cells in series s y s t e m s c h e m a t i c .

87 (for nomenclature see Table I): V

1 d

QCi_ 1 - QC i + --r = : -n ndt

(1)

(VC,)

where Q is the volumetric flow rate (L3/T); C is the concentration of a substance in the subscripted segment ( M / L 3 ) ; V is the total volume of the n-cell system (L3); and r is the rate of change of the substance due to some reaction (M/(L3T)), equal to zero for conservative tracers. For systems of conservative substances with a constant volumetric flow rate, Equation 1 reduces to:

dC

n (C~_,- C~)t* dt

(2)

where t* is the system detention time (T), equal to the system volume divided by the volumetric flow rate, V / Q . Boundary conditions can be formulated as: Ci = O @ t = t o,

(3)

i4=0

and Ci = C o @ t = t o,

(4)

i=0

A schematic for a plug flow system is displayed in Fig. 2. Assuming infinite radial dispersion, a mass balance equation for this system including axial dispersion can be written as:

(DSC) 8x -sx

8N~

(UC)+-r=87

8c

(5)

where D is the axial dispersion coefficient ( L 2 / T ) ; and U is the average velocity in the x direction ( L / T ) . For a conservative substance and constant velocity and dispersion, Equation 5 simplifies to: D

82C 6x 2

- U

8C 8x

8C

- --

(6)

8t

The following boundary conditions can be established: C=Co@X

= 0

O

Fig. 2. Plug flow with dispersion system schematic.

(7)

k

88 and 0 < C< ~@x--* +~

(8)

From a mathematical standpoint, the relative simplicity of the cells in series system is apparent. This simplicity is even more manifest in working with three-dimensional systems where the cell approach still yields first-order, ordinary differential equations (Thomann, 1974), whereas the continuous approach results in a second-order, partial differential equation with four independent variables. The advantage of the continuous approach is that it is more deterministically representative of the real system. The resultant equation(s), however, may only be solvable by employing an appropriate numerical solution technique, thus effectually returning to a cellular approach. This consideration is important when dealing with heterogeneous systems such as s o l u t e / s o l v e n t / a d s o r b e r interactions in surface water (Weber et al., 1980) and groundwater (Uchrin, 1983) systems. The complexity of the reaction term describing these systems usually results in non-linear equation systems, necessitating numerical solutions. MODEL RESPONSES

Several input functions are generally used to assess model response characteristics including spike, step, ramp, and sinusoidal functions. A spike function, mathematically defined as a delta function, 8(t - to), was used for this analysis. The delta function has the following properties: (1)

8(t-to)=O,

t4~t o

(9)

(2)

6(t-t0)=m,

t=t o

(10)

(3) f] a(t- t0) dt= 1

(11)

(4) ~ a ( t -

(12)

to) dt-- 1

Using the delta function as an initial condition to the first cell, a series of first-order, ordinary differential equations is set up which can be solved in a straightforward manner using Laplace transforms. The solution for the n th cell is given by: c. -

M

n"

v ( . - 1)!

(t/t*)'"

l'e'

"'/'*'

(13)

where M is the mass of the spiked substance (M) and t * ( = V / Q ) is the system residence or detention time (T). Using the delta function as an initial condition for a plug flow with dispersion system at the position x = 0 yields

89

the following solution:

C- 2A(rrDt)l/2

(14)

-4L)t

where A is the cross sectional area of the system. STATISTICAL COMPARISON

The response function for each system (Equations 13 and 14) can be compared on the basis of two commonly used statistical parameters: the mean and variance. The i th moment, m,, of a frequency distribution function, f ( t ) , can be expressed as: m I=f

t'f(t) dt

(15)

The mean, t, can thus be defined as: (16)

t= ml/m 0

and the variance, s 2, as: s2=(m2--mo)--(ml--mo)

2

(17)

A dimensionless transfer function, system as:

R(t'),

can be defined for cells in series

R( t') -- C(out)/C(in)

(18)

where C(out) is the concentration of a substance leaving the system and C(in) the concentration entering the system and t' is dimensionless time, given by:

t'= t/t*

(19)

The transfer function can further be normalized: oo

f_ R(t'ldt'=l=mo

(20)

oo

Employing the definition of the Laplace transform: oo

5~= f_ e-'"R(t') dt'

(21)

oo

and denoting (5~') as ( d ~ / d s ) lim ~ ' = - m I

yields: (22)

s~0

and lim ~ " = m 2 s--+0

(23)

90 Substituting into Equation 17 yields: i= -lim~'

(24)

s-+0

and, s 2= lim ~ " - ( s--~0

lim ~ ' / 2 \ s ---* 0

(25)

/

Applying Equations 24 and 25 to the cells in series system and dedimensionalizing yields: i= 1

(26)

and (27)

s 2 = 1/n

A dimensionless transfer function, R, for the plug flow with dispersion system can be defined as:

(28)

R = C/C*

where C* is some unit or reference concentration. Equation 6 can then be written in dimensionless form as: 82R ---Pe 8x '2

8R

8R =Pe-6x' St'

(29)

where t' is dimensionless time, given by t/t*; t* is, as before, the system detention (travel) time, given by V / Q or L / U (T); L is the length of the system (L); x' is dimensionless distance, given by x / L ; and Pe is the Peclet number, given by U L / D (dimensionless). Equation 14, the solution to Equation 6 for a delta function input, can likewise be expressed in dimensionless form as: =

-47rt'

exp

4t'

(30)

where C* is given as M / L A . Van der Laan (1958) expressed the Laplace transform of the transfer function as: 8 = 12q e(q+ '2Pe)

(31)

where q is given by [(s/Pe) + (1/4)] 1/2. Van der Laan further showed that differentiating Equation 31 and appropriately substituting into Equations 24 and 25 yields the following expressions for mean and variance in plug flow with dispersion systems: i = 1 + 2/Pe

(32)

91

and S 2 =

(33)

2/Pe + 8/Pe 2

Several interesting characteristics are apparent. Attempting to equate the means for both systems (Equations 26 and 32) is unsuccessful as an inequality results that can only be resolved as the Peclet number approaches infinity. Thus, a perfect correlation between the cells in series system and the plug flow with dispersion system is impossible for systems with finite Peclet numbers. This further translates into systems with dispersion coefficients greater than zero. However, as the Peclet number increases, the correspondence of the means gets better. Comparison of the respective variances (Equations 27 and 33) is more fruitful and results in the expression: (34)

2/Pe + 8/Pe 2 = 1/n

It is interesting to note that the point of convergence for the means, i.e., P e ~ ~ , is only obtained if n ~ m. This is to be expected, as the derivation

of a true, dispersionless, plug flow system requires that the completely mixed control volume be shrunk to infinitesimal size, thus requiring an infinite number of cells. MODEL RESULTS

Comparisons of the two modeling approaches are displayed in Figures 3-8 for 1, 2, 5, 10, 20, and 40 cells in series and corresponding Peclet

PFD 1.0

o 0

....

i 0.5

I 1.0

J 1.5

I 2.0

CIS

i 2.5

t-3.0

t'

Fig. 3. Comparison of continuous (PFD) vs. segment (CIS) system model responses to a spike input (n = 1 ; Pe = 4).

92

PFD ---~ CIS

1.0 R /

/ 0

1.O

i

t'

I

2.0

i

3

Fig. 4. C o m p a r i s o n of continuous ( P F D ) vs. segment (CIS) system model responses to a spike i n p u t (n = 2; Pe = 6.472).

1.O

PFD .... CIS

/~ " / ~ /

R

,//~ //

o

O

[

1.O

t'

2.0

;__

I

3.O

Fig. 5. C o m p a r i s o n of continuous ( P F D ) vs. segment (CIS) system model responses to a spike input (n = 5; Pe =13.06).

t R1,0

° ~ ~

- PFD .... CIS

1.0

2,0

3.0

t'

Fig. 6. C o m p a r i s o n of continuous ( P F D ) vs. segment (CIS) system model responses to a spike input (n = 1 0 ; Pe = 23.42).

2.0-

93

i••

~/

R 1.O

0

PFD \\

....

CIS

o/t 0

1.0

2,0 t'

Fig. 7. C o m p a r i s o n o f c o n t i n u o u s ( P F D ) vs. s e g m e n t (CIS) s y s t e m m o d e l r e s p o n s e s to a s p i k e i n p u t ( n = 20; Pe = 43.66).

2.0

PFD

....

CIS

1.0

0~

o

1.o

2 .o

t'

Fig. 8. C o m p a r i s o n of continuous ( P F D ) vs. segment (C1S) system model responses to a spike i n p u t ( n = 40; Pe = 83.82).

94

numbers of 4.000, 6.472, 13.06, 23.42, 43.66, and 83.92. As expected, the two models approach each other as both n and Pe increase. This corresponds to the system tending towards more plug flow-like behavior. An interesting effect is the migration of the maxima, or mode, as n and Pe decrease. This is also mathematically true of the mean time as the mean for the cells in series system is fixed at t/t* = 1, while for the continuous system, the mean is an inverse function of the Peclet number. Thus, for an improved correlation of the two models, a time shift can be incorporated into the cells in series model. This can be accomplished by adding 2/Pe to the dimensionless time terms (t/t* in Equation 13. Figures 9-11 display the improved model

PFD

1.0

. . . .

CIS

°~°

0

1.0

2.0

3.0

t'

Fig. 9. Comparison of continuous (PFD) vs. segment (CIS) system model responses incorporating time shift to a spike input (n = 2).

PFD 1.0

.

-----,

ClS

"

0 0

1.0

2.0

I 3.0

t'

Fig. 10. Comparison of continuous (PFD) vs. segment (CIS) system model • responses incorporating time shift to a spike input (n ~ 5).

95

~

,.o

PFD

/,:

0

---.

1.0

2.0

3.0

t'

Fig. l h Comparison of continuous (PFD) vs. segment (CIS) system model responses incorporating time shift to a spike input (n = 10).

correlations for n = 2, 5, and 10, and the corresponding continuous system model traces. SUMMARY

Although a continuous system model in three dimensions offers a more spatially realistic representation of ecological systems, it is often desirable to simplify a model for the sake of reducing mathematical complexity. This is especially true when it is anticipated that the reaction terms may be non-linear. This paper demonstrated a method for relating the numerical dispersion inherent in the simple cells-in-series model to the actual dispersion in a continuous system model. This was accomplished by treating the response functions to a delta function input as a statistical distribution for both model systems. The resultant comparison of the variances provided a relationship between the Peclet number for the continuous system and the number of cells for the cells-in-series system. A comparison of the means showed that a time shift can be applied to the cells-in-series system to provide an even closer correlation between the two approaches. It is also possible that this approach can be used by modelers using finer scale finite difference techniques for integrating the spatial derivatives to obtain quick estimates of the numerical dispersion induced by the spatial step size. ACKNOWLEDGEMENTS

The authors would like to thank Dr. Robert C. Ahlert for his encouragement and suggestions throughout this effort. The work described herein was

96 s u p p o r t e d in p a r t b y the N e w Jersey A g r i c u l t u r a l P u b l i c a t i o n N o . D-07524-1-84.

Experiment

Station,

REFERENCES Levenspiel, O., 1972. Chemical Reaction Engineering (2nd Edition). Wiley, NY, 578 pp. Thomann, R.V., 1974. Systems Analysis and Water Quality Management. McGraw-Hill, New York, NY, 286 pp. Uchrin, C.G., 1984. Modeling transport processes and differential accumulation of persistent toxic organic substances in groundwater systems. In: S.E. Jorgensen (Editor), Modelling the Fate and Effect of Toxic Substances in the Environment. Proc. Symp. 6-10 June 1983, Copenhagen. Ecol. Modelling, 22: 135-143. Reprinted in Developments in Environmental Modelling, 6. Elsevier, Amsterdam/Oxford/New York/Tokyo. Van der Laan, E.Th., 1958. Letter to Editor. Chem. Eng. Sci., 7: 187-189. Weber, W.J., Jr., Sherrill, J.D., Pirbazari, M., Uchrin, C.G. and Lo, T.Y., 1980. Transport and differential accumulation of toxic substances in river-harbor-lake systems. In: R.A. Haque (Editor), Exposure and Hazard Assessment of Toxic Chemicals. Ann Arbor Science, Ann Arbor, MI, pp. 191-213.