You are on page 1of 43

Process Dynamics and Control

Chapter 2

Mathematical Modeling of
Chemical Processes

07/25/20 CAB3014 - Chemical Process Dynamics and Control 1


Chapter Objectives
Process Dynamics and Control

End of this chapter, you should be able to:


1. Develop unsteady-state models (dynamic models) of
chemical processes from physical and chemical principles
2. Explain the rationale for dynamic models
3. Explain a general strategy for deriving dynamic models
4. Carry out simulation studies (Solution of the dynamic
models that consist of sets of ODE’s and AE’s)

07/25/20 CAB3014 - Chemical Process Dynamics and Control 2


Mathematical Model (Eykhoff, 1974)
Process Dynamics and Control

• “a representation of the essential aspects of an


existing system (or a system to be constructed)
which represents knowledge of that system in a
usable form”

• Everything should be made as simple as possible,


but no simpler

07/25/20 CAB3014 - Chemical Process Dynamics and Control 3


Uses of mathematical models
Process Dynamics and Control

Design:
• Exploring the sizing and arrangement of processing
equipment for dynamic performance
• Studying the interactions of various parts of the
process, particularly when material recycle or heat
integration is used
• Evaluating alternate process and control structures
and strategies
• Simulating start-up, shutdown, and emergency
simulations and procedures.

07/25/20 CAB3014 - Chemical Process Dynamics and Control 4


Uses of mathematical models
Process Dynamics and Control

Plant operation:
• Troubleshooting and processing problems
• Aiding in start-up and operator training
• Studying the effects of and the requirements for
expansion (bottle-neck removal) projects
• Optimizing plant operation
• It is usually much cheaper, safer, and faster to
conduct the kinds of studies listed above on a
mathematical model than experimentally on an
operating unit.

07/25/20 CAB3014 - Chemical Process Dynamics and Control 5


Principles of Model Formulation
Process Dynamics and Control

• The model equations are at best an


approximation to the real process.
• Adage: “All models are wrong, but some are
useful”
• Inherently involves a compromise between
– model accuracy and complexity
– the and effort required to develop the
model

07/25/20 CAB3014 - Chemical Process Dynamics and Control 6


Process modeling
Process Dynamics and Control

• Both an art and a science.


• Requires creativity to make simplifying
assumptions that result in an appropriate
model
• Dynamic models of chemical processes
consist of ODEs and/or PDEs, plus related
algebraic equations

07/25/20 CAB3014 - Chemical Process Dynamics and Control 7


A Systematic Approach for Developing
Dynamic Models
Process Dynamics and Control

1. State the modeling objectives and the end use of


the model. They determine the required levels of
model detail and model accuracy.
2. Draw a schematic diagram of the process and label
all process variables.
3. List all of the assumptions that are involved in
developing the model. Try for parsimony; the
model should be no more complicated than
necessary to meet the modeling objectives.

07/25/20 CAB3014 - Chemical Process Dynamics and Control 8


Systematic Approach
Process Dynamics and Control

4. Determine whether spatial variations of process


variables are important. If so, a partial differential
equation model will be required.
5. Write appropriate conservation equations (mass,
component, energy, and so forth).
6. Introduce equilibrium relations and other algebraic
equations (from thermodynamics, transport
phenomena, chemical kinetics, equipment
geometry, etc.).

07/25/20 CAB3014 - Chemical Process Dynamics and Control 9


A Systematic Approach…
Process Dynamics and Control

6. Perform a degrees of freedom analysis (Section


2.3) to ensure that the model equations can be
solved.
7. Simplify the model.
• Arrange the equations so that the dependent
variables (outputs) appear on the left side and
the independent variables (inputs) appear on
the right side.
• This model form is convenient for computer
simulation and subsequent analysis.
8. Classify inputs as disturbance variables or as
manipulated variables.

07/25/20 CAB3014 - Chemical Process Dynamics and Control 10


Modeling Approaches
Process Dynamics and Control

Physical/chemical (fundamental, global)


• Model structure by theoretical analysis
–Material/energy balances
–Heat, mass, and momentum transfer
–Thermodynamics, chemical kinetics
–Physical property relationships
• Model complexity must be determined (assumptions)
• Can be computationally expensive (not real-time)
• May be expensive/time-consuming to obtain
• Good for extrapolation, scale-up
• Does not require experimental data to obtain (data
required for validation and fitting)
• Theoretical models of chemical processes are based on
conservation laws.

