You are on page 1of 19
4 class Contral pracess and dynamic Chapter S (process system and analysis control) 5.1 EXAMPLES OF FIRST-ORDER SYSTEMS Liquid Level Consider the system shown in Fig. 5-1, which consists of a tank of uniform cross-sectional area A to which is attached a flow resistance R such as a valve, a pipe, or a weir. Assume that go, the volumetric flow rate (volume/time) through the resistance, is related to the head h by the linear relationship A jo = 5.1 4 R G.1) A resistance that has this linear relationship between flow and head is, referred to as a linear resistance. (A pipe is a linear resistance if the flow is in the laminar range. A specially contoured weir, called a Sutro weir, produces a linear head-flow relationship, Turbulent flow through pipes and valves is generally proportional to Vh. Flow through weirs having simple geometric shapes can be expressed as Kh", where K and n are positive constants. For example, the flow through a rectangular weir is proportional to h*”,) FIGURE S41 Liquid-level system, 40, A time-varying volumetric flow q of liquid of constant density p enters the tank. Determine the transfer function that relates head to flow. We can analyse this system by writing a transient mass balance around the tank: Rate of Rate of Rate of accumulation mass flow in mass flow out of mass in tank In terms of the variables used in this analysis, the mass balance becomes d(pAh) palt) — pqo(t) =

0.1 1o(1 = e "©? )u(r — 0.1) 4 class Contra pracess and dynamic ‘The complete solution to this problem, which is the inverse of Eq. (5.13), is H(® = 10(1 — e")u(s) — 10(1 Out — 0.1) 6.14) which is equivalent to H() = 10(1~ e“) 1<01 A = 10[(1—e“)—(1—e2)] > 01 Simplifying this expression for H(i) for 1 > 0.1 gives H() = 1.052 ft > 0.1 From Eq, (4.19), the response of the system to an impulse of magnitude 9 is given by (=e! (4.19) HOlimputse = (56) = €* In Fig. 5-2, the pulse response of the liquid-level system and the ideal impulse response are shown for comparison, Notice that the level rises very rapidly during the 0.1 min that additional flow is entering the tank; the level then decays exponentially and follows very closely the ideal impulse response. 10 \ Pulse response Area = 9 ft = = Impulse response = 100 iH = (ideal) S > 10 0 01 02 % 1 2 t(min) ¢(min) (a) ) FIGURE 5-2Approximation of an impulse function in a liquid-level system (Example 5.1). (a) Pulse input; (6) response of tank level. 4 class Contral pracess and dynamic Liquid-Level Process with Constant-Flow Outlet An example of a transfer function that often arises in control systems may be developed by considering the liquid-level system shown in Fig. 5-3 . The resistance shown in Fig. 5-1 is replaced by a constant-flow pump. The a) same assumptions of constant cross sectional area and Y constant density that were used before also apply here. For this system, Eq. (5.2) still applies, but q. (t) is now a constant; thus WM) — qo = 7s (5.15) 2 dt FIGURE 5-3 At steady state, Eq, (5.15) becomes Liquid-level system with constant outlet flow. qs — qo = 0 (5.16) Subtracting Eq. (5.16) from Eq, (5.15) and introducing the deviation variables Q = q - q: and H =h-hs give o=4= (5.17) Taking the Laplace transform of each side of Eq. (5.17) and solving for H/Q give HO) 2 1 (5.18) Qs) As Notice that the transfer function 1/ As in Eq. (5.18) is equivalent to integration. (Recall from App. 3A that multiplying the transform by s corresponds to differentiation of the function in the time domain, while dividing by s corresponds to integration in the time domain.) Therefore, the solution of Eq, (5.18) is lee ho) = he + 5 f,owae (5.19) Clearly, if we increase the inlet flow to the tank, the level will increase because the outlet flow remains constant. The excess volumetric flow rate into the tank accumulates, and the level rises. For instance, if a step change Q (t) =u (t) were applied to the system shown in Fig. 5-3 the result would be A(t) = hs + tlA (5.20) The step response given by Eq. (5.20) is a ramp function that grows without limit, Such a system that grows without limit for a sustained change in input is said to have nonregulation, Systems that 6 4 class Contra pracess and dynamic have a limited change in output for a sustained change in input are said to have regulation. An example of a system having regulation is the step response of a first-order system, such as that shown in Fig. 5-1. Ifthe inlet flow to the process shown in Fig. 5-1 is increased, the level will rise until the outlet flow becomes equal to the inlet flow, and then the level stops changing. This process is said to be self-regulating, The transfer function for the liquid-level system with constant outlet flow given by Eq. (5.18) can be considered as a special case of Eq. (5.8) as R 00. 1 im([45)-+ Row\ ARs +1 As Mixing Process Consider the mixing process shown in Fig. 5-4 in which a stream of solution containing dissolved salt flows at a constant volumetric flow rate q into a tank of constant holdup volume V. The concentration of the salt in the entering stream. x (mass of salt/volume) varies with time. It is desired to v0 determine the transfer function relating the outlet (7). concentration y to the inlet concentration x. IF we assume the density of the solution to be constant, the flow rate in must, equal the flow rate out, since the holdup volume is fixed. We may analyse this system by writing a transient mass balance for the salt; thus FIGURE 5-4 Mixing process. (h rate *) (re rate °*) _ (* of wea) salt in salt out of salt in tank Expressing this mass balance in terms of symbols gives, d(Vy) dy Vv (5.21 dt dt : qx — gy We will again introduce deviation variables as we have in the previous examples. At steady state, Eg. (5.21) may be written qXs — qys = 0 (5.22) Subtracting Eq. (5.22) from Eq. (5.21) and introducing the deviation variables, Xmx-x Y=y-ys 4 class Contra pracess and dynamic Give dy Taking the Laplace transform of this expression and rearranging the result give Ys) 1 Xs) ts +1 (5.23) where t= Vig. This mixing process is, therefore, another first-order process for which the dynamies are now well known. Heating Process Consider the heating process shown in Fig. 5-5. A stream at temperature Tris fed to the tank. Heat is added to the tank by means of an electric heater. The tank is well mixed, and the temperature of the exiting stream is 7, The flow rate to the tank is constant at w Tbh. A transient energy balance on the tank yields Rate of Rate of Rate of Rate of energy flow || energy flow | + | energy flow in | = | accumulation of into tank out of tank from heater energy in tank Converting this energy balance to symbols results in wC(%; — Tre) — wC(T = Tet) + q = pve dl = Ter) = prete (5.24) dt dt where Tyr is the reference temperature and C is the heat capacity of the wT fluid. At steady state, dTdt is zero, and Eq, (5.24) can be written FIGURE $-S wC(Tis — T) + qs = 0 (5.25) where the subscript s has been used 10 indicate steady state. Subtracting Eq, (5.25) from Eq, (5.24) gives a(t -T = pvc ar = Ty (5.26) wC(Ti — Tis) — wC(T — 1.) + q - 7 Eq. (5.26) becomes 4 class Contral pracess and dynamic If we assume that 7; is constant (and so 7; = Tis) and introduce the deviation variables Eq, (5.26) becomes dT” -wCT’ + Q = pvc (5.27, dt : Taking Laplace transforms of Eq, (5.27) gives -wCT'(s) + O(s) = pVCsT“(s) (5.28) Rearranging Eq, (5.28) produces the following first-order transfer function relating T (s) and Q (J: Toe I We Cie a Os) (pViw)s+1 tet] (5.29) Thus, this process exhibits first-order dynamics as the tank temperature T responds to changes in the heat input to the tank. Example 5.2. Consider the mixed tank heater shown in Fig. 56. Develop a transfer function relating the tank outlet temperature to changes in the inlet temperature. Determine the response of the outlet temperature of the tank to a step change in the inlet temperature from 60 to 70 °C. Before ‘we proceed, intuitively what would we expect to happen? If the inlet temperature rises by 10 °C, we expect the outlet femperature to eventually rise by 10 °C if nothing else changes. Let’s see what modelling the process will tell us. From Eq, (5.26) we can write the following simplified balance, realizing that q- qs: ane d(T ~ Ts) 200 Limin wC(T; — Tis) — wC(T i) = pyc—— aes In terms of deviation variables, this becomes ’ aT’ vCT; — wCT’ = pVC— 7 " e dt Heat input q FIGURE 5-6 Mixed tank heater. 4 class Contral pracess and dynamic Transforming, we get wCTs) — wCT(s) = pVCsT(s) and finally, after rearranging, Ts) 1 1 f(s) (pViw)s +1 ts +1 Substituting in numerical values for the variables, we obtain the actual transfer function for this mixed tank heater. V_ tank volume __1,000L v volumetric flow rate 200 L/min Ts) __1 Ts) Ss+1 If the inlet temperature is stepped from 60 to 70°C, Tf(Q) = 70 — 60 = 10 and Ti(s) = 10/s. Thus, ro- (1) s\5s+1 Inverting to the time domain, we obtain the expression for T (V. T(H = 10(1 - e"’’) and finally, we obtain the expression for 7'(r), the actual tank outlet temperature. Ti) = + TH = 80+ 1o(1 - tls) A plot of the outlet temperature (in deviation variables) is shown in the Fig. 5-7 a. The actual outlet temperature is shown in Fig. 5-7 b. Note that for the uncontrolled mixing tank, a step change of 10°C in the inlet temperature ultimately produces a 10 C change in the outlet temperature, just as we predicted, intuitively before we began our modelling. This result is just what we expected. 10 4 class Contra pracess and dynamic Outlet temperature CC) ‘etal cet temperature CO) seviation variables 89) ss a / 8 / 2 f 81 5 10 15 20 2s G 25 Time (nin) @ FIGURE 5-7 (a) Tank outlet temperature (deviation variable); (b) actual tank outlet temperature. In summarizing the previous examples of first-order systems, the time constant for each has been expressed in terms of system parameters; thus mC T=—— for th ter, Eq. (4.5 TA ‘or thermometer, Eq. (4.5) t= AR for liquid-level process, Eq. (5.8) poe for mixing process, Eq. (5.23) q pv : r=" for heating process, Eq. (5.29) w 5.2 LINEARIZATION Thus far, all the examples of physical systems, including the Tiquid-level system of Fig. $1 , have been linear. Actually, most physical systems of practical importance are nonlinear Characterization of a dynamic system by a transfer function can be done only for linear systems (those described by linear differential equations). The convenience of using transfer functions for dynamic analysis, which we have already seen in applications, provides significant motivation for approximating nonlinear systems by linear ones. Avery important technique for such approximation is illustrated by the following discussion of the liquid-level system of Fig. 5-1 Bt 4 class Contra pracess and dynamic We now assume that the flow out of the tank follows a square root relationship qo = Ch? (5.30) where C is a constant. For a liquid of constant density and a tank of uniform cross-sectional area 4, a material balance around the tank gives dh 0 gol = AS 531 WD ~ 4 dt (5.31) Combining Eqs. (5.30) and (5.31) gives the nonlinear differential equation dh - cH? = at 5.32 q dt ¢ ) At this point, we cannot proceed as before and take the Laplace transform. This is due to the presence of the nonlinear term h', for which there is no simple transform. This difficulty can be circumvented by linearizing the nonlinear term. By means of a Taylor series expansion, the funetion q, (h) may be expanded around the steady- state value fis; thus 40 = alle) + 4h (hah he) + EGA HP where go(hs) is the first derivative of qo evaluated at hs, q% (hs) is the second deriva- tive, etc. If we keep only the linear term, the result is qo = qo(hs) + qo(hs)(h — hs) (5.33) Taking the derivative of go with respect to h in Eq. (5.30) and evaluating the derivative at h = hs give gills) = 40K” Introducing this into Eq. (5.33) gives 1 lo = Go, + —(h ~ hs 5.34) fo = qo, + Bt ) (5.34) 12 4 class Control process and dynamic oe where go, = go (is) and WR, = +Ch, Substituting Eq. (5.34) into Eq. (5.31) gives hohe _ gdh Ri ae (5.35) 9 G, ~ At steady state the flow entering the tank equals the flow leaving the tank; thus Gs = qo, (5.36) Introducing this last equation into Eq. (5.35) gives gh Ba (537) a’ Ri Introducing deviation variables Q = q — q and H = h ~ hy into Eq. (5.37) and trans- forming give (5.38) where 2hs!? R= co T=RA Introducing this last equation into Eq. (5.35) gives dh | h—he agi oe 5.37 aR! * ee Introducing deviation variables Q = qs and H = h~ h, into Eq. (5.37) and trans- forming give Ho) __ 8) Os) ts+l where 2hs!? R==l- T= RA 13 4 class Contra pracess and dynamic We see that a transfer function is obtained that is identical in form with that of the linear system, Eq, (5.8). However, in this case, the resistance Ri depends on the steady-state conditions around which the process operates. Graphically, the resistance R; is the reciprocal of the slope of the tangent line passing through the point (gos, hs), as shown in Fig. 5.8 o—— Tangent line % ope = b= Hoh) Slope = > ath Nonlinear resistance 4% tas 9 FIGURE 5-8 Liquid-level system with nonlinear resistance. Furthermore, the linear approximation given by Eq. (5.35) is the equation of the tangent line itself. From the graphical representation, it should be clear that the linear approximation improves as the deviation in h becomes smaller. If one does not have an analytic expression such as A” for the nonlinear function, but only a graph of the function, the technique can still be applied by representing the function by the tangent line passing through the point of operation. Using MATLAB to Compare Nonlinear (Exact) Solutions and Linearized Solutions For the tank draining models of Eqs. (5.32) and (5.38) we have the following systems Nonlinear model q- ch? aa (5.32) - H(s) Ri = 5.38 Linearized model mB) Sem (5.38) Where ant a = 2 c T=RA Consider the case where A 3 fi? and the steady-state height is 4 ft when the inlet flow is 16 cfm. Compare the linearized and nonlinear (exact) solutions for the transient response of the tank height toa step change in feed flow from 16 to 20 cfm. Solution 14 4 class Contra pracess and dynamic From Eq. (5-30) v2 los = Ch, 16 cfm = C(4 fr)? Thus, C = 8 cim/f'” and Ri 2ny? 24 ft ft 0.5 iG 8 cfm/ft!? cfm =RA= (ost Jo fC) = 1.5 min cfm Substituting the numerical values into the nonlinear model, Eq. (5.32), yields 20 — svi = 3 h(O) = 4 ft The MATLAB m-file necessary to simulate this equation is shown below function hprime=level(t,h) hprime = A. hprime=(20-8*sqrt(h))/3; This file calculates the derivative dh/at at any given t and h. We call the m-file using the numerical differential equation solver ODE4S, [teh] = ode45(level' , [0,10] , [4] ): >> [th] = odess(elevel , (0.10). (4) Matrices that MATLAB | | m-filelevelm span... || initial condition you want the routine to || contains the || nist €0 ts RO answers returned || numerically model ‘correspond to into. solve ODE ‘ita The linearized model, with numerical values substituted in, is H(s) _ 0.5 Qs) 15841 H=h-4 @Q=q~16 deviation variables H(s) = (3) os ) ——— s} \ss+1) ~ sass+0 step change Oby4efm 15 4 class Contra pracess and dynamic Inverting gives — 9() — ont/ls HQ = 21 —e"*) linearized solution W(t) = 4 + 2(1— e""15) Entering this equation into MATLAB yields hhlin = 4 + 24(1 - exp (A/1.5)); plot(t,h,hlin); xlabel(‘Time'); ylabel(h title(Comparison of Nonlinear and Linearized Solutions’); The full program in Matalb syms st YH % solve q-C*h*0.5= A* dh/dt;% Nonlinear model Eq.(5-32) % H(s)=Q(s)* (R1/n*(s+1)) %n=tau Eq.(5.38) 2f((1.5%842) +5); %6Y(5)=H(s) laplace (Y(s}) %6Y(t)=H(t) 36h(t)=4+H(t) 1de45(‘level’ , [0,10] , [4] }; At}=44y(t) S6h(t)=hlin=a+H(t) 4+Y(t); % h1=4 + 2*(1 - exp (+t/1.5)); plot(t,h,t,hlin); xlabel"Time'); ylabel('h’}; title(‘Comparison of Nonlinear and Linearized Solutions’); 16 4 class Contra pracess and dynamic 5 Combarison of Nonlinear and Linearized Solutions Wontinear | Linearzed 6 = 55 © 5 ast / 4 ° 2 4 6 8 10 Time FIGURE 5-9 Comparison of nonlinear and linearized solutions for tank draining In general, the linearization of a nonlinear function is accomplished using a Taylor series expansion truncated to include only the linear terms. Thus for a single variable function ff f(x) = f (xs) + (x — x5) + (higher-order terms) (5.39) dx For functions of two variables, we have S(x,y) = f(%s,¥s) + of @- Xlixsays) + (higher-order terms) Consider the differential equation describing the dynamics ofa system dy 2 oo (5.41) Linearizing the nonlinear term gives dy af| = + fs)t+=| Y- ys) = ar * 0) ay), ey) (5.42) —_*__ ncarized approximation 7 4 class Contra pracess and dynamic Writing this equation again for the steady-state case gives dys of| at POs) + y O's — Ys) = Xs (5.43) vs Subtracting the steady-state case in Eq. (5.43) from Eq. (5.42), we can convert the original differential equation to deviation variables: Wy) A) Wy) ax dt a — ys) = x — Xs dY cies = dt = where X= x- x, and Y¥ = y- ys, Note that the f (ys) term is eliminated in the process of forming deviation variables, and we are left with only linear terms in the equation which is now amenable to solution using Laplace transforms, TAYLOR SERIES EXPANSIONS FOR LINEARIZING NONLINEAR TERMS Functions of a single variable: f(x) = f(xs) + Functions of two variables: foxy) = (er) +2] (eau) 3 -») *V(xs.9s) 18 4* class: Contra pracess and dynamic Here are some physical examples of first-order systems: System ‘Transfer function 4 Ve Figure S-1 Ls Hk = level system Ay ” Os) ARs +1 Wd xo 7 v ieee Figure S4Mixing = Y0) process X@) ~ igs = 0 Steam or cleetricity Figure 5-5 Heating 78) __ Mw) " process 065) (pPiw)s +1 wT readin * x= fluid temperature Figure 41a Yo) 1 ‘Thermometer X(s) — (methA)s +1 Mercury Glass wall 19

You might also like