Chapter 5 Solutions
Chapter 5 Solutions
af af
5.1 Derive the transfer function H s / Q s for the liquid-level system of Fig. P5.1 when
a) The tank level operates about the steady-state value of hs = 1 ft
b) The tank level operates about the steady-state value of hs = 3 ft.
The pump removes water at a constant rate of 10 cfm (cubic feet per minute); this
rate is independent of head. The cross-sectional area of the tank is 1.0 ft 2 and the
resistance R is 0.5 ft/cfm.
dh
a) Volume balance : q − 10 = A
dt
The tank level operates about the steady state value of hs = 1 ft (at this height the only
outlet from the tank is through the pump)
at steady state : qs − 10 = 0
dh
after subtraction : q − qs = A
dt
dH
Q(t)= A
dt
H ( s) 1 1
Rearranging : = =
Q( s ) As s
b) The tank level operates about the steady state value of hs = 3 ft (at this height the
outlets from the tank is through the pump and through the resistance)
(h − 2) dh
Volume Balance : q − 10 − =A
R dt
(hs − 2)
At steady state : qs − 10 − =0
R
(h − hs ) dh
After subtraction : q − qs − =A
R dt
H (t ) dH
Q(t ) − =A
R dt
H ( s)
Q( s) − = AsH ( s )
R
Rearranging,
( ARs + 1) H ( s) = RQ( s)
H ( s) R R 0.5 H ( s)
= = = =
Q( s ) ARs + 1 τ s + 1 0.5s + 1 Q( s )
5.2.A liquid-level system, such as the one shown in Fig. 5.1, has a cross-sectional area of
3.0 ft 2 .
Figure 5.1
Figure P5.3
af af
a) Find the transfer function H s / Q s .
b) If the flow to the tank increases from 2.0 to 2.2 cfm according to a step change,
calculate the level h two minutes after the change occurs.
5.3 Continued
First find an expression for the outlet flow rate:
From graph:
q0 h
1.0 0.3
2.4 1.0
⎛ 2.4 − 1 ⎞
∴ q0 = ⎜ ⎟h +b
⎝ 1 − 0.3 ⎠
q0 = 2h + b
1 = 2(0.3) + b
b = 0.4
q0 = 2h + 0.4
Part a)
dh
Volume Balance: 2 = qi − (2h + 0.4)
dt
@ SS 0 = qis − (2hs + 0.4) → since qis = 2, hs = 0.8
subtracting,
dH
∴ 2 = Q − 2H
dt
H ( s) 1 0.5
= = Transfer Function
Q( s) 2s + 2 s + 1
Part b)
0.2
Q( s) = step change of 0.2cfm
s
0.5(0.2) 0.1 A B
H (s) = = = + → A = 0.1, B = -0.1
s ( s + 1) s ( s + 1) s s + 1
0.1 0.1
∴ H ( s) = − → H (t ) = 0.1(1 − e − t )
s s +1
h(t ) = hs + H (t ) = 0.8 + 0.1(1 − e − t )
h(2) = 0.9 − 0.1e −2 = 0.8865 ft = h(2)
5.4 Develop a formula for finding the time constant of the liquid-level system shown in
Fig. P5.4 when the average operating level is h0 . The resistance R is linear. The tank has
three vertical walls and one that slopes at an angle α from the vertical as shown. The
distance separating the parallel walls is 1.
Figure P5.4
As in Problem 5.2, the process dynamics are determined by an overall volume balance:
dV
= q in − q out
dt
dh
( B + tan(α ) h) = q in − q out
dt
This equation is not of the form of a first order process since the coefficient of the time
derivative is not a constant. To make it a constant we will have to set the level to a
constant value. Assuming variations in level are small, we can do this by setting the level
equal to the average value h0. Doing so and substituting qout=h/R, we obtain
R( B + tan(α ) h0 )
dh
= Rq in − h
dt
which upon changing to the same deviation variables defined in Problem 5.2 becomes:
= RQ − H , where τ = R ( B + tan (α ) h0 )
dH
τ
dt
Figure P5.5
A material balance on A gives:
dco
ci F − co F − Vk1co = V (1)
dt
At steady state:
dCi
V = FCi − ( F + kV )C0 (3)
dt
Ci ( s ) F − Co ( s ) F − VkCo ( s ) = vsCo ( s )
Co ( s )
Solving for gives:
Ci ( s )
⎡ F ⎤
⎢ Vk + F ⎥⎦
= ⎣
Co ( s ) F
=
Ci ( s ) Vs + ( F + Vk ) ⎡ V ⎤
⎢⎣ Vk + F ⎥⎦ s + 1
5.6 A thermocouple junction of area A, mass m, heat capacity C, and emissivity e is
located in a furnace that normally is at Tis , ° C. At these temperatures convective and
conductive heat transfer to the junction are negligible compared with radiative heat
transfer. Determine the linearized transfer function between the furnace temperature
Ti and the junction temperature T0 . For the case
m = 0.1g
C = 0.12cal / ga fc Ch
e = 0.7
A = 0.1cm 2
Tis = 1100 C
plot the response of the thermocouple to a 10° C step change in furnace temperature.
Compare this with the true response obtained by integration of the differential
equation.
Solution:
An energy balance on the thermocouple junction gives:
= σeA( Ti 4 − T 4 )
dT
mC
dt
where
mC=0.012 cal/K=0.0502 J/K
σeA =(5.672x10-8W/m2/K4)(0.7)(0.1/100/100 m2)=3.97x10-13
(the value of the Stefan- Boltzmann constant, σ , was taken from McCabe, Smith and
Harriott, 5th edition, page 413.)
dT
τ* = Ti 4 − T 4
dt
where the value of the pseudo time constant is 1.26x1011 sK3. Note that τ * is not a true
time constant of first order process because it does not have units of time. To convert this
equation into that of a first order process we will expand the T4 term on the right hand
side in a Taylor series expansion about the initial steady state value of 1373 K:
= ( Ti 4 − Ts4 ) − 4Ts3 (T − Ts )
dT
τ*
dt
or
dY
τ = X −Y
dt
where
Y=T-Ts
X=(Ti4-Ts4)/4/Ts3u(t)=10.1u(t) (Note that Ti=Ts so X=0 for t<0)
τ = τ * / 4 / Ts3 =12.2s.
This is the form of a first order transfer function. We can now determine the transient
behavior of T as we have done before:
X='A*Heaviside(t)'
X =
A*Heaviside(t)
Xs=laplace(X)
Xs =
A/s
Ys=symmul(Xs,'1/(tau*s+1)')
Ys =
A/s/(tau*s+1)
Y=invlaplace(Ys)
Y =
A-A*exp(-1/tau*t)
Y=subs(Y,'10.1','A'); Y=subs(Y,'12.2','tau')
Y =
10.1-10.1*exp(-8.196721311475410e-2*t)
8
T-1373
3
0 20 40 60 80 100
t
We may also solve the differential equation directly. The following M-file was used in
ode23 to obtain the solution by numerical integration:
type prob56.m
function xprime=prob56(t,x)
Ti4=1383^4;
taustar=1.26E11;
xprime(1)=(Ti4-x(1)^4)/taustar;
[t,Thermo]=ode23('prob56',0,100,1373);
Tdev=Thermo(:,1)-1373;
hold on
plot(t,Tdev(:,1))
10
8
T-1373
3
0 20 40 60 80 100
t
hold off
A comparison of the two curves indicates the linearized transient response equation
predicts the actual response quite well. The time required to reach steady state is virtually
the same, approximately 50 s. The ultimate temperature deviation values differ by a tenth
of a degree, 10.1 (the value of A) for the linearized response versus exactly 10 for the
actual response.
Part a) Solution
Inflow, Steady- Q (gpm)
gal/hr State
Level, ft
0 0 0
5,000 0.7 83.33333
10,000 1.1 166.6667
15,000 2.3 250
20,000 3.9 333.3333
25,000 6.3 416.6667
30,000 8.8 500
⎛ 3.9 − 2.3 ⎞
2.3 + ⎜ ⎟ (300 − 250) = 3.26 ft
⎝ 333.3 − 250 ⎠
π D2 π ( 25 )
A= = = 19.6 ft 2
4 4
⎛ ft ⎞ ⎛ 7.48 gal ⎞
τ = AR = (19.6 ft 2 ) ⎜ 0.0109 ⎟⎜ ⎟ = 1.6 min
⎝ gal min ⎠ ⎝ ft 3 ⎠
H ' 0.0109
=
Qin' 1.6 s + 1
100 gpm
Qin' =
s
1.09 0.6794 A B 1.09 1.09
H' = = = + = −
s (1.6s + 1) s ( s + 0.625 ) s s + 0.625 s s + 0.625
H ' (t ) = 1.09(1 − e −0.625t )
H (t ) = 3.26 + 1.09(1 − e −0.625t )
hss
Numerically,
R = 0.0109 ft
gpm
A1 = 19.6 ft 2
A2 = 12.6 ft 2
τ 1 = A1 R = 1.6 min
τ 2 = A2 R = 1.37 min
Now,
100
Q0 ( s ) = (step change 300gpm to 400gpm)
s
1.49s + 2.18
H1 ( s ) =
(
s 2.19s 2 + 4.57 s + 1 )
h1ss − h2 ss
Initial SS heights in the tanks, from linearized Tk1: 300 − =0
R
h1ss − h2 ss h2 ss
From Tk2: − =0 Solving simultaneously, h1ss = 6.54 ft h2 ss = 3.27 ft
R R
Using MATLAB to invert and plot:
h=
(149/100*s+109/50)/(219/100*s^2+457/100*s+1)/s
H=ilaplace(h)
H=
109/50-1/6062450*exp(-
457/438*t)*(13216141*cosh(1/438*t*121249^(1/2))+34913*sinh(1/438*t*121249^(
1/2))*121249^(1/2))
1.5
Tank 1 Height(ft)
0.5
0
0 2 4 6 8 10 12 14 16 18 20
t
The new SS height in Tank 1 is 2.18ft (deviation variable) or 8.72ft (actual height). This
height is greater than the height with a single tank alone. With the addition of Tank 2 on
the outlet of Tank 1, more height is required in Tank 1 to produce an outlet flow of
400gpm to bring the system back to steady state. This is based upon a linearization about
300gpm inlet flow.
Solving the original (not linearized) differential equations:
First, we can fit the tabular data with an equation over the range of interest:
Ht Flow
2.3 250
3.9 333.3333
6.3 416.6667
P5.7 - Flow vs SS Height
600
500
400
outlet flow (gpm)
300
200
100
0
0 1 2 3 4 5 6 7 8 9 10
ss height (ft)
450
400
350
300
Outlet Flow (GPM)
250
200
150
100
50
0
0 1 2 3 4 5 6 7
SS Height (ft)
Fitted equation from Excel: Q1 = −4.34h12 + 79h1 + 91.3
dh1
ODE1: 400 − [−4.34 ( h1 − h2 ) + 79 ( h1 − h2 ) + 91.3] = 19.6
2
dt
dh2
ODE2: [−4.34 ( h1 − h2 ) + 79 ( h1 − h2 ) + 91.3] − [−4.34 ( h2 ) + 79 ( h2 ) + 91.3] = 12.6
2 2
dt
Initial Conditions:
Q0 = 300 gpm, what are h1ss and h2 ss for the nonlinearized case?
Set RHS of ODE1 and ODE2 to zero and solve simultaneous eqtns for h1ss and h2 ss
300 − [−4.34 ( h1ss − h2 ss ) + 79 ( h1ss − h2 ss ) + 91.3] = 0
2
(1)
[−4.34 ( h1ss − h2 ss ) + 79 ( h1ss − h2 ss ) + 91.3] − [−4.34 ( h2 ss ) + 79 ( h2 ss ) + 91.3] = 0
2 2
(2)
Adding (1) and (2) together:
300-[−4.34 ( h2 ss ) + 79 ( h2 ss ) + 91.3] = 0
2
Simplifying:
( h2 ss ) − 18.2 ( h2 ss ) + 48.1 = 0
2
h2 ss = 3.21 ft
h1ss = 6.42 ft
[t,h]=ode45('prob5_7',[0,20],[6.42,3.21]);
plot(t,h)
xlabel('time')
ylabel('height')
grid
12
11
10
9
tank1
tank2
8
height
3
0 2 4 6 8 10 12 14 16 18 20
time
Figure P5.8
a) Plot on this same figure your best guess of the quantitative behavior of the inlet
concentration versus time. Be sure to label the graph with quantitative information
regarding times and magnitudes and any other data that will demonstrate your
understanding of the situation.
b) Write an equation for Ci as a function of time.
Data: Tank dimensions: 8 ft high by 5 ft diameter
Tank volume V: 700 gal
Flow rate q: 100 gal/min
Average density: 70 lb/ft 3
C ( s) 1
=
Ci ( s ) 7 s + 1
Assume that Ci is a sine wave: Ci = A sin ωt
Aω
Ci ( s ) =
s + ω2
2
⎛ Aω ⎞ ⎛ 1 ⎞
C ( s) = ⎜ 2 2 ⎟⎜ ⎟
⎝ s + ω ⎠ ⎝ 7s + 1 ⎠
Aωt −
t
A
C (t ) = e τ
+ sin(ωt + φ )
(ωτ ) (ωτ )
2
+1 2
+1 −1
tan ( −ωτ )
τ = 7 min
2π rad rad
ω= = 0.143
44 min min
from graph
ωτ = 1
−π
φ = tan −1 (−1) = −45 (or
rad ) output phase shift
4
rad
with a frequency of 0.143 , the time lag between the input and output is:
min
⎛π ⎞
⎜ rad ⎟
tlag = ⎝ ⎠ = 5.5 min = 5 min 30sec lag
4
⎛ rad ⎞
⎜ 0.143 ⎟
⎝ min ⎠
A A A
Amplitude of Output = 0.1 = = =
(ωτ ) + 1 1 + 1 1.414
2
impulse) to the tank; at t = 1 , 2 ft of water is added suddenly to the tank. Sketch the
3
response of the level in the tank versus time and determine the level at t = 0.5, 1, and
1.5.
Figure P5.9
h dh
qi − =A
0.5 dt
h
qis − s = 0 steady state → hs = 5 ft (since qis = 10cfm)
0.5
h' dh'
qi' − =A subtracting
0.5 dt
Prob P5.9
rearrange
dh'
0.5qi' = 0.5 A + h'
τ dt 6.5
transform
0.5Qi ( s ) = (τ s + 1) H ' ( s )
6
H ' (s) 0.5 0.5
= =
Qi ( s ) (τ s + 1) s + 1
height
5.5
Qi ( s ) = 1 + 2e − s
impulse impulse
mag=1 mag=2
at t=0 delayed
1 minute 5
0.5 e − s
H ' ( s) = +
s +1 s +1 4.5
0 0.5 1 1.5 2 2.5 3
−t − ( t −1)
h (t ) = 0.5e u (t ) + e
'
u (t − 1) time
Figure P5.10
af af
a) Determine Q t and Q s by combining simple functions. Note that Q is the deviation
in flow rate.
af
b) Obtain an expression for H t where H is the deviation in level.
af
c) Determine H t at t = 2 and t = ∞ .
Solution-Part a and b)
dh
qi − h = 2
dt
qis − hs = 0 steady state → hs = 1 ft (since qis = 1cfm)
dh'
qi' − h' = 2 subtracting
dt
Transform
Qi ( s ) = (2 s + 1) H ( s )
H (s) 1
=
Qi ( s ) 2s + 1
1 e− s
Qi ( s ) = 2 − 2
s s
⎛ 1 ⎞⎛ 1 e ⎞
−s
H (s) = ⎜ ⎟⎜ 2 − ⎟
⎝ 2s + 1 ⎠ ⎝ s s2 ⎠
⎛ 1 − e− s ⎞ 1 e− s
H (s) = ⎜ = −
⎜ ( 2s + 1) s 2 ⎟⎟ ( 2s + 1) s 2 ( 2s + 1) s 2
⎝ ⎠
Using partial fractions and inverting:
1 0.5 1 2 2
= = 2− +
( 2s + 1) s ( s + 0.5) s s s s + 0.5
2 2
⎡ − ⎤
t
⎡ −
t −1
⎤
H (t ) = ⎢t − 2 + 2e ⎥ u (t ) − ⎢(t − 1) − 2 + 2e 2 ⎥ u (t − 1)
2
⎣ ⎦ ⎣ ⎦
Solution Part c)
H (2) = (2 − 2 + 2e −2/2 ) − (1 − 2 + 2e −0.5 ) = 0.523 ft
0.736 0.213
e −3 s
5.11. Determine y(t=5) if Y ( s ) = .
s ( 7 s +1)
Solution:
e −3 s
Y (s) =
s (7 s + 1)
− ( t − 3)
⎡ 7 ⎤
Y (t ) = ⎢1 − e ⎥ u (t − 3)
⎣ ⎦
− ( 5 − 3)
⎡ 7 ⎤ ⎡ −2
7⎤
Y (5) = ⎢1 − e ⎥ = ⎣⎢1 − e ⎦⎥ = 0.25 = Y (5)
⎣ ⎦
5.12 Derive the transfer function H/Q for the liquid level system shown in Fig. P5.12.
The resistances are linear. H and Q are deviation variables. Show clearly how you
derived the transfer function. You are expected to give numerical values in the
transfer function.
Figure P5.12
Solution (see next page)
h
q1 =
R1
h
q2 =
R2
1 1 1
Let = +
R R1 R2
Volume Balance:
dh
q − (q1 + q2 ) = A
dt
⎛ 1 1 ⎞ dh
q −⎜ + ⎟h = A
⎝ R1 R2 ⎠ dt
h dh
q− = A
R dt
h
qs − s = 0 at steady state
R
h − hs d ( h − hs )
q − qs − =A after subtraction
R dt
H (t ) dH
Q(t ) − =A
R dt
Transforming:
H ( s)
Q( s) − = AsH ( s )
R
H ( s) R 1 1 10 ⎛ 10 ⎞ 20
= where R = = = and τ = AR = ( 2 ) ⎜ ⎟ =
Q( s) τ s + 1 1
+
1 1 1 7
+ ⎝ 7⎠ 7
R1 R2 2 5
10
H ( s) 7
=
Q( s ) 20 s + 1
7
5.13 The liquid-level system shown in Fig. P5.13 is initially at steady state with the inlet
flow rate at 1 cfm. At time zero, one ft 3 of water is suddenly added to the tank; at
t = 1, one ft 3 is added, etc. In other words, a train of unit impulses is applied to the
tank at intervals of one minute. Ultimately the output wave train becomes periodic as
shown in the sketch. Determine the maximum and minimum values of this output.
Figure P5.13
Solution:
At t=0 the constant inlet flow of 1 cfm is switched to a train of impulse flows of
magnitude 1 ft3. After the cyclic behavior becomes periodic, one obtains the transient
level output shown above.
dh h
A = q in − q out = q in −
dt R
We use the initial height, at the beginning of one of the cycles, to define the deviation
variable for the tank height:
H=h-hmin
dH
τ = RQ − H
dt
where H(0)=0 and R=1 min/ft2.
Q = Aδ − hmin
τ = AR = 1
We are can now solve the differential equation using Laplace transforms.
H ( s) K 1
= =
Q( s ) τ s + 1 s + 1
Q=laplace(DIRAC(t)-hmin)
Qs =
1-hmin/s
Therefore,
1 h
H (s) = − min
s + 1 s ( s + 1)
H=ilaplace(1/(s+1)-hmin/s/(s+1))
H =
-hmin+(1+hmin)*exp(-t)
hmin=exp(-1)/(1-exp(-1))
hmin =
0.5820
hmax =
1.5820
Another Method:
Alternatively, one can simulate the entire transient process. This is most conveniently
done using the following deviation variables:
H=h-1
∞
Q = ∑ δ (t − n) − 1
n =0
To solve using Laplace transforms we will approximate this infinite sum by some finite
number of impulse functions, we’ll use seven to demonstrate the method.
syms Q, t, s
Q=DIRAC(t)+DIRAC(t-1)+DIRAC(t-2)+DIRAC(t-3)+DIRAC(t-4)+DIRAC(t-
5)+DIRAC(t-6)-1
Q =
DIRAC(t)+DIRAC(t-1)+DIRAC(t-2)+DIRAC(t-3)+DIRAC(t-4)+DIRAC(t-
5)+DIRAC(t-6)-1
Qs=Laplace(Q)
Qs =
1+exp(-s)+exp(-2*s)+exp(-3*s)+exp(-4*s)+exp(-5*s)+exp(-6*s)-1/s
Hs= Qs*1/(s+1)
Hs =
(1+exp(-s)+exp(-2*s)+exp(-3*s)+exp(-4*s)+exp(-5*s)+exp(-6*s)-1/s)/(s+1)
H=invlaplace(Hs)
H =
2*exp(-t)+HEAVISIDE(t-1)*exp(-t+1)+HEAVISIDE(t-2)*exp(-
t+2)+HEAVISIDE(t-3)*exp(-t+3)+HEAVISIDE(t-4)*exp(-t+4)+HEAVISIDE(t-
5)*exp(-t+5)+HEAVISIDE(t-6)*exp(-t+6)-1
0.5
Level-1
-0.5
-1
0 2 4 6 8 10
t
t=5.001; hmax=1+eval(H)
hmax =
1.5832
t=4.999; hmin=1+eval(H)
hmin =
0.5854
5.14.The two-tank mixing process shown in Fig. P5.14 contains a recirculation loop that
transfers solution from tank 2 to tank 1 at a flow rate of αqo .
Figure P5.14
a Develop a transfer function that relates the concentration in tank 2, c2 , to the
af af
concentration in the feed, x; i.e. C2 s / X s where C2 and X are deviation variables.
For convenience, assume that the initial concentrations are x = c1 = c2 = 0 .
b If a unit-step change in x occurs, determine the time needed for c2 to reach 60 percent
of its ultimate value for the cases where α = 0, 1, and ∞ .
c Sketch the response for α = ∞ .
Assume that each tank has a constant holdup volume of 1 ft 3 . Neglect transportation lag
in the line connecting the tanks and the recirculation line. Try to answer parts (b) and (c)
by intuition
Solution 5.14a:
α = 0 Case
c2 ( s ) 1
= 2
x( s) s + 2s + 1
1 1 A B C
c2 ( s ) = = = + +
s ⎡⎣ s + 2s + 1⎤⎦ s [ s + 1] s ( s + 1) s + 1
2 2 2
c2 (t ) = 1 − e − t − te− t for α =0
Now we need t such that c2 (t ) = 0.6 :
time =
2.0223 for α=0
α = ∞ Case
c2 ( s ) 1
=
x( s) 2s + 1
1
c2 ( s ) =
s [ 2s + 1]
−t
c2 (t ) = 1 − e 2
for α =∞
Now we need t such that c2 (t ) = 0.6 :
−t
0.6 = 1 − e 2
−t
e 2 = 0.4
t = 1.83min
α = 1 Case
c2 ( s ) 1
=
x( s) 2s + 1
1 A B C
c2 ( s ) = = + +
s ⎡⎣0.5s + 2 s + 1⎤⎦ s
2
s + 0.586 s + 3.414
Roots of quadratic:
−2 ± 4 − 2
r= =−2 ± 2 =−3.414, −0.586
1
time =
1.8830 for α=1
5.15 Dye for our new line of blue jeans is being blended in a mixing tank. The desired
color of blue is produced using a concentration of 1500 ppm blue dye, with a
minimum acceptable concentration of 1400 ppm. At 9AM today the dye injector
plugged and the dye flow was interrupted for 10 minutes, until we realized the
problem and unclogged the nozzle. For how many minutes was the flow leaving the
mixer off-specification (<1400ppm)? How many gallons of off-spec dye were made?
water 20gal/min
V=100gal
Figure P5.15
dcout
q0 cin − q0 cout = V
dt
dcouts
q0 cins − q0 couts = V
dt
dCout
q0Cin − q0Cout = V
dt
V dCout
Cin − Cout =
q0 dt
Transforming:
Cin ( s ) = (τ s + 1) Cout ( s )
Cout ( s ) 1
=
Cin ( s ) (τ s + 1)
1000
Inlet Concentration
500
-5 0 5 10 15
t
-200
-400
Cin (deviation variable)
-600
-800
-1000
-1200
-1400
-1600
-5 0 5 10 15
t
Cout ( s ) =
1
s ( 5s + 1)
(
−1500 + 1500e −10 s )
partial
fractions
↓
1 0.2 A B 1 1
= = + = −
s ( 5s + 1) s ( s + 0.2 ) s + 0.2 s s s + 0.2
∴ Cout (t ) = −1500 ⎡⎣1 − e −0.2t ⎤⎦ u (t ) + 1500 ⎡⎣1 − e−0.2( t −10) ⎤⎦ u (t − 10)
( ) ( )
cout (t ) = Cout (t ) + 1500 = 1500 ⎡⎣1 − 1 − e −0.2t u (t ) + 1 − e−0.2( t −10) u (t − 10) ⎤⎦
1400
1200
1000
C
800
600
400
200
0 5 10 15 20 25 30
t
Using the MATLAB generated graphs, we can determine that the offspec material starts
at t=0.3464minutes and ends at 22.79minutes. (or this can be found by trial and error or
using Excel to determine the time when the outlet concentration is 1400ppm. So the total
time of offspec production is 22.44min. At a flow rate of 20gpm, 448.8gal of offspec dye
are produced.
5.16 For the reactor (CSTR) shown below, determine the transfer function that relates the
exit concentration from the reactor to changes in the feed concentration. If we
instantaneously double the feed concentration from 1 gmole/liter to 2gmoles/liter,
what is the new exiting concentration one minute later? What is the new steady state
reactor concentration?
2
The rate constant is k = .
⎛ gmoles ⎞
⎜ ⎟ ( minute )
⎝ liter ⎠
5 liters/min
CAs=0.2 gmole/liter
Volume = 50 liters
Figure P5.16
dC A
vC A0 − vC A − kVC A2 = V
dt
Check on initial steady-state concentration:
⎛ l ⎞ ⎛ gmol ⎞ ⎛ l ⎞ ⎛ l ⎞
⎟ −⎜5 ⎟ C As − ⎜ 2 ⎟ ( 50l ) C As = 0
2
⎜5 ⎟ ⎜1
⎝ min ⎠ ⎝ l ⎠ ⎝ min ⎠ ⎝ gmoleimin ⎠
2
20C As + C As − 1 = 0
−1 ± 1 + 80 −1 ± 9 8 gmol
C As = = = = 0.2 = C As
40 40 40 l
gmol
C A0 s = 1.0
l
Back to the mole balance:
dC A
vC A0 − vC A − kVC A2 = V
Linearize
dt
C A2 = C As
2
+ 2C As ( C A − C As )
Substituting:
vC A0 − vC A − kV C As
2
( )
+ 2C As ( C A − C As ) = V
dC A
dt
vC A0 s − vC As − kV C As
2
(
+ 2C As ( C As − C As ) ) =V
dC As
dt
steady state
d ( C A − C As )
v(C A0 − C A0 s ) − v(C A − C As ) − kV 2C As ( C A − C As ) = V subtracting
dt
dC A′
vC ′A0 − vC ′A − kV 2C As C A′ = V
dt
Rearranging:
V dC A′ ( v + 2kVC As )
C A′ 0 = + C A′
v dt v
τ Kp
( )
gmol
C A (1) = 0.2 + 0.111 1 − e −1/1.11 = 0.2659
l
new conc at t=1min
Check new steady-state, linearized vs. actual, using steady state mole balance:
( 5) ( 2 ) − 5C As − ( 2 )( 50 ) C As2 = 0
CA 0 =2
gmol gmol
C As = 0.292 versus 0.311 for the linearized solution
l l
Let’s check the actual solution versus the linearized solution using
MATLAB:
dC A
Actual: 5C A0 − 5C A − 100C A2 = 50
dt
dC A
+ 0.1C A + 2C A2 = 0.1C A0 C A (0) = 0.2
dt
[t,c]=ode45('prob5_16',[0,6],[0.2]);
clinear=0.2+0.111*(1-exp(-t/1.11));
plot(t,c,t,clinear)
grid
xlabel('time')
ylabel('concentration')
>> title('Solution for Problem 5.16')
__________________________________________
Filename: prob5_16.m
function cprime=prob5_16(t,c)
cprime=(0.2-0.1*c-2*c^2);
>> [t,c,clinear]
ans =
0 0.2000 0.2000
0.1005 0.2096 0.2096
0.2010 0.2183 0.2184
0.3014 0.2263 0.2264
0.4019 0.2334 0.2337
0.5519 0.2428 0.2435
0.7019 0.2508 0.2520
0.8519 0.2576 0.2595
1.0019 0.2633 0.2660 Å time = 1
1.1519 0.2681 0.2717
1.3019 0.2722 0.2766
1.4519 0.2756 0.2810
1.6019 0.2784 0.2848
1.7519 0.2807 0.2881
1.9019 0.2827 0.2910
2.0519 0.2843 0.2935
2.2019 0.2857 0.2957
2.3519 0.2868 0.2977
2.5019 0.2877 0.2993
2.6519 0.2885 0.3008
2.8019 0.2891 0.3021
2.9519 0.2897 0.3032
3.1019 0.2901 0.3042
3.2519 0.2905 0.3051
3.4019 0.2908 0.3058
3.5519 0.2910 0.3065
3.7019 0.2912 0.3070
3.8519 0.2914 0.3075
4.0019 0.2915 0.3080
4.1519 0.2917 0.3084
4.3019 0.2918 0.3087
4.4519 0.2918 0.3090
4.6019 0.2919 0.3092
4.7519 0.2920 0.3095
4.9019 0.2920 0.3097
5.0519 0.2920 0.3098
5.2019 0.2921 0.3100
5.3519 0.2921 0.3101
5.5019 0.2921 0.3102
5.6519 0.2921 0.3103
5.8019 0.2921 0.3104
5.8514 0.2922 0.3104
5.9010 0.2922 0.3105
5.9505 0.2922 0.3105
6.0000 0.2922 0.3105 Å new steady state
5.17 The Antoine Equation for the vapor pressure of a liquid at a given temperature is
given by:
B
A−
P* = e T +C
⎡ ⎛ B ⎞⎤ ⎛ B ⎞
2 (
P* = Ps* + exp( A) ⎢ exp ⎜ − ⎟ ⎥ ⎜⎜ ⎟ T − Ts )
⎢⎣ ⎝ Ts + C ⎠ ⎥⎦ ⎝ (Ts + C ) ⎟⎠
⎛ B ⎞⎛ B ⎞
P* = Ps* + exp ⎜ A − ⎟ ⎜⎜ ⎟ (T − Ts )
⎝ Ts + C ⎠ (Ts + C )2 ⎟
⎝ ⎠
Ps*
⎛ B ⎞
P* = Ps* + Ps* ⎜ ⎟ (T − Ts )
⎜ (T + C )2 ⎟
⎝ s ⎠
Linearizing about 40C:
⎛ 2788.51 ⎞
P40* C = exp ⎜15.9008 − ⎟ = 182.85mmHg
⎝ 40 + 220.8 ⎠
⎛ 2788.51 ⎞
*
Plinearized = 182.85 + (182.85 ) ⎜ ⎟ (T − 40 )
⎜ ( 40 + 220.8 )2 ⎟
⎝ ⎠
*
Plinearized = 7.496 (T − 40 ) + 182.85
*
Plinearized T P* %difference
220.33 45C 223.6 1.46%
332.77 60C 391.6 15.0%
As we move away from the point of linearization, 40C, the suitability of the equation
decreases.
5.18 Find the transfer function that relates the height in the vessel to changes in the inlet
flow rate.
qi (CFM)
h
θ=30°
qo(CFM)
Figure P5.18
R1
(valve resistance)
h tan15°=h/R
15°
Solution:
dV
qi − q0 =
dt
1 1 π tan 2 15 3
V = π r 2 h = π ( h tan15 ) h =
2
h
3 3 3
⎛ π tan 2 15 ⎞ 2 dh
qi − q0 = ⎜ ⎟ 3h
⎝ 3 ⎠ dt
qi −
h
R1
(
= π tan 2 15 h 2 )
dh
dt
exact equation
Let's go back and linearize V before substituting into the volume balance:
π tan 2 15
V= h3 = α h3
3
α
Vlinearized = α hs3 + 3α hs2 (h − hs )
dVlinearized d (h − hs )
= 3α hs2
dt dt
thus,
h d (h − hs )
qi − = 3α hs2
R1 dt
d (h − hs )
R1q1 = 3α R1hs2 +h
dt
R1q1s = hs at steady state
d (h − hs )
R1 (q1 − q1s ) = 3α R1hs2 + (h − hs )
dt
dh′
R1q1′ = 3α R1hs2 + h′
dt
Transforming:
( )
R1q1′( s ) = 3α R1hs2 s + 1 h′( s )
h′( s ) R1
=
q1′( s ) 3α R1hs2 s + 1
τ
⎛ π tan 2 15 ⎞
τ = 3⎜ ⎟ R1hs = π R1 ( hs tan15 ) = τ
2 2
⎝ 3 ⎠
Solving the exact volume balance in MATLAB with some
numbers… Let hs=3ft, R1=1min/ft2
At steady state, qis= hs/ R1=3cfm and let the disturbance be
a step change in the inlet flow rate from 3cfm to 4cfm.
h′( s ) R1 1
= =
q1′( s ) π R1 ( hs tan15 ) s + 1 2.03s + 1
2
1
q1′ ( s ) =
s
1
h′( s ) =
s ( 2.03s + 1)
−t
h′(t ) = 1 − e 2.03
⎛ −t
⎞
h(t ) = 3 + ⎜1 − e ⎟
2.03
⎝ ⎠
[t,h]=ode45('prob518',[0,20],[3]);
h1=3+(1-exp(-t/2.03)); this is the solt’n to linearized+
plot(t,h,'r',t,h1,'k');
function hprime=prob518(t,h)
hprime=(1/3/0.0752)*(4/(h^2)-1/h);
⎛ 1 ⎞ ⎛ 1 ⎞ dh
qi ⎜ −
2 ⎟ ⎜ 2 ⎟
=
⎝ 3Kh ⎠ ⎝ 3KR1h ⎠ dt
where
π
K=
3
( tan 2
)
15 = 0.0752
min
R1 = 1
ft 2
qi = 4cfm (step changed from 3cfm to 4cfm... forcing function is therefore constant 4cfm)