07/25/20 CAB3014 - Chemical Process Dynamics and Control 11


Mass Balance
Process Dynamics and Control

Conservation of Mass

 rate of mass  rate of mass  rate of mass 


    (2-6)
accumulation   in   out  (2.1)

Conservation of Component i

(2.2)

07/25/20 CAB3014 - Chemical Process Dynamics and Control 12


Energy Balance
Process Dynamics and Control

Conservation of Energy

(2.3)

07/25/20 CAB3014 - Chemical Process Dynamics and Control 13


Energy Balance …
Process Dynamics and Control

• Total energy of a system, Utot

(2.4)

• For the processes and examples considered in


this course, it is appropriate to make two
assumptions:
– Changes in potential energy and kinetic
energy can be neglected
– The net rate of work can be neglected

07/25/20 CAB3014 - Chemical Process Dynamics and Control 14


Energy Balance …
Process Dynamics and Control

• For these reasonable assumptions, the energy balance in Eq.


2-3 can be written as

(2.5)

U int  the internal energy of   denotes the difference


between outlet and inlet
the system conditions of the flowing

H  enthalpy per unit mass streams; therefore

w  mass flow rate  
-Δ wH = rate of enthalpy of the inlet
Q  rate of heat transfer to the system stream(s) - the enthalpy
of the outlet stream(s)

07/25/20 CAB3014 - Chemical Process Dynamics and Control 15


Black box (empirical)
Process Dynamics and Control

– Large number of unknown parameters


– Can be obtained quickly (e.g., linear
regression)
– Model structure is subjective
– Dangerous to extrapolate

07/25/20 CAB3014 - Chemical Process Dynamics and Control 16


Semi-empirical
Process Dynamics and Control

 • Compromise of first two approaches


• Model structure may be simpler
• Typically 2 to 10 physical parameters estimated
(nonlinear regression)
• Good versatility, can be extrapolated
• Can be run in real-time
• linear regression y  c0  c1 x  c 2 x 2

• nonlinear regression y  K 1  e 
 t /

07/25/20 CAB3014 - Chemical Process Dynamics and Control 17


Semi-empirical
Process Dynamics and Control

• Number of parameters affects accuracy of model,


but confidence limits on the parameters fitted must
be evaluated.
• Objective function for data fitting – minimize sum of
squares of errors between data points and model
predictions (use optimization code to fit parameters)
• Nonlinear models such as neural nets are becoming
popular (automatic modeling)

07/25/20 CAB3014 - Chemical Process Dynamics and Control 18


Development of Dynamic Models
Process Dynamics and Control

Illustrative Example: A Blending Process

An unsteady-state mass balance for the blending system:

(2.1)

or
(2.6)

where w1, w2, and w are mass flow rates.


07/25/20 CAB3014 - Chemical Process Dynamics and Control 19
Blending Process
Process Dynamics and Control

The unsteady-state component balance is:

(2.7)

The corresponding steady-state model was derived in


Ch. 1 (cf. Eqs. 1-1 and 1-2).

(2.8)

07/25/20 CAB3014 - Chemical Process Dynamics and Control 20


The Blending Process Revisited
Process Dynamics and Control

For constant ρ, Eqs. 2-6 and 2-7 become:


(2.9)

(2.10)

Equation 2-10 can be simplified by expanding the


accumulation term using the “chain rule” for
differentiation of a product:
(2.11)

Substitution of (2-11) into (2-10) gives:


(2.12)

07/25/20 CAB3014 - Chemical Process Dynamics and Control 21


Blending Process Revisited …
Process Dynamics and Control

Substitution of the mass balance in (2-9) for in (2-12) gives:

(2.13)

After canceling common terms and rearranging (2-9) and


(2-13), a more convenient model form is obtained:

(2.14)

(2.15)

07/25/20 CAB3014 - Chemical Process Dynamics and Control 22


Blending Process Revisited …
Process Dynamics and Control

• The dynamic model in Eqs. 2-14 and 2-15 is in a


convenient form for subsequent investigation based on
analytical or numerical techniques

• Specify the inlet compositions (x1 and x2) and the flow
rates (w1, w2 and w) as functions of time

