Solution: Homework Biomedical Signal, Systems and Control (BME 80.) Instructor: René Vidal, E-mail: rvidal@cis.jhu.edu TA: Donavan Cheng, E-mail: donavan.cheng@gmail.com TA: Ertan Cetingul, E-mail: ertan@cis.jhu.edu April, 008. (0 points) Modeling glucose metabolism Glucose metabolism can be represented by the two compartment model shown below. Glucose enters gastrointestinal (GI) tract and gets absorbed into the bloodstream where it is metabolized. A rabbit is fed with glucose. Let the concentration of glucose in the GI tract and bloodstream at time t be x (t) and x (t) respectively, and let the rate of glucose ingestion be z(t). Assume the volume of the two compartments are both liter. Also assume that there is a negligible amount of glucose in the bloodstream and GI tract before the oral dose. z(t) GI tract λ Blood λ (a) Let us assume glucose is absorbed into the blood stream at a rate in proportion to x (t) with a proportionality constant λ. Meanwhile, glucose is metabolized at a rate in proportion to x (t) with proportionality constant λ. Set up the differential equations for x (t) and x (t). (b) In this system, x (t) and x (t) are the internal states, and the system output is y(t) x (t). Find the transfer function of this system. (Hint: are the solutions the same for λ λ and λ λ?) (c) Now let us only consider the case λ λ. What is the output y(t) if the input is z(t) δ(t)? When does the blood glucose concentration reach a maximum? Answer: (a) The differential equations are: ẋ (t) λ x (t) + z(t), ẋ (t) λ x (t) + λ x (t). (b) Assuming no glucose in GI or blood at t 0, i.e., zero initial conditions, take the Laplace transform of the differential equations We can write (s) X (s) sx (s) λ X (s) + Z(s), sx (s) λ X (s) + λ X (s). λ (s+λ )(s+λ ) Z(s), and H(s) (s) Z(s) λ ( λ )( λ ). If λ λ λ H(s) ( λ ).
(c) First do partial fraction expansion to H(s) H(s) λ ( λ )( λ ) A λ + A ( λ )H(s) s λ λ λ λ B ( λ )H(s) s λ λ λ λ The response to z(t) δ(t) is the impulse response h(t) B λ h(t) L (H(s)) λ λ λ (e λt e λt )u(t), where u(t) is the step function. ou can ignore the step function term in h(t) but in that case you have to specify that t 0. The extremum point is obtained at t ˆt where dh 0, i.e., dt tˆt dh dt λ ( λ e λˆt + λ e λˆt ) 0 λ e λˆt + λ e λˆt 0. () tˆt λ λ Take logs of both sides and solve Eqn. () for ˆt, i.e., ˆt λ λ log. (0 points) Find the Laplace transform and region of convergence of the following time functions: (a) f(t) t sin t (b) f(t) t sin t t cos t (c) f(t) (t) + t cos t (d) f(t) sin t sin t (e) f(t) sin t + cos t ( λ Answer: Note that we always take unilateral Laplace transform defined for t 0 (a) Use multiplication by time Laplace transform property, i.e., L{tg(t)} d dsg(s). Let g(t) sin(t) and use L{sin(at)} a s +a, λ ). L{t sin(t)} d ds s + s (s + ) s s + s +. Note that for Re{s} > 0, e st t sin(t) 0 as t. So the region of convergence (ROC) is Re{s} > 0. (b) Using the following properties of the Laplace transform L{tg(t)} d ds G(s), L{sin(at)} L{cos(at)} a s + a, s s + a,
we can calculate (c) L{f(t)} L{t sin(t)} L{t cos(t)} d [ ds s d ] s + 9 ds s + 6s (s + 9) (s ) (s + ) s6 + 6s s + s 6s + 6 6 (s + 9) (s + ). Note that for Re{s} > 0, e st (t sin(t) t cos(t)) 0 as t. So the region of convergence (ROC) is Re{s} > 0. L{f(t)} L{(t)} + L{t cos(t)} [ d ] s ds s + [ s ] s + (s + ) 0s + 8 s(s + ) Note that for Re{s} > 0, e st ((t) + t cos(t)) 0 as t. So the region of convergence (ROC) is Re{s} > 0. (d) Using the trigonometric relation we have sin(αt) sin(βt) cos( α β t) cos( α + β t), with α and β, f(t) cos( t) cos( + t) cos(t) cos(t) L{f(t)} L{cos(t)} L{cos(t)} s s + s s + 6 6s (s + )(s + 6) Note that for Re{s} > 0, e st sin(t) sin(t) 0 as t. So the region of convergence (ROC) is Re{s} > 0. (e) Using the trigonometric relations sin (t) cos(t) and cos (t) + cos(t),
we have f(t) cos(t) + cos(t) L{f(t)} L{} + L{cos(t)} s s + 8 s(s + ) [ ] + cos(t) + Note that for Re{s} > 0, e st (sin (t) + cos (t)) 0 as t. So the region of convergence (ROC) is Re{s} > 0.. (0 points) Find the time function corresponding to each of the following Laplace transforms using partial fraction expansions: (a) F (s) s+ s +s+0 (b) F (s) (s+) (s+)(s +) (c) F (s) s+ s (d) F (s) s+ s 6 (e) F (s) (s+)(s+) (s+)(s +) Answer: (a) Rewrite and carry out partial fraction expansion, (b) F (s) s + 0 [ ( ) ] ( ) + ( ) ( ) + ( ) + f(t) L {F (s)} e t cos(t) e t sin(t), t 0. F (s) C ( ) ( )(s + ) C + C C s + ( ) s + s After equating the coefficients of s, s, and in the numerator we obtain 8 + C s + (C + C ) + C 8 + C C C + C C.
We then get F (s) (c) Perform partial fraction expansion, + s + + s s + + 6 s + f(t) e t cos(t) + 6 sin(t), t 0. F (s) s s + (s )(s + ) C s + C C s + C (s )F (s) s s + s s + C C s + s + (s )(s + ) After equating the coefficients of s, s, and in the numerator we obtain s + C + s C + C + C s + We then get F (s) (d) Carry out partial fraction expansion, s + s + s + ( + + C C C C ) f(t) L {F (s)} et + e t cos F (s) s 6 A (s )F (s) s ( ) t, t 0. A s + B + C D s + B ( )F (s) s
After equating the coefficients of s, s, s, and in the numerator we obtain s ( + + C) + s ( + D) + s( + C) + ( D) S + f(t) L {F (s)} et + e t + cos(t) sin(t), t 0. Alternate solution: F (s) s 6 C C s + C C s + + + C C + D 0 D s + s s + f(t) L {F (s)} cosh(t) + sinh(t) + cos(t) sin(t), t 0. (e) Perform partial fraction expansion F (s) ( )( ) ( )(s + ) A + B C s + + D E (s + ) A ( )F (s) s.80 After equating the coefficients of s, s, s, s, and in the numerator we obtain s ( + B) + s (B + C) + s ( 6 + B + C + D) + s(b + C + D + E) + ( + C + E) s + 90 00 + B 0 B.80 We then get 6 F (s).80.80.8.6 66. + s + + (s + ) B + C C 8.8 + B + C + D D 90.6 B + C + D + E 90 E 660 66. f(t).8e t.80 cos(t) +.60 sin(t) + 7.8t sin(t) +.τ sin(τ)dτ, 0.8e t.80 cos(t) +.60 sin(t) + 7.8t sin(t) 6.6t cos(t) + 8. sin(t), f(t).8e t.80 cos(t) + 9.90 sin(t) + 7.8t sin(t) 6.6t cos(t). t 6
Alternate solution: Expand in partial fraction expansion F (s) ( )( ) ( )(s + ) C + C s j + C j + C (s j) + C ( j) C ( )F (s) s.80 C (s j) F (s) sj.0 j.90 C C.0 + j.90 C d [ (s j) F (s) ] sj ds C C 0.6 + j.89 8 79j 00 ou can use Matlab function residue to check the results. We then have 0.6 j.89 f(t).8e t + C cos(t + arg(c )) + C t cos(t + arg(c )).8e t +.9979 cos(t.788) + 9.706t cos(t.70), where C.9689, C.8, and.89.90 arg(c ) tan.788, arg(c ) tan 0.6.0. (0 points) Solve the following ordinary differential equations using Laplace transforms: (a) ÿ(t) + ẏ(t) + y(t) 0; y(0) ; ẏ(0) (b) ÿ(t) + ẏ(t) sin t; y(0) ; ẏ(0) (c) ÿ(t) + ẏ(t) e t ; y(0) ; ẏ(0) Answer: (a) Use the differentiation Laplace transform property to get We then get (s) s (s) sy(0) ẏ(0) + s (s) y(0) + (s) 0. s + + + ( y(t) e t cos ) + ( t + ) (b) Use the differentiation Laplace transform property to get ( ) + + e t sin ( t s (s) sy(0) ẏ(0) + s (s) y(0) s +. ), t 0..70. 7
We then get and match coefficients of to obtain s ( + C (s) s + s( )(s + ) C C + C C s + C s + ( )(s + ) s0 C s + s(s + ) s ) + s ( + C + C ) + s + C + s + s + C + C, C + C. So y(t) becomes y(t) e t cos(t) sin(t), t 0. (c) Use the differentiation Laplace transform property to get We then calculate s (s) sy(0) ẏ(0) + s (s) y(0) s. (s) s + s s(s )( ) C C s + C s + s C (s )( ) s0 C s s( ) s C s s(s ) s 6 (s) s 6 [ y(t) + et ] 6 e t u(t).. (0 points) Find the transfer functions for the block diagrams in Figure. The special structure in Figure (b) is called the observer canonical form. Answer: (a) The block diagram in Figure can be simplified to the diagram in Figure with G and G such that G G and G G. G H G H 8
06 CHAPTER. DNAMIC RESPONSE 0. Find the transfer functions for the block diagrams in Fig.., using the ideas of block diagram simpli cation. The special; structure in Fig.. (b) is called the observer canonical form and will be discussed in Chapter 7. R R S G S G S b b b H S G S Figure : Block a a a diagrams for Problem H s S s S s (a ) ( b ) R b b b S s S Then the transfer function can be written as a s S s R G ( + G ) + G ( + G )G a G ( G H )( G H ) + G G ( G H ) a. ( c ) + ( G H )( G H ) + G G ( G H ) + G G G R ( s ) S A ( s ) S B ( s ) S ( s ) (b) We move the summing junction on the right past the integrator to get b s and repeat to get (b + b s)s. H ( s ) Meanwhile we apply the feedback rule to the first inner loop to get s+a and repeat for the second and G ( s ) third loops to get the simplified block diagram (d ) in Figure and the transfer function: Figure.: [Text Fig..] Block diagrams for Problem.0 D ( s ) R b s + b b s + a s + a a. (c) Applying block diagram reduction (see Figure ) i.e., reduce innermost loop, shift b to the b node, reduce Solution: next innermost loop and continue systematically to obtain: Part (a): Transfer functions found using the ideas of Figs..6 and.7: (a) (a) Block diagram for Fig.. (a). Figure : Simplified block diagram for Problem (a) 9
R G ( + G ) G ( G H )( G H ) + G G ( G H ) + G ( + G : )G + ( G H )( G H ) + G G ( G H ) + G G G (c) Block diagram for Fig..(c). (b) We move the summer on the right past the integrator to get b s and repeat to get (b + b s)s. Meanwhile we apply the feedback rule to the rst inner loop to get as shown in the gure and repeat for s+a the second and third loops to get: (b) Block diagram for Fig..(b). Figure : Simplified block diagram for Problem (b) R b s + b b s + a s + a a : (c) Applying block diagram reduction: reduce innermost loop, shift b to the b node, reduce next innermost loop and continue systematically to obtain: (c) Block diagram for Fig..(c). Figure : Simplified block diagram for Problem (c) R b s + (a b + b ) a b + a b + b s + a s : + a a R b s + (a b + b ) a b + a b + b s + a s. + a a 09 (d) (d) The simplified block diagram is depicted in Figure and the transfer function can be written as: (d) Block diagram for Fig..(d). Figure : Simplified block diagram for Problem (d) R D + AB + G(D + AB ) D + DBH + AB + BH + GD + GBDH + GAB. 0 D + AB D + DBH + AB