• Specify the initial conditions for the dependent variables,


V(0) and x(0)
• Determine the transient responses, V(t) and x(t)

07/25/20 CAB3014 - Chemical Process Dynamics and Control 23


Process Dynamics and Control
Blending Process Revisited …

07/25/20 CAB3014 - Chemical Process Dynamics and Control 24


Dynamic models of representative
processes
Process Dynamics and Control

• Stirred-Tank Heating Process

Figure 2.3 Stirred-tank heating process with constant holdup, V.

07/25/20 CAB3014 - Chemical Process Dynamics and Control 25


Stirred-Tank Heating Process
Process Dynamics and Control

Assumptions:
• Perfect mixing
 The exit temperature T is also the temperature of
the tank contents
• The liquid holdup V is constant because the inlet and
outlet flow rates are equal
• The density ρ and heat capacity C of the liquid are
assumed to be constant
 Temperature dependence is neglected
• Heat losses are negligible
07/25/20 CAB3014 - Chemical Process Dynamics and Control 26
Stirred-Tank Heating Process
Process Dynamics and Control

Model Development
• For a pure liquid at low or moderate pressures, the internal
energy, Uint, is approximately equal to the enthalpy, H
• H depends only on temperature
• We assume that Uint = H and where the caret (^) means per
unit mass.
A differential change in temperature, dT, produces a
corresponding change in the internal energy per unit mass,
(2.16)

where C is the constant pressure heat capacity.


The total internal energy of the liquid in the tank is:
(2.17)
07/25/20 CAB3014 - Chemical Process Dynamics and Control 27
Stirred-Tank Heating Process
Process Dynamics and Control

An expression for the rate of internal energy accumulation


can be derived from Eqs. (2-16) and (2-17):
(2.18)

• Note that this term appears in the general energy


balance of Eq. 2-5.

Suppose that the liquid in the tank is at a temperature T


and has an enthalpy, Ĥ . Integrating Eq. 2-16 from a
reference temperature Tref to T gives,

(2.19)

07/25/20 CAB3014 - Chemical Process Dynamics and Control 28


Stirred-Tank Heating Process
Process Dynamics and Control

Without loss of generality, we assume that Hˆ ref  0 .


Thus, (2-19) can be written as:
(2.20)

For the inlet stream: (2.21)

Substituting (2-20) and (2-21) into the convection term


of (2-5) gives:
(2.22)

Finally, substitution of (2-18) and (2-22) into (2-5)


(2.23)

07/25/20 CAB3014 - Chemical Process Dynamics and Control 29


Stirred-Tank Heating Process
Process Dynamics and Control

Define deviation variables (from desired operating/set point)

y  T T T is desired operating point


u  ws  ws ws (T ) from steady state
V dy H v H v V
 y  u note that  K p and  1
w dt wC wC w
dy
note when 0 y  K pu
dt
dy
1   y  K pu
dt
General linear ordinary differential equation solution: sum of exponential(s)
Suppose u  1 (unit step response)
  
t

y (t )  K p 1  e 1 
 
 
07/25/20 CAB3014 - Chemical Process Dynamics and Control 30
Stirred-Tank Heating Process
Process Dynamics and Control

07/25/20 CAB3014 - Chemical Process Dynamics and Control 31


Example 1:
Process Dynamics and Control

Ti = 40o C, T = 90o C, Ti = 0o C  V 2 104 kg


   2hr
w 104 kg hr
w s =0.83 106 g hr
H v =600 cal g H v 600(cal/g)
Kp   4
C=l cal g o C wC 10  10 3 (g/hr)  1 (cal/g o C )
4  6  10 5 ( o C hr/kg)
w=10 kg hr
 =103 kg m 3
y  T T
3
V=20 m u  ws  ws
V  2  104 kg

Steady-state balance: The dynamic model is


dy
wC(T -Ti )=ws ΔH v 2 = -y + 6 10-5 u
dt

07/25/20 CAB3014 - Chemical Process Dynamics and Control 32


Example 1:
Process Dynamics and Control

Step 1: at t=0 double ws

T(0) = T y(0) = 0
ws
u = +0.83  10 6 g hr

5
ws
K pu  6  10  0.83  10 6

t=0
 50

2
dy
dt
= -y + 50 
y = 50 l - e -0.5t 
Final T = yss + T = 50 + 90 = 140o C

07/25/20 CAB3014 - Chemical Process Dynamics and Control 33


Example 1:
Process Dynamics and Control

Step 2: Maintain T = 140o C / 24 hr New steady


state

Step 3: Then set u = 0, ws = 830 kg hr


dy
2 = - y + 6 10 -5 u , y (0) = 50
dt

Solve for u = 0 y = 50e -0.5t


as t  , y0

How long to reach y = 0.5 ?

Self-regulating, but slow

07/25/20 CAB3014 - Chemical Process Dynamics and Control 34


Example 1:
Process Dynamics and Control

Step 4: How can we speed up the return from 140°C to


90°C?

ws = 0 g/hr u = -0.83 x 106 g/hr


dy
2 = - y - 50
dt

y = - 50 l - e -0.5t 
At steady state with ws =0, y  -50°C T  40°C

Now, find the time to reach y = 0.5?

Definitely much quicker


than the case u = 0

07/25/20 CAB3014 - Chemical Process Dynamics and Control 35


Process Dynamics
Process Dynamics and Control

• Process control is inherently concerned with unsteady


state behavior, i.e., "transient response", "process
dynamics"

Stirred tank heater: Assume a "lag" between heating element


temperature Te, and process fluid temp, T.

Heat transfer limitation = he A(Te – T)


Energy balances
dT
Tank: wCTi  he A(Te  T )  wCT  mC
dt
dT
Heating element: Q-he A(Te -T)=meCe e
dt
dT dTe
At steady state :  0, 0
dt dt
07/25/20 CAB3014 - Chemical Process Dynamics and Control 36
Process Dynamics
Process Dynamics and Control

Specify Q  Calculate T, Te

2 first order equations  1 second order equation in T

Relate T to Q (Te is an intermediate variable)

y=T- T u=Q-Q Ti fixed

m me C e d 2 y  me C e me C e m  dy 1
2
 
   
  y  u
he Ae dt  he Ae wC w  dt wC

Note Ce  0 yields 1st order ODE (simpler model)

07/25/20 CAB3014 - Chemical Process Dynamics and Control 37


Liquid storage systems
Process Dynamics and Control

1
q= h Rv: line resistance
Rv

linear ODE
If P  p  gh

q=Cv P-Pa Pa : ambient pressure

Non-linear
ODE
07/25/20 CAB3014 - Chemical Process Dynamics and Control 38
Degrees of Freedom Analysis
Process Dynamics and Control

1. List all quantities in the model that are known constants


(or parameters that can be specified) on the basis of
equipment dimensions, known physical properties, etc.
2. Determine the number of equations NE and the number
of process variables, NV. Note that time t is not
considered to be a process variable because it is neither
a process input nor a process output.
3. Calculate the number of degrees of freedom, NF = NV -
NE.

07/25/20 CAB3014 - Chemical Process Dynamics and Control 39


Degrees of Freedom
Process Dynamics and Control

4. Identify the NE output variables that will be obtained


by solving the process model.
5. Identify the NF input variables that must be specified
as either disturbance variables or manipulated
variables, in order to utilize the NF degrees of freedom.

07/25/20 CAB3014 - Chemical Process Dynamics and Control 40


Degrees of Freedom Analysis
for the Stirred-Tank Model
Process Dynamics and Control

Parameters (3): V ,  , C Variables (4): T , Ti , w, Q

Equation (1) : Eq. 2-23 NF = 4 – 1 = 3

The process variables are classified as:


Output variable: T Input variables : Ti, w, Q

For temperature control purposes, it is reasonable to classify


the three inputs as:
Disturbance variables : Ti, w
Manipulated variable : Q
07/25/20 CAB3014 - Chemical Process Dynamics and Control 41
Conclusion!
Process Dynamics and Control

• Need for mathematical modeling


• Types of mathematical models
• A systematic approach
• Blending example – revisited
• Tank heater example – model developed
• Second-order system
• Linear and nonlinear systems
• Degrees of freedom

07/25/20 CAB3014 - Chemical Process Dynamics and Control 42


For Chapter 3
Process Dynamics and Control

• Go through Laplace Transform


• Xerox Laplace Transform Table 3.1
page 54-55, Seborg Book

07/25/20 CAB3014 - Chemical Process Dynamics and Control 43

You might also like