You are on page 1of 459
COMPLETE SOLUTIONS MANUAL FOR ANALOG AND - DIGITAL SIGNAL PROCESSING SECOND EDITION ASHOK AMBARDAR Complete Solutions Manual for Analog and Digital Signal Processing Second Edition Ashok Ambardar Michigan Technological University Brooks/Cole Publishing Company I@P? An Intemational Thomson Publishing Company PacificGrove + Albany * Belmont + Bonn + Boston + Cincinnati + Detroit + Johannesburg * London Madrid + Melboume * MexicoCity + New York + Paris * Singapore + Tokyo + Toronto + Washington COPYRIGHT © 1999 by Brooks/Cole Publishing Company A division of International Thomson Publishing Inc. IDP The ITP logo is a registered trademark used herein under license. For more information, contact: BROOKS/COLE PUBLISHING COMPANY 511 Forest Lodge Road PacificGrove,CA 93950 USA International Thomson Publishing Europe Berkshire House 168-173 High Holbom London WC1V 7AA England ‘Thomas Nelson Australia 102Dodés Street South Melbourne, 3205, Victoria, Australia Nelson Canada 1120Birchmount Road Scarborough, Ontario (Canada M1K 5G4 Japan International Thomson Editores Seneca 53 Col. Polanco 11560 México,D.F, México International Thomson Publishing GmbH KGnigswinterer Strasse 418 53227 Bonn Germany International Thomson Publishing Asia 60 Albert Street #15-01 Albert Complex Singapore 189969 International Thomson Publishing Japan Palaceside Building, SF I-l-1 Hitotsubashi Chiyoda-ku, Tokyo 190-0003, All rights reserved. Instructors of classes using Analog and Digital Signal Processing, 2nd Ed., by Ashok ‘Ambardar, asa textbook may reproduce material from this publication for classroom use, Otherwise, the text ofthis publication may not be reproduced, stored in a retrieval system, or transcribed, in any form or by any means— electronic, mechanical, photocopying, recording, or otherwise—without the prior writen permission ofthe publisher, Bropks'Cole Publishing Company, Pacific Grove, California 93950. You can request permission to use material from this text through the following phone and fax numbers: Phone: 1-800-730-2214 Fax: 1-800-730-2215 Printed in the United States of America 543 ISBN0-$34-37039.X CONTENTS A NOTE TO THE INSTRUCTOR USEFUL MATHEMATICAL RELATIONS Chapter Chapter Chapter Chapter Chapter Chapter Chapter Chapter Chapter 10 Chapter 11 Chapter 12 Chapter 13 Chapter 14 Chapter 15 Chapter 16 Chapter 17 Chapter 18 Chapter 19 Chapter 20 ANALOG SIGNALS DISCRETE SIGNALS ANALOG SYSTEMS DISCRETE-TIME SYSTEMS CONTINUOUS CONVOLUTION DISCRETE CONVOLUTION FOURIER SERIES ‘THE FOURIER TRANSFORM MODULATION THE LAPLACE TRANSFORM APPLICATIONS OF THE LAPLACE TRANSFORM ANALOG FILTERS SAMPLING AND QUANTIZATION THE DISCRETE-TIME FOURIER TRANSFORM THE DFT AND FFT THE z-TRANSFORM APPLICATIONS OF THE z-TRANSFORM MIR DIGITAL FILTERS FIR DIGITAL FILTERS < 26 45 65 92 1a 131 187 190 200 219 235 269 ~287 319 380 418, A Note to the Instructor ‘This manuel contains solutions to all the end-of-chapter problems in the second edition of the text Analog and Digital Signal Processing. ‘Trivial algebraic details have, for the most part, been omitted (in order to highlight the solution methods) and numerical answers, where applicable, have been rounded (typically, to four places after the decimal). ‘We have used MATLAB to solve the design/computation problems. The MATLAB code is by no means ‘unique, no attempt was made to optimize it, and it is included only to give an indication of the expected results (even though few plots have been reproduced). Routines fom the ADSP toolbex (from the text) that were used for solving the problems are listed in the solutions, where appropriate. ‘The mefiles corresponding to the MATLAB code for the design/eomputation problems are also supplied on the accompanying disk in the subdirectory SOLUTION (as chXpY.m where X is the one/two digit chapter number and ¥ is the one/two digit problem number). These fles may be run without modification (for MATLAB v4ix ot higher) or edited/expanded to suit your own needs. This disk also contains updated versions of the foliowing m-fles (with extension (that comes with the text). These files reside in the subdirectory UPDATES. in the ADSP toolbox FILE UPDATED FEATURES ustep,afd.Jpp ADSP files. Fixed bug for elliptic filter design acergui, deztede GUI files. Fixed bug to catch callback errors efirdes ,dfirauop GUI files. Fixed bug to catch callback errors fegui,tepit,tesyaplt cur Fixed bug to catch callback errors ctoesplt ,dteiggen our . Fixed bug to catch callback errors Installation 1. Copy the solutioi files to a subdirectory on the hard drive (say solution) where MATLAB resides. 2. Copy the updated ADSP toolbox files over the already existing files in the subdirectories for the ADSP toolbox (Chapter 21 of the text describes the installation of the ADSP toolbox). 3. Add the names of these subdirectories to the MATLAB path. 4, Start MATLAB. To run a file say ch3p44.m, just enter its filename without the extension (ch3p44). If you catch any errors in the text or in the solutions manual, or discover any bugs in the software, we ‘would like to hear from you. Any errata for the text and the solutions manual that comes to our attention, ‘and eny upgrades to the software (including the files listed above) will appear on our Internet site Ashok Ambardar Michigan Technological University Internet site: http://vev.ce.mtu.edu/faculty/akenbard. htal e-mail: akanbardéntu.eda USEFUL MATHEMATICAL RELATIONS EULER’S IDENTITY eH? = cos Ot jin? eH = cos(km) ALSO = Aeti® eta 4g TRIGONOMETRIC IDENTITIES sina = eos(—§) cosa = sin(a+-§) sin(a = A) = sinacos6 x eosasinp || cos(a + 6) = cosa.coe pF sinasing sin2a = 2sinacosa 08 2a = 2eos?a — 1 cosas 1—2ein'a cos2a = cova — sina INDEFINITE INTEGRALS fsstas)de= = 2222 | f cosas) tz = 22) [ra J ssin(ae) de Sales) —azes(en) [eon de = Se) states) | [awe aE PEN | mer, ee sin(br) +6 cos(bz) ae| 200s(bz) — bsin(bz) [evstines-oo eR P=] | DEFINITE INTEGRALS OVER (0, 0) meat ma a ede =? fe cos(ta) dr = 2 | [ten [ eo sina) de = ~ f wana neo [ie caties? nese) sin(az) = 7 —— [irmaeirent(S-as) = mel, i ou =a ie TeEE® aR fen a aa tase ‘Bab fw =a sin(’2) 02 ge = Mtan~i(? ete? VR /(Q2a), n=O Sem uc=tan(2), aro are de = “1i(002), I ' : (0 f vais), USEFUL MATHEMATICAL RELATIONS SEQUENCES AND SERIES aa 1 Le allan ie scaaa scious FINITE SUMS WEOSFD gcd a Da ae 5 Sata -{ SSIBSHD sinfZ(V + 1)a], A 2mm (m~=0,1,2..) i 9, 2=2mn (m=0,1,2,...) W 7 Tesi) are YP = prev syewsy Sot =| SESHD cos[(N + 1)z], 2 # 2mm (m=0,1,2,...) et a My, seamen (m=0,12,-.) | Seal ark: _ Sin[(2N + 1)ra] sine[(2N +1) x = pews y om Se +1) et al Site belt, ax “i afl ie N41, an1 |G 4N(N +2), a=t SEQUENCES AND SERIES aain(z) lal <1 Doet sults) = Tan casla) FP lol <1 Sat @eos(2)— oF x fact Detedi= eee bl? “acos(z) [Zit asa ape els | Lets) = EA alt : ata ea sin(kz) _ 4 Leta ge ict | SB) yey, ceca | x eat tee, aa |e =4a(n-2), O O and find the power as P = 0.5((0.5)(2)? + (0.5)(4)") =8 = 0.5(0.5)(2)? + 0.5(2)? 3. 2—u(t). Split this into two switched, non-overlapping components 23(t) = 2, ¢ <0 and 1, t>0. Then, P = 0.5(2 41°) = 25 4 Chapter 2 Analog Signals 2.26 (Solution) (@) 2) u(t): = eM dt = 0.25 ) aie) eel): Beet fear w ose? mace (©) 2(?) = e-l-8u(1 —1) isa folded version of e~tu(t). $0, B= [eat = 05 te 1 vuutanennaie 5s f° tba (@) a(t) = eb#tu(t — 2) = ete-20-M UA 2). S0 (from part c and compression), E = 0.25¢8 = 100.8872 (©) 2(t) = e“-*u(1 ~ 2t): From part ¢ (and compression), E = 0.25 (f) x(t) = etu(—t ~ 2) = e~2e-(-!-2)u(—t ~ 2). The energy in e~(-*-)u(~t ~ 2) is the same as the energy in e~tu(#) (because folding and shifting do not change the energy). So, E = 0.5e~* = 0.0092. = You could aso ertuate B= feat (g) 2(t) = el!“ is a two-sided growing exponential (so neither power signal nor energy signal). (b) 2(t) = sino(3t — 1): So, B= a sinc?(3t) et = @® 2 en, Ef vf dt = 200.8) = VF = 1.7725 2.27 (Solution) (@) 2(6) = u(t): Switched, power signal, P = 0.5 (because power in de signal y(t) = 1 is 2). (b) 2(t) =1+ u(t): Switched power signal. z(t) =1, t <0 and a(t) = 2, 1 >0. So, P=0.5(1? +2) = 25 He 2 |" (6) a0) = job Bown sia, B= Eoaremr’~ 2f tee Sf - = (0.257) (from tables) = 1.5708 (2) x= Bae am 22 [7 asap (e) x(t) =1+ cos(xt)u(t): Power signal. x(t) =1, t <0 and 2{t) = 1+ cas(xt), t > 0. So, P = 0.5(1) + 0.5(1 +0.5) = 1.25 Ghapter 2 Solutions to Problems 15 (0 z= > #21. Not an energy signal (22(t) decays as 1/t and not any faster) Dots poe igual anne P= [Eat 1 ae (© 2) =F, 121 nary signa B= (h) 2(¢) = cas(sthu(t): Switched power signal. = 0.5(0.5) = 0.25. G) x(t) = cos(xt)u(t) — cos[n(t — 4)Ju(t ~ 4): Energy signal. ‘This corresponds to 2 periods (4 hhalf-cycles) of a sine with T = 2. Esch half-cycle has unit width and height= 1. So (Review Pane! 2.2), E = 4(0.5)(1)"(1) = 2 SS 2.28 (Solution) The product of two periodic signals with periods T; and To will be periodic if T; and Ts are commensurate. To see this consider a(t) = 2sin(2nt/T;) cos(2xt/Ta) = sin[2nt(T; + T2)/TiTa) — sin[2xt(T, — T2)/TrT] ‘This is periodie only if (T; + T2)/T\TZ2 and (7; ~Tz)/T:T are commensurate, So, Ty and T; must be rational fractions in order for their sum, difference or product to be rational fractions. 2.29 (Solution) In the following, 2(t) = e/%*/+t ig periodic with period T= 1/f. (a) v(t) = 2(2t) +32(0.5t): The frequencies are fi = 2fo and fo = 0.5fo. So, v(t) is periodic with fimdamental frequency = GCD(fi, fa) = 0.5fo and period 27° (b) f(t) = 22!" 4 sed; So, fy = 8 He and fo =3.5 He. So, fundamental frequency = GCD( fx, fa) = 0.5 Ha and period = 2. (©) 1 the signal o(t) = 4e/38* — 50~"*t: Not periodic (the second term is a decaying exponential). (4) Is the signal h(t) = Sef®** — 2e~7"; The second term is a constant. So, fundamental frequency = § Hz and period = 0.125 s. : (@) Is the signal s(t) = S> X[Aje™*¥**. Frequencies are multiples of fo. tee So, periodic with fundamental frequency = fo and period T= 1/fo- 2.80 (Solution) See sketches below. (a) 7 re (a) ufsin(nt)} To sketch, note that ulf(t)] is 0 if f(t) < 0 and +1 if f(t) > 0. The period is T = 2. ‘The signal power is P = 0.5. 16. Chapter 2_ Analog Signals {b) sgafsin(rt)} To sketch, note that sgo[f(t)] is -1 if f(¢) <0 and +1 if f(t) > 0. The period is = 2, The signal power is P (©) dlsin(xt)] To sketch, note that impulses occur when sin(wt) = 0. To find the impulse strengths, see Problem 2.47(b). ‘This signal is periodic but not a power signal. —s 2.81 (Solution) (a) 2(t) = sin(2ri} is a sinusoid with period 1. Its power is P = 0.5, (&) v(t) = ©? is petiodic with the same petiod as 2(). 80,7 (©) 2(0) = 2 is also periodic with the same period as 2(¢). Since z(t) is complex and [2()[=1, its power is P= 4 f.le(t)Pat = 1 2.82 (Solution) See the sketches below. The area of one period of each periodic extension equals the total area of 2(4) = tri(t/2). (2) Periodic extention (0) Periodic extension (e) Periodic extension AS 126 LN aS Ss Ne AS Sa Tris ss HO (Periodic extension i Peso tee N Nei NNcie 2.84 (Solution) (a) 2{¢) = cos(2nt) + cox(6xt) + cox(l0rt) Its components are at 1, 3 and 5 Hz. So fo = 1 and T =1, Each component is half-wave symmetric over one composite period, and so is 2(¢). (b) 2(¢) = 2+ con(2nt) +sin(6xt)+sin(10mt) ‘This cannot be half-wave symmetric since its de value is not zero, (©) 2(¢) = cos(2nt) +cos(4nt) +sin(6rt) Its components are at 1, 2 and 3 Hz. So fo = 1 and Since cos(4zt) is not half-wave symmetric over one composite period, neither is 2(¢) Chapter 2_ Solutions to Problems 2.35 (Solution) See the sketches below. At jumps, the derivative will include impulses. x) iN tT a x0 (0 "0. Zz \ i 1s : a sew "set : Signal (© a ie @ Z {a) z(t) = cos(0.5rt) z(t) = —O.5wsin(0.5mt) —x"(t) = -0.25m cos(0.5rt) (plus impulses) (b) z(t) = 1 + cos(nt) al(t)=~xsin(rt) —2"(t) = ~pi? eas(rt) (c) a(t) = tri(t). See the sketches. @x)=1-2 2)= 2.36 (Solution) 2 2"(t) = ~2 (plus impulses) (2) x) = e"*"u(2). $0, B= [ome = 057 (b) x(t) = te“/u(t), So, B= e "1H dt = 0.2514 (from tables) (9 HO = ertea(24 U0), 80,2 = [ “|e-tsin(2e)}* dt = 0.2 (from tables) 2.37 (Solution) s(t) = Ae“ ult). found from 0.014 = Ae“*/*. This gives t= 4.6r. This compares reasonably with the practical estimate of t = Sr. 2.38 (Solution) az ‘The thne it takes to decay to less than 1% of its initial value (A) is. (a) a(t) = (1—e"*)u(t). The final value of z(t) is 1. The time t; to resch 10% and tz to reach 90% are found from 0.1 = 1 ~ e~** and 0. So, te = ty — ty = In(0.9) — In(0.1 sio= { =e, Thus, f) = —In(0.) and ty = 1972 In(01). SMOSH OS!S1 rae sonata 1 The ne teach 10% nd fo reach 90% are found from 0.1 = sin(0.5rt:) and 0.9 = sin(0.5rt2). ‘Thus, t1 = 2-sin“¥(0.1) and t 4(0.9) and te = ta ~ty = 0.7129 — 0.0638 = 0.6491 18. Chapter 2 Analog Signals 2.39 (Solution) (a) 2(t) = (1—e-"/*)u(t). The final value of 2(t) is 1. The time t, to reach 10% and ta to reach 909% are found from 0.1 = 1 —e~®/* and 0.9=1~e-¥/*, Thus, ty = —rln(0.9) and tz = —rin(0.1) So, tg = to ~ ty = r[la(0.9) ~ In(0.1)] = 2.19727. This compares well with te © 2.27 (b) For the compressed signal f(t) = 2(3), the time taken to reach 10% and 90% of the final value will be three times less and the time constant will be t/3. Similarly, the rise-time of the stretched signal g(t) = 2(t/3) will be St, In general, the rise-time of the signal A(t) = 2(at) will be atn. 2.40 (Solution) (@) a(t) = (1 - e u(t), The time to reach within 5% of the final value (of unity) is found from 0.98 =e. Thus, et = 0.05 and ¢ = —In(0.05) = 2.9957 (2) x00 = { MESO OSEST re sn sac thin 9 of the a ao (of ay found from 0.95 = sin(0.5m). Thus, ¢ = 2sin“1(0.95) = 0.7978 ae Ett) ent=(t) BAL (Botution) Drm "ET Dm ET (2) Since =(t) = rect(t) is even symmetric, Dz and Ds are both zero because t2(t) has odd syzametry. (b) 1. 2(¢) = rest(t— 2). The area of 2(¢) and 2%(¢) is 1. So Dim foeatne Dio [ tdn2 2, a(t) = e-*u(t). The area of z(t) is 1/cr and the area of 2°(:) is 0.5/a. So, using tables, Dy = 20 f ten dt = (a)zty = 4 3. a(t) = te*u(t), The ares of z(t) is 1/a? and the area of 22(¢) is 0.25/a°. So, using tables, Dy ae [team (#2 Dz= of . Bet ge = (da? 6 Gaye 2.42 (Solution) Refer to the sketch. (0) (2) 2(t) = Ate*tu(t). Now, 2'(f) = Aev*"(1 - at) = Oat f= 1. So, = 1 Also, z(1) = 1 = Ae™®, So, A =e" = ¢ = 2.7183 Chapter 2 Solutions to Problems 19, (b) x(t) = A(e~** — e-2**), Now, 2/(t) = A(—ae-* + 2ae-2*t) = 0 at t= 1. So, ~e~® 427% = 0 or a =In? = 0.6931 Also, 2(1) = A(e"# ~ €7 80, A a (© at) = 4G, Now, (0) = wea) ore att=1. So, -2+a+1=00ra=1 Aso (a) = =A = 80, A=1l+a=2 2.43 (Solution) 2(t) = cos(2rfot + 8) = cosly(t)] So, 6(t) = Irfot +8 and f(t) = £0 = fy, a cc 2.44 (Solution) (a) Alt) = 10. So, H(t) = 25 [oul thdt +0 = 20Kt + 8 and a(t) = coe(20mt +6). (b) If the instantaneous frequency varies linearly from 0 to 100 Hz in two seconds, fi(t) = 50t So, #(t) = 2x f gilt}dt + 6 = 50nt? +0 and 2(t) = cos(sSomt? +6) (c) the instantaneous frequency varies linearly from $0 to 100 Hz in two seconds, f(t) = 50+ 250. So, H(t) = 2m f dult}et +4 = 2m(60t + 12.54%) + 8 and x(t) = cos(100nt + 25m1? + 6) (@) Tahe trequeney varies lnerly fom fo He to fy Hain to sands, Rt) = fo + A= Lo, So, 6t) = 2a f eltat +0 = ant + eA Leet 46 and z(t) = coslg(0] #0 ae spe of IE the frequency varies from de to 10 He in 4 seconds, we have 22 2.45 (Solution) 2(t) = cos(at*). So, #(t) = at? and fil = 25r = 7.8540, 2.46 (Solution) (a) a(t) = det? Asa = 0% 2(t) becomes more compressed and tall. Since z(t) is even cram, [" 9 z(t) =1 (from tables), The limiting form of z(t) is thus 6(t). (b) z(t) = we 7 Asa 0,2(t) becomes more compressed and tall. Since 2¢) is even symmetric we find fe x(t) af” Z(t) =x (from tables). The limiting form of 2(¢) is thus n5(¢). (©) 2(¢) = Jsinc(£) As a ~+ 0, z(t) becomes more compressed and tal. Since 2() is even sym atric, {™ a(t) =2 [ z(t) =1 (fom tables) The lining form of z(t) is thus 5() Ln hb 20. Chapter 2_Anelog Signals (4) z(t) = 3 tables). The limiting form of z(t) is thus 4(¢). 2.47 (Solution) See the sketches below (8) ay 4 12 (a) a(t) = s(t? —3t+2) The roots of f(t) = ~3¢+2=0 are t find [f (lear = [2-3] = 1 and |f'(@)leq2 = 14-3] = 1. Thus 2(t (b) z(t) = dfsin(xt)} The roots of f(t) = sin(xt) = 0 occur at te =n, m= 0,41,42,.. , 2. With #’(d (¢ = 1) + 6(¢ -2). Ke Asa +0, x(t) becomes more compressed and tall. We find [ =(t) <1 (from lo 2 — 8, we With I(t) = Teos(rt), we find [f(te)] = fr eos(kx)| =n. Thus, 2(¢) = 4S 4(t~k). ‘This describes aan impulse train. COMPUTATION AND DESIGN 2.48 (Solution) Uses the ADSP routine enerper wproblen 2.48 t0:0.01:3; wtime array xesin(2epitt); Signal x(t) yeep; zeexp (42); Wz is complex valued fecos(pitx) 5 grcos(pi*x. +x); plot(t,x),grid,pause plot (t,y),grid,pause plot (t,real(z)),grid,panse plot ¢t,),grid,pause plot(e,),grid,pause ‘Winding the period smrmax (x) jiefind (abs (x-xm) <100+eps) ;rist (4) seindits (es) sTxea (1) ymonax(y) ;i-find (abs (y-yn) <10O+eps) j tit (1) jdinditt (ei) ;Ty=a4 (1) ‘fnvaax (£) {4efind Cabs (£-f2) <100eeps) ;tint (4) jddadifs (ei) ;Theai (1) garuax(g) ietind Cabs (g-ge) <100%eps) jzi=t (4) jdtnaite (eA) ; Terai (1) winding Pover Wower in z is 1¥ ‘Wor the rest use the ADSP routine enerpyr Worked of x is wWeriod of y is YWeriod of tis ‘Weriod of g is Chapter 2 Solutions to Problems 21 xe'sin(2epist)'; Wefine as a string variable Peeenerpur(x,[0,Ts],T3) over in x= 0.5 y= exp(sin(2epist))? ;Pymenerper(y,[0,Ty] Ty) WPower in y = 2.2796 f-"cos(pitsin(2epitt))? ;Pi-enerper(f,[0,T4],Tf) IPover in f = 0.6101 gr’ cos(pissin(2spitt) .xsin(2epivt)) ? ;Pgrenerpur(g,(0,Tg],Tg) XPover in g = 0.6521 2.49 (Solution) Uses the ADSP routines ustep, uramp, enerper ‘wroblea 2.48 ‘$9-2:0.02:6;5"sin(pist) ;s8esin(piv(t+0.5)); xeustep(s) :y-siga(s) ;f-sign(s)*sign(s6); gruramp(s) jheexp(s) 5 plot(t,2),grid,pause Period is plot(t,y),grid,pause Period is plot(t,f),grid,pause {Period is plot(t.g).grid,pause Period is plot(t.h) ,grid,pause Period is Wee enerpyr to compute pover vith +2 x-?ustep(sin(pitt))? ;Preenerpwr(x,[0 21,2) Power is 0.5 yo?sign(sin(piet)) ;Pyzenexper(y, (0 2),2) XPower is 1 ‘f=*sign(sin(pitt))+sign (sin (piv (t+0.5)))’ ;Pfrenerpyr(f, [0 21,2) APover is 2 g-?uranp(sin(pi+t))? ;Pg-enerpur(g,[0 21,2) _4Pover is 0.25 betexp(sin(pitt))?;Phrenerper(h, [0 21,2) YPower is 2.2796 2.50 (Solution) Uses the ADSP routines ustep, tri, enerper wProblex 2.50 HPART (a) NeS pt00:1/Ms1jxetrd (t) jx2ex.*x;y=sin(pitt) axesum(x) /N,ax2esun (22) /l, ay=sun(y)/R,ay2 Repeat for N=10 N=10;%=0:4/M:4 jxetri(t) jx2=x, ax; yosin(pist) ;y2=y.4y; axesun (x) /N,ax2esum(x2) /M,ay=sum(y)/N,ay2=sun (2) /H APART (e) MoS; t=0:1/Ns4 jLeLength(t) jamted (+) jx2—x.#x;y-sin (pit) jy2-y-7; +x (1)-0.54x(L))/M, ax2= (sun (x2) -0..65x2(2)-0.54x2(L))/N, Sey (19-0. 54y (LD) /M,ay2=sun(y2-0.+y2(1)-0.54y2(1))/H Yepeat for N10 LeLongth(t) jx-tri(t) jx2ex.x;yesini(pire) sy2°y-475 54x (1) -0.64x(L)) /N, ax2= (sum (x2)-0 .54x2(1)-0.54x2(L))/N, ay~sun(y-0 .5+y(1)-0.54y(L)) /N,ay2=sun(y2-0.54y2(1)-0.5472())/8 22 2.51 (Solution) Using tables, weroblex 2.51 wPaRT (a) 137002; e008: x=10exp(-t) #8in(242); sxvtetcunsun(x); sxe=d-2eexp(~t) .#(sin(2et) #24c08 (2409): plot t,sx,t,sxe) ,pause ‘Repeat for ts=0.01 t290.01;70=2;t=0:t8:70; x610xexp(-t).51n(24t) sxete¢cunsun(x) ; sxen4-2vexp(-t) .#(sin(2*t) +2xcos(248)) ; plot (t,sx,t,sxe) ,pause PART (b) ‘Wepeat for ts0.1 and 10-5 t5=0.1;T088;t=0:t8:T0; xe10rexp(-t) .*54n(2*t); sxrts+cunsun(x) 5 sxen4-2eexp(-t) (sin (24t)#24cos(24t)); plot (t,sx,t,sxe) pause YRepear for te=0.01 and T0=5 ‘$890.01; T0=5;t=0:t2:T0; xeL0sexp(~t) -asin(2#t) ; sxetsecunsum(x) ; ‘sxend-2texp(-t) .* (sin(2#4)42¢co8(2#t)) ; plot(t,sx,t,sxe) [sin(274) + 2 cos(2T%). Chapter 2 Analog Signals As Ty +00, 4 2.52 (Solution) z(¢) = 10e~*sin(2t), x(t) = 102"*[2cos( 2) ~ sin(20)) wproblen 2.52 ts°0.1; 490: BixedOvexp(-t).¥2in(2+t) ; xe-diff (x) /ts;L-length Grd) ; Younerical derivative xde=10+exp(-t).*(2cos(2et)~sin(24t)); exact derivative plot(e,xde,e(1:L) ,xd) pause exrexde(1:L)-xd;plot(t(1:1) ,erx) pause error for ts#0.05 =10%exp(-t) -#sin(24t) ; Chapter 2 Solutions to Problems 23, xdo-L0+exp(-t).#(2+cos (2et)-sin(2et)) plot(t xde,t(1:L) .xd) pause exrexde(1:L)-xd;plot(t(1:L) err) LL _ 2.53 (Solution) Uses the ADSP routines ustep, uranp, operate Yproblen 2.53, ‘b-2:0.01:2; xe2mustep(tH1) -uranp(t+1) +aramp(e-1) ;plot(t,x) ,pause (ty, y]operate(t,x,2,-1) ;plot (ty,y) pause (ef #]-operate(t,x,-2,1) jploter ‘You could also use ctsiggui. ‘The results are shown for 2(—2t +1) 2.54 (Solution) Uses the ADSP routines leat, godt aft) = 2eos(2.4nt) ~Ssin(S.Art)+cos(M.txt 0.2m), f= to find thelr rational approximation. 2, f= 2.7, fs ‘We use MATLAB 24 Chapter 2_ Analog Signals wprobien 2.54 UAL .2:f292.73£367 2; fat jdt) =rat (£4) ; (22,42) rat (22) ;{n3,43)=rat(f3) ; {Find rational approximations (aa da) =gedt ({ai 2,03) [41 ,42,43)); f0—na/da 1£0%3/10-0.3, [ab db] =1em! (fat 22,43) ,fn1,n2,n3)); Tenb/db T10/3 «3.3333. 2.55 (Solution) Uses the ADSP routines sinc, enerpyr wrobien 2.55 x=?Gesinc(2#)’; Exeenerpyr (x, [-0-5,0.5]) ‘MBx=16 2508 Preenerpyr(x,(-0.5,0.5],1.4) YPxeEx/1.4 = 11.6077 2.56 (Solution) x(t) = cos(2nfot) cos{2x(fo + A/}t) wroblen 2.56 wpant (a) $-B192; t=(0:8)/S;A=1;B=1;£0=400; DaO;xeA*cos (2epiet0et)+Becos (2epi+ £0+D) +t) jplot (t,x) ,sound(x) ,pause Det ;x=Ascos (2¢pinf0st)+Bacos (2epi*(t0+D) 4t) ;plot (t,x) ,sound(x) ,pause Ded x-Atcos (2epist0*t)+B*cos(24pix (£0%D) t) plot (t,x) ,sound(x) ,pause De5x-A¥cos((2epiet 04) +B4cos(2epiv(£0+D) +t) plot (t,x) ,eound(x) wpant (b) Ythe beat signal is periodic. You can read the beat frequency from the plots 2.57 (Solution) x(t) = cos(mi?/6), g(t) = mt?/6. So, filt) = Z(t) = t/8. So, the instantaneous frequency increases (linearly) with time. The signal Is not periodic. es wroblen 2.57 890.02; Te2; te0:ts:T;x-cos (pitt. st/6) ;plot (t,x) pause T=6;t=0:ts:T;x=cos (pivt..+t/6) ;plot(t,x) pause ? ‘te: Tixmcos (pitt. t/6) splot (t,x) 2.58 (Solution) wroblen 2.58 PARTS (a~c) zOsi;ts: 20-0 .5;t8°0.14t0; 2090. 1)t5=0.14t0;te-2: wexp(-pitt.+t/t0/t0)/t0;plot(t,2) ,Axceun(x)*ts, pause xvexp(-pitt.4%/t0/t0) /t0;plot (t,x) ,Ax-sua(x) *ts,pause :2jxmexp(-pitt #t/t0/20) /t0 ;plot(t,x) ,Aresun(x ts pause Chapter 2 Solutions to Problems 08:2 jamexp(-pist.*t/t0/t0)/t0;plot(t,x) ,Ax-sun(x) #te,pause =-2:t:2;xrexp(-pitt.#t/t0/t0)/t0; plot (t,x), Axesun(x)*ts ,pause WPART (A) The derivative approaches the doublet a’ (t) tOnt ten0.14t0;t—-2:t8:2;x-exp(-pitt.+¢/t0/t0)/t05 xdndift (x) /ts; LeLengeh (xd) ;plot (t (1:1) x4) ,axd=sun (xd)*ts, pause :2;xrexp(-pist +¢/t0/t0)/t05 sLeLength (zd) ;plot (t (1:1) ,xd) ,Axd=sum(xd) ts pause 00.1; t80. 1440 xvexp(-pirt.*t/t0/t0)/t0; xdedift (x) /ts;LeLength (ed) ;plot (t (1:1) xa) ,Axdesum(xd)*ts, pause :t5:2ixeexp(-pint wt/20/20)/t0; sngth (xd) ;plot(t(1:L) ,x4) ,Axd-sun(xd)+ts,pause 01; ta=0. t*t0;t=-2:t8:2;xeexp(-pirt.+t/20/%0)/t0; xdndift (x) /te ;:L-Length Gad) :plot (t(1:L) ,24) ,Axdesun (xd) +t Chapter 3 e DISCRETE SIGNALS 8.1 (Solution) See the following figure for sketches. 1) o “a 4 Atte (8, 4,2, 2} Bnergy signal. B= D2?[p] = 36 + 18444460 (b) sin] = {-3, -2, “1, 0, 1} Energy signal. B= S2%fn] 944414115 (©) =in] ={5, 2 4,6} Energy signal. B= 24m] = 4416 +36 = 56 (@) zh) = ofp] —ufe—4) Boergy signal. B= Sat] =1414141]4 wa 3 (e) ={n] = cos(nm/2) Period N = 4. Power signal. P= HD) 02] = 2+) =05 7 ao () 2{n) = 8(0.5)"v{n] Energy signal. 2 = ye = sia (0 25)" = 64 __ ~ 95.3333, = a0 fee 3.2 (Solution) Seo the following figure for sketches. . 0) 10) ° @ S 6 6 7 ‘ 4 a2 22 es sc catia sia With 2[n] = (8, 4, 2, 2}, we find (a) ya] = z{n ~2] = {0,0,6,4,2,2} (shift right by 2). (©) flo] = xf +2] = (6,4,2,2} (shite late by 2). (©) g{n] = 2[-n +2] = {2,5,4,6} (fold fin}) Chapter 3 Solutions to Problems (4) Alo] = 2]-n— 2) = {2,2,4,6,0,0} (fold yl) ‘The energy in each signal is B= 36 +16-+4+4=60 3.3 (Solution) Note that z[n] = 8(0.8)"(u[n +1} — ula —4)) = {16, 8, 4, 2, 1). Then () vin) =2in—3) = (6, 0, 26, 8, 4, 2, 1} (shit right by 3) (b) Flr] = [n+ 1] = (26,8, 4, 2, 1} (shift lee by 1) (©) ofr =2[-n +4] = (8, 1, 2, 4, 8, 16) (ohift lft by 4, them fold) (€) Afr] = 2[-n—2] = (1, 2 4, 8 16, 0} (ehift right by 2, then fold) 3.4 (Solution) Let z{n) = {4, 0, 3, -1, 3). Find and sketch each of the following signals and compare their signal energy with the energy in z[n]. (@) dfn) = x{2n] = {4, §, 3). (b) zero-interpolated fin] = 219] = (4, 0, 0, 0, 3, 0, -1, 0, 3, 0}. (4, 4; 0, 0, 3, 2, -2, ~1, 3, 3} 1, 1, &, 18} (last value fsterpolated (6) step-interpolated ofr] = 213] (A) tearly-interpolated h(n] = 2[$] = {4, 2, 0, 1, 8, 0.5, assuming next sample is zero). 3.5 (Solution) See the following figures (not to scale). We find the even part as ze[n] = 0.5(2/n)+2[-~n]) and the odd part as zoln} = 0.5(z/n} — 2[-n)). li li fo Vs sutltys rl 28 Chapter $_ Discrete Signals pe Eve per oe part : ¢ dag ali : i. : m TEs 1a n Sigml (9 Even pat : Yu y Hh s bd Sigal © Even pat oc pat r Ly 2 ry? z Tr 3.6 (Solution) See the following figure for sketches. We note that {a) 2[p] =1[n +2] ~r[n —2] - 4uln —6] is easily sketched as a sum of steps and ramps (b) zfn] (©) 2fp] = rect rect() is 6 Tsample rectangular pulse from n= —3 to n= 3 is a S.sample rectangular pulse centered at n = 2. (A) x{n = 6tri(254) is a 7-sample triangular pulse centered at n= 4 (with end values of 2er0). fi. tl, ly. Tat. 7 (Signal Description) Refr tothe setces ign 1 I aL 7 2 = iL 5 Figure P3.7. Signals for Problem 3.7 (a) Signals as 6 numerie sequence: JHE # (Signal 1:) fn) = (2,2,2,2,1,1,13,111,) # (Signal 2:) 2{n] = {-2,~2,4,4,4, + (Signal 8:) 2{n] = (8,1,2,3,4,5} Chapter 3_ Solutions to Problems 29, «© (Signal 4) 2{n) = (8,5, 4,3,2,2,2,2,2} (b) Signal representation by impulses © (Signal 1:) s(n] =2(6fn +53] +6)n +2] + 5fn+1] + nl) + in 1] + din 2) +...4 5fn—8) 25|n +3] — 26m +2] + 46[n-+ 1] + 4bln] + 4blr ~ 1] ~ 25x ~2] ~ 250 — 3] in ~ 1} + 26{n —2} + 36[n 3] + 46[r— 4) + 56[n— 5] (r+ 54fn 1] + 45x —2}+36(n —3]) +2(6]n—4] + dln —5]+...+60 8] (c) Sigual representation by steps and ramps: (Signal 1:)_2fp] =2ufn-+3]—uln—1]— un -9) fein moe a toupee lh tae —2)4 204 in) ~ rin ~ 5] - Suln — 6) = Gulp) ~ rin] + rin ~ 4) — 2uln—9} (@) and (c) Signal energy and signal power (i periodic) Sigal B= D2 j=2% Naw P=2Ez% Signal 2: B=Sx%jnj=64 Na? P= fp De ai]=85 N=6 P=AS2%nj= Bija100 N=-9 P-25zin= 3.8 (Solution) (a) 2{n] = cos(0.5nz). So, F = 628 s periodic with V = 4 (b) =in} = cos(0.5n). So, F = ZL, s0 not periodic e Js not o rational fraction) (©) in| = sa((f) ~2e0s%f). 80, =f, B= So, Ni = 8, Nz = 12. So, periodic with N = bea (A) a{n) = 2eos(4z) +eotR) = 2eos(%E) + 0.5 + 0.5 c0s(3F). So, Fi= }, Fas 1, 80 Ni =8, No=4, 60 periodic with N = LOM(8,4) = 8 = Fand (©) 2] =4~ 3ein(4) Periodic with (€) a{n] = cos( RF) + vo8($E). 80, A= $, == So, N= 24, No =8. So, periodic with N = LCM(24,9) =72 (e) {x} = cos(S32) + cos(82). Not periodic because Fz = & is not rational. (h) fp} = cos(89E) ens AF) = 0.5 cox( MAT) + 0.5 cos(I9E). 80, Fi = HB, Fe =f So, Ny = 6, Nz =12. So, periodic with N = 12. (i) x(n] = 4", So, F = 0.15 = 3h = &. So, a with V = 20. () 2fn] = 205997 4 sem, 50, F, =015 = B= fh =02=4 So, Ny = 20, Nz = 6 and V = LOM(20,5) = 20 (K) ain] =o, So, F = 225, Not periodic because F is not rational. () af] = Gy? = (PP)? =O, So, F-= 80, periodic with N= 8. 30 Chapter 3_Discrete Signals 3.9 (Solution) (@) xfp} = cos(4nn/3). $0, F = 4/6 = 2/3. So, F = 2/3—1 = ~1/3. 80, z[n] = cos(—2nx/3) = cos(2nn/3). For 4. 0.5 (or $< 2fo). Now, F = 1.6 = —0.4, s0 zn] = cos(-0.8n1 + 0.252) = cos(0.8nt ~ 0.25"). (b) ={t) = cos(140rt ~ 0.25). So, fo = 70 Hz, S = 100 He, and F= fo/S = 0.7 ‘There is aliasing because F > 0.6 (or S < 2fo). Now, F = 0.7 = ~0.3, so z{n) = cos(~0.6nx — 0.25n) = cos(0.6nx + 0.25n). (©) 2(t) = sin(60zt). S0, fo = 30 He, $= 100 He, and F = fo/S=03 ‘There Is no aliasing because F <0 (or $ > 2/4). So, z{n] = sin(0.6n7) 3.11 (Solution) ‘The product of a right-sided and a left-sided discreto-time signal is always time-Limited or identically zero. Example 1: up ~ 8) and w{-n]. Their product is zero. Example 2: ufn +2) and u[-n}. Their product is {...,0,0,1,1,1,0.0,-..} 8.12 (Solution) Refer to the sketch. bsCal tel TEs as “ Figure PS.12. Siguels for Problem 3.12 (a) 2[n] = Aa*(ufn) — ufn — 1¥]). From the figure, V = 6. Also z(0] = Also, [2] 4a, 90 = 05. (b) fn] = Acos(2"Fn +6). From the figure, N = 6 or F = 1/6. Atn =0 and n=1, we have yO] =1 = Acose all] = -1 = Acos(§ +8) = $ cose — 4¥8 sing Asind 1s, — 46 sind or Asin@ = V3. So, 5 = tang = — Thus, 5— 4% sind or Asin@ = V3. So, ERE = tand = V3. fond A= by=2 ‘This gives @ Chapter $_ Solutions to Problems 31 3.18 (Solution) A 7 (2) =n] = 2"uf-n] = (0.5)-*u{-n}. So, B= > (05) = D085)" = a Fa) 1 a (©) 2{x] = Pulm ~ 1] = (05)"Paf-n=3}. $0, B= J) (05)-" = Posy = OF at a ot : cos(n), Periodic, F = 0.5 and NW =2. z{n] = {1, —1} for one pétiod. os(t+t)=2 (2) =n] = cos(nn/2). Periodic, F = 0.25 and N =4. a[n) = {1,0,~1,0} for one period So, P= EYoeh] 028041) <08 m= 1 (6) ain] = buna. 80, B= zo 2 (from tables) (©) afn) = zn 1], Neither a power signal nor an energy sigual (because 2%[n} does not decay faster than 1/n and Y>s4In] = 1+} +} +--- does not converge). (8) an] = Syuln~ 11. 80, B= oa = © (om tables) = (h) zfn] =e". Periodic, F = 0.5 end N =2 and [xf $0, P= Shan? =05(1 41) =1 @ zfn] = e"*/, Periodic, F = 0.25 and N= 4 and |z{n} = 1. 2 So, P= 2") = 0251414141) =1 G) af] = elF#2001/4 = err/teine/t_ Neither power nor exergy (growing complex exponential). (8) slp] = 3"/4 = 8, Petiodic, F = dy and N =16 and |2[n]| = 2. $0, P= 32d = 406) =1 VI)" + (VF)- = "7/2 + e-I"™/2 = Deos(nm/2). Periodic, F = 0.25 and N = 4 and (2,0, ~2,0} for one period. a 025(4+ 32. Chapter 3. Discrete Signals 3.14 (Solution) Refer to the sketch (3) Tite Vises = ube ~ kN] where yfn] = ufnj uf — 9] and. N= 6, Thus 2 {1,1,3,0,0,0} for cone period. So, P= k 502} = 2(1+141) =05 = =5k-4) = J) oln— kN) 4. (b) an} ¥ eres ~ where 27 = § and gin) =2"(ufn} — Thus, zf {3,2,4,8,0) for one period and P =} )>2%fn) = (1+ 4416464) =17 a 3.15 (Solution) All represent the same signal because ain] = sin) = fo] = ret{n} = ‘aln| = expr) = ¢ Ain] = sine{n] = {..-,9,0,1,0,0,...} 3.16 (Solution) {a) @=05 — (0.5)"ufn} = {1,0.5,0.25,0.125,...}. This is a decaying exposential @=1 . (i)"ufn] = {1,1,1,1,...}. This is 0 unit step (constant) (2)"ufpl = {2,2,4,8,...}. This is a growing exponential. (b) a=-05 — (-05)"uln} = {1,~0.5,0.25, 0.125, ...}. This is a decaying exponential. @=1 — (-1)*uln)= {1,-2,1,-1,..}. This is an alternating step. @=2— (-2)"uln) = (1,-2,4,-8,...}. This is © growing exponential (2) 20.50% — (0.52)" = (0.5)"e"9. This is an exponentially damped sinusoid @(ef)" = eh°F_ This is sinusoid. ei (2/9) = (2)*ei. This is an exponentially growing sinusoid. (4) a=~0.5e% —(~0.5e%*)" = (-0.5)"ei"?_ Damped sinusoid with samples alternating in sign. ame” — (6i)" = (—1)"e!*?. Sinusoid with samples alternating in sign a= HR (~265 = (-2)"e*. Growing sinusoid with samples alternating in sign. Chapter 3_ Solutions to Problems 8.17 (Golution) fn} = dtri(n/a) ={0,1,2,3,4,3,2,1,0} {a) ={n/3} = {0,0,0,1,0,0,2,0,0,3,0,0,4,0,0,3,0,0,2,0,0,1,0,0,0,0,0} (zero interpolation) -{2n/3) = {0,0,0,2,0,0,4,0,0,2,0,0,0,0} (decimation) (b) 2{n/3] = (0,0,0,1,1,1,2,2,2,3,3,3,4,4,4,3,3,3,2,2,2,1,1,1,0,0,0} (step interpolation) -x{2n/3] = {0,0,1,2,2,8,4,4,3,2,2,1,0,0) (decimation) (6) ={2n] = {0,2,4,2,0} (decimation) 2[2n/3] = {0,0,0,2,0,0,4,0,0,2,0,0,0, 0,0} (zero interpolation) (@) =[2n) = {0,2,4,2,0} (decimation) -={2n/3] = {0,0,0,2,2,2,4,4,4,2,2,2,0,0,0} (step interpolation). 3.18 (Solution) (a) x{n] > (interpolate by 8) 2[3] — (delay by 2) 2[252] — (decimate by 3) 2[n ~ 3} () ata} = Ch 4, 7, 20, 23). a{3]= (1, 2, 8, 4, 5, 6, 7, 8, 9, 10, 11, 12, 23, %, 22, 0} (inear interpolation). 2(52] = {8, 0, 1, 2, 3, 4,5, 6, 7, & 9 10, 21, 12, 13, 8, 48, 0} an a= 2, 5, 8 11, ¥} (©) ln] => (interpolate by N) 215] —+ (delay by M) =[258] —+ (decimate by N) zin ~ 44] Restriction: M and N must be integers. 3.19 (Solution) Refer to the sketches, SS ER A) (a) =: Be eM, ke O ly -yN 1 vith a] “Angular spacing = 7 Angular spacing = eotefttn 2 gia WW 1 with [2] ‘Angular spacing N=6: Angular spacing a Chapter 3_ Discrete Signals 8.20 (Solution) (a) afr] = cos( RE), So, P= FF =}. Fors

Fy So, z{n) = sin( 22 + 0.25n) = ~sin( 23 — 0.25%). (b) IF Sq =4 kHz, the reconstructed frequency is FaSp = ~$982 = 50 He (ie., $0 Hz). (c) If Sq ~8 kB, the reconstructed frequency is FoSp = — 8 = —100 Hz (ie., 100 He). (A) If Sq = 20 kHz, the reconstructed frequency is FoSp = ~200 = —250 He (i.e., 250 Ba). 3.23 (Solution) 2(t) cos[6(t)) = cos(at?). So, fut) = sho! (t) = St. This varies linearly with t. (a) If the frequency varies from 0 to 2 Hz in 10 seconds, 2 = 3. So, a= O.2n. Now, $=4 Hz, sot = nt, = n/S and z{n] = cos(an?/S%) = cos( g(n") (b) af +N) = coslg(n +N) So, for 2{n} = 2[n +N), we require & = m and St = 2k (where N, m and & are integers that make the last rwo terms integer multiples of 2x). The smallest NV thot satisfies these result is N = 80. So, 2{n] is periodic with period W = 80. = cos|(n? + 2nN + N*)) (c) yln] = cos(eFon?/M). With Fo = 0.25 and M ~ 8, yin] = cos( Jyn®). Following part (b), u{n] is periodic with period W = 32. Chapter 3_Solutions to Problems 35, 8.24 (Solution) (a) z[n] = (0.5)"ufn). So, z[0] = 1. The 60-B time constant is found from (0.5)" = 0.001 and gives, ‘elog(0.5) = log(0.001) or n = 9.9658 ~ 10. The 40-dB time constant is found from (0.5) = 0.01 and gives nlog(0.5) = log(0.01) or n = 6.6439 = 7. (b) With 5 = 1 kHz, the 60-4B and 40-dB time constants are 10 ms and 7 ms, respectively. 8.25 (Solution) (@) ain) = (4,3,2,1,,1,2,3.4}, Ask <4 a) ‘We compute D Sapp 7a (b) ole] = (4,3,2,4,0,1,2,8,0, 35k y gl) “Eau 781 Afn] = (4,3,3,1,0,1,2,3,4}, -221, we compute P= DMI = (-08)? + 05" DE (0.25) = 0.28 + (1.5)*5 oe a Q= DahIk) = 0(-0.5)? + (2.5)? DR, #(0.25)k = as Re ei - So, the delay is D = § =1. 3.26 (Periodicity) 2in] = ti(n/3) = (0, $, 8, 1, § $, 0}. We have Soz{n] =3 and B= D2] = Refer to the sketches forthe periodic exinsions calle ll ilies ~ Ife atlt lil sllfeghuutics -ulffuo; IU 1 1234s iis 36 Chapter 3_ Discrete (©) For (A) For N = 4, we have 25m] (e) For N'=3, we have Spin) 3.27 (Solution) z/n) "uln]. So, its periodic extension with period NV is vol= SS orn ax] = Sart war Sa" ‘ & & SEL, 0 Ky = 18.5, K-25 So, y(t) = -16 + 12t-+ 18.5e7* ~ 2.5e~3¢ Zero-Input: yes = yw = Kie™t + Kre7™ with (0) = 0, y'(0) So, Ki +Kz=0 — Ky, -3K2 ‘Ky =05,K2 = -0.5 So, yet = 0.5e~* — 0.5e-™ ‘Zero-State: yz5 = y(t) = -16 + 12t+ Kye~* + Ke" with zero IC. So,-16+Ki+Ka=0 12-Ki-3K,=0 Ki =18&K2=-2 ves 16 + 12t+ Bert ~ 26-8 (a) y(t) + 4y't) + 4y(t) = 2e*u(e) v= yO) =1 Ch. Eq: s?44s+4=0 Roots: -2,~2 (repeated) — yyy = (Ki + Kate Forced Response: yr = Ct*e~* (because of root repeated twice) tf a So, Yjp = =20H%en 4 2012" ye = 4H em — 80te~™ + 200-7 So, [22 + 58+ Slyp = [ACH ~ 8Ct +20 ~ 80H + 8Ct + 4CtRe“# = 2Ce-# So, yp = ent ‘Total Response: y(t) = yr ty = Be 4+ (Ki + Kate (0) = 0,3/(0) So, A0)=0= Kh (0) 2K, +H. Ke So, y(t) = ter + tem Zero-Tnput: Yai = ww = (Ki + Kate“ with y(0) =0,y'(0) =1 So, Ky=0 -2%i+Kp=1 Ka=1 ya=te™ Zero-State: Yay = y(t) = Pen + (Ky + Kathen% with zero IC. So, Kr -2Ki+Ke=0 Kp=0 yep = tenr™ Chapter 4 Solutions to Problems 53 {e) v0) + 4y'(0) + 4y(t) = Beas(2tyu(e) — (0) =O ¥(O)=1 Ch. Eq: s?+45+4=0 Roots:-2,-2 (repeated) yw = (Ki + Kat)e“™ Forced Response: yp = Acos(2t)+Bsin(2t), 60 So, vp = —2Asin(24) + 2Beos(2t) yp = —4Acos(2t) ~ 4Bsin(22) So, [s? + 5s + Elyr = BB c0s(2t) ~ 8Asin(2t) = 8 cos(2t) Now, compare coefficients of cosine and sine terms to giveA=0,B=1 yy ‘Total Response: y(t) = yr + yw = sin(2t) + (K+ Kat)e-* —y(0) = 0,y/(0) $0, (0) =0=K; (0) 1=2-2Ky +R, Kp=-t So, y(t) = sin(t) ~ te Zero-laput: yes = yw = (Ki + Kathe“ with 9(0) = 0.9/0 So, Ky =0 -2K;+K2=1 Ka= Zero-State: yos = y(t) = sin(2t) + (Ky + Kat)e~* with zero IC. So,K,=0 2-2Ki+K2=0 Kz=-2 uss =sin(2t)— 2te% (+ )%e+2vO =e*u) (0 =O ¥O)=1 YO) =0 Ch, Ba: (¢-+2)%(8+2)=0 Roots: 1-1-2 yw = (HK + Kat)ent + Hgem™* Forced Response: yr = Cte (because of repeated root) So, «(ye =~20ie*4Ce* lyr] = 40te“*—4Ce—™ [yx] = -8Cte“™ +1200 * ya = tem So, [(s + 1)*(s + 2)]yr = [5° +45? +584 2yp = Ce =e Cs So, yr = te ‘Total Response: y(t) = yr t+ yw = te-™-+ (Ky + Kate“ + Kye", u(0) = 0,y'(0) = 1,y"(0) = 0 So, Ky+Ky=0 9 1-Ky+K_-2K351 9 —44+K,-2Kg+4Ka=0 So Ky = 4,24, Kg=4 y(t) = ten (4+ dient + den Zero-lnput: ysi (Ki + Katlent + Kge-™ with 9(0) = 0,y'(0) = 1,y"@) So, KitKs=0 9 -Ky+Ky-2Ky=1 0 Ki~2Ka +42 =0 So Ky =—2,K2=3,Ky=2 yam (-2+ Stet + 20° pete Zero-Stater yes = u(t) = (t+ Ko)e* + (Ki + Kate“ with zero IC. i So, Ki + Ka 1-Ky+K2-2Kg=0 9 -44+K,-2Ka+4Ka=0 SoKy=~2,K2=1,K3=2 yoo = (t+2)e-* +(¢—2)e ——— 4.12 (System Response) (@) "0 +37) + 2y(t) = 22) +2(), x)= Ault), yO) =2, YO) = Find ZIR as yu(t) = Kiet + Ker, y(0) =2, y'(0) = 1 oF yall Now, start with y'(0) +39 (t) +2u(t) = 2(@) <4, Fibd yet) =2. a Find ZSR as yi(i) =2+Kie™® + Kae", ya(0) = v4(0) = 0 oF y(t) = 2 —4erf + 20, Use superposition: Yes(t) = 2u{(t) + ys(t) = 2+ det — 6e™™ Find total response: y(t) = ysi(t) + vee(t) = 2+ Get ~ 9e- 54. Chapter 4 Analog Systems (©) VO +4YO +3u(t) =32"), 2) = 4e-*U(t), 4(0) ZIR is yai(t) = 0 (because initial conditions are zero) Stast with y(t) + dy'(t) + 3y(t) = a(t) = 4e~*. Find yp(t) = Ce = —4e-™ Find ZSR as yi(t) = ~4e-™ + Kre“*+- Kae, yi (0) = yi(0) = Oor ys(t) = ~4e-* 4-26-44. 26-4, ‘Use linearity: yua{t) = Syf(t) = Ge~* ~ ABer™ + Sev! Find total response: y(t) = ves(t) (0) vO +470) +4y() =2'-2, 2 4u(, 40) = 8, ¥O)=-3 Find ZIR as yai{t) = (Ki + Kate“, y(0) = 6, 1/(0) = —3 or yoi(t) = (6 + 91)e-. Now, start with y(t) +4y'(t) + 4y(t) = 2(t) = 4. Find y(t) = 1 Find ZSR as yi(t) = 1+ (Ki + Kate, ys(0) = 9 (0) = 0 or ya(t) = 1 —(1 + 2tje-™. Use superposition: yer(t) = f(t) — lt) = -1+ en + 6te~#. Find total response: y(t) = yyi(t) + yea(t) = 1 + Te“! + 15te~* ¥Q)=0 (A) 9") +290) +2018) = a(t) +22(¢-1), 2H = Au), (0) =0, VC =0 ZR is y(t) = 0 (because initial conditions are 2er0) Start with y(t) + 2y/(t) + 2u(t) = a(t) = 4. Find yr(t) =2. Bd 258 28 (t) = 2+ e-*[Acos(t) + Bsin(t)], (0) = xi(0) = 0 or lt) = 2 2e-*feos(t) + sin(t)] Use linearity and time invariance: y(t) = yea(t) = x(t) + 2ux(¢ ~ 1). (©) vO +5V@) + 6ult) = 2G) -22¢-1), zlt) = 2e~Ault), (0) = 0, (0) =0 ZAR is ya) = 0 (because intial conditions are zer0) Start with y"(t) + 5y/(¢) + 6u(t) = z(t) = 2e~4. Find ue(@) Find 2SR as yi(t) = et + Kie"® + Kae, un(0) = 400) (6) = vest) = vil) ~ Qual - 2). ) vO +5 @ + v0) = 2") 22-1), al Find ZIR as y(t) = Kiet + Kae, (0) = 4, Start with'y"(t) + 5y'(t) + dy(t) = x(t) = 36", Find yp(t) = Chet = tet, Find ZSR. as y(t) = tet + Kyert + Kge™, yu(0) ~ 9h (0) = Oor walt) = tent — fort + Be. Use linearity and time invariance: y(t) = yilt) + vest) = vat) + ¥f(0) ~ 2us(t 1) Use linearity and time invaria: 4.18 (Solution) (a) v(t) + 3u(t) = x(t). For impulse response, solve h’(t) + 3h(t) = 0, (0) = 1 A(t) = Ke“, h(0) = 1 or A(t) = e“*u(t) (b) u'G@) + 4y(t) = 20(8). Start with single input system y/(t) + Ault) = z(t) Solve p(t) + 4hig(t} = 0, ho(0) = 1 to get ha(t) = e~ Mult) Then, by linearity, h(t) = 2ho(?) = 2e~*u(t) Chspter 4 Solutions to Problems 55. (©) y(t) +2y(t) = 2'(¢) — 2(¢). Start with single-input system y'(t) + 2y(t) = z(t). Solve hi(t) + 2ho(t) = 0, ho(0) = 1 to get holt) = u(t), Then, by linearity, h(t) = a(t) ~ 2ho(t) = s(t) — 4e~ u(t), (2) v'O +) = 2'() —2(t). Start with single-input system y'(t) +y(¢) = z(¢). Solve Ao(t) + Ao(t) = 0, ho(0) = 1 to get ho(t) = e~tu(t). Then, by linearity, h(t) = hg(t) — ho(t) = 4(t) — 2e~*u(t). 4.14 (Solution) (a) v(t) + 5y'(t) + y(t) = 2(0). Solve h(t) + 5A'(t) + 4A(¢) = 0, BO) =0, (0) = So, A(t) = Kiet + Koe*, (0) =0, A'(0) =1 or A(t) = Bertult) — fe-“u(t). (b) ¥"() + 4v(o) +4y(0) (08 a vwith single-input system y"(t) + 4y/(i) + 4y(t) = 2(t). Solve ASCE) + Abg(E) + Aol) (0) So, ho(t) = (Ki + Kathe“, A , ha ‘Then, by linearity, h(t) = 2ho(t) = 2te-*u(t). © ¥0)+4/ (0 +5y(e) = 2210) —2(0), Start with singlo;nput system y"(0)+4y/() +8418) = 200. Solve g(t) + 4n6(6) + Bho(t) (0 = 1. So, hal) = een! + Kaen, (0) = 0, BQ) = tor yl) = (ert eal. ‘Then, by lineacity, A(t) = 2h4(¢) — ho(t) = ~2.5e*u(t) + 3.5e-u(t). (@) v') +270 +O = 2") +2'(. Start with single-input system y"() + 2v(t) + ult) = 210). Solve Aft) + Z(t) + ho(@) =0, ho(0) =0, A4(0) = 1. So, ho(t) = (Ki + Hatlet, ho(0) =0, ho{0) = 1 or holt ‘Then, by linearity, h(t) = Aj(t) + ho(t} = d(t) — e~*ult). 4.15 (Solution) Remember, for stability, every root must have a negative real part and the degree of the highest derivative of y(¢) must exceed the degree of the highest derivative of =(). (a) Yi) +4y(t) = 2(0) Stable (root is s = —4) (b) y'(t) - 4y(t) = 3z(t) Unstable (root is s = 4) (©) ¥(0) + Ault) = 2'() +82(0) Unstable (degree of y(t) equals (does not exceed) that of 2'(t)) (@) v(t) + 5y'@) + 4y(t) = 6x(t) Stable (roots at s = ~4, s= 1) or holt) = teu). ett). (0) 9") +49" + 4y(0) = 20'(t) ~2(0) Stable (two equal roots s = ~2) (f) yO) + 5) + Butt ‘"(t) Stable (roots at (g) ¥"(e) - 5y'(e) + 4ytt (h) of) + 2(t) — 3u(t) = 20'(t) Unstable (roots at (t) Unstable (roots at 56. Chapter 4_ Analog Systems 4.16 (Solution) (a) Refer to the circuit below. NR ence: x Kirchhoff’s current law at the output node gives Cy'(t) + B[u(t) — 2(¢)] So, y'(t) + 2y(¢) = A2(¢), where r = RC. So, yy = Ke-/", With z(t) = Le“*/2, we choose yr = Ce~!/™, 80, Yp=~(C/aje/* p(t) + tye(t) =-S +S = 12) $0, =1/(a—7) yrlt)= ev Soult) ye tun = ghee + Kentlr Assuming a relaxed circuit, y) <0 = gle + $0, t) = aBgler* =e“) (b) The impulse response of the RC circuit is A(t) = 2e~/"u(t). Asa+0, e7/* 0 and y(t) + [0 en} = Lert!" = hit) 4,17 (Solution) Refer to the following sketches. f 0 : er (@) of) = -e“)ult) A) = s(t) = emtult). (b) Since 2(t) = rect(t — 0.5) = u(t) — u(t — 1), by linearity and time invariance ult) = sft) ~ aft =) = (2 eHult) — 4 ~ eye — 1) By intervals: y(t) emt, O0° LTT, easel, dynamic, unstable. A 7 (© wt) = [ z(A)4\ ETT, causal, dynamic, stable (integration is over finite range) @ w= [easqae [toa 17, dynam, stable. Causal br a> 0 es = tate (©) v(t)= f 2(A~2)dd= [ 74 LTT, dynamic, stable. Causa for a <0 © [" 4.20 (Solution) (2) u(t) = 2(2t) Linear, time varying, dynamic, noncsusal, stable (b) u(t) = 2(-# (c) y(t) =2(0.5t) Linear, time varying, dynamic, causal, stable (4) v(t) = sgn{z(t)} | Nonlinear, time invariant, instantaneous, causal, stable « tat aetadr= ["" a(@de 07, dynamic, table, Cousal for a > —1. Linear, time varying, dynamic, noncausal, stable (e) y(t) =|x(t)| Nonlinear, time invariant, instantaneous, causal, stable 4,21 (Solution) Refer to the following table: = mee =a tale 2 [ey imear tor aay @ any @ [ey] Causal for (O 1, we find an(t) = Se 2D — ent = SemH(e? — 1) pat) = Se~OH — Fer = 5e-O1(602 1) Ie va(t) =wn(t) at €= 7, then 5e27(e? — 1) = 5e~927 (002 1) + eel This gives MT = OS T= og in (Se) = 1.868 t-M)u(t) (r= 0.5) 82M ult) (r= 5). 4,82 (Solution) Argue for or against the following statements assuming relaxed systems and constant element values. You may validate your arguments using simple circuits. (a) A system with only resistors is always instantaneous ond stable. True, See circuit 1 of Prob.4.29, for exemple. (b) A system with only inductors and/or capacitors is always stable. False. It is linear, causal, but ‘ot necessarily stable, For example, for v(t) = L(t) (an inductor), the operational transfer function H(e) = Y= sb isnot strictly proper, andthe system is unstable (©) An RLC system with at least one resistor is always linear, causal and stable. True. Examples: ‘Thie circuits of Prob.4.29 are linear, causal and stable. 62. Chapter 4 Analog Systems 4.33 (Solution) (a) Ale} = en **u(t). So, A(t) = ~ae™**u(t) + 6(2). Thus, A(t) + ah(t) = 6(t) or y(t) +ay(t) = 2(6) (b) A(t) = e~*u(t) — e-Pu(t). This suggests roots s = —1 and s = ~2 and a differential equation whose LHS is y"(t) + 3y/(t) + 2y(¢). Now, h(t) = ~e7t + 227% and AM(t) = emt ~ dem + 5(¢) So, h(t) + BN’ (f) + 2A(t) = dt) oF y(t) + 3y'(t) + 2y(t) = 5(0) SS 4.34 (Solution) (a) ¥() +2u(t) = x(t). The inverse system is y(t) = x/(¢) + 2x(t) (unstable) (b) y(t) + 2v(@) + y(t) = 2) + 2x), ‘The inverse system is y/(l) + 2u(t) =2"(0) + 20"(t) +.2(0) (unstable). ee 4.35 (Solution) (2) (0) = 2%(t) Not invertible (sign ambiguity) (b) u(t) = 22 Inverse system is 2(¢) = Inylt) (c) y(t) = cosiz(t)] Not invertible (ambiguity due to periodicity) (2) ve) =e") Not invertible (ambiguity due to periodicity) (e) u(t) = 2(¢-2) Inverse system is (t 2) = 2(t) oF u(t) = 2(¢ +2) (f) y'() +y() = 2(¢) Inverse system is y(t) = 2'(¢) + 2(8) COMPUTATION AND DESIGN 4,36 (Solution) Uses the ADSP routine sysrespt ‘XPROBLEN 4.36 We2;D=[1,2]; ystep=sysresp!((’s",1,D, [1 0 0 0 0)) Yyimpesyeresp1(’s? ,D) yes=sysrespi(’s? ,D,(4,3,0,0,0)) ytotssysrespi(’s”,N,D,[4,3,0,0,0] 6) ——— Chapter 4 Solutions to Problems 63 4.87 (Solution) Uses the ADSP routine sysresp1 ‘APROBLEM 4.37 PART (a) N=1;D=[1,10; ys=sysrespi(?s',N,D,[1 0 0 0 0)):yimsysrespt('s?,N,D); +$-0:0.01:4;eubplot(2,1,1),plot(t eval (ys)) subplot (2,1,2) ,plot(t,eval(y4)) ,pause wPART (b) Het ;DeLt ,sqrt(2) 10; ye=tysrecpi(’2!,N,D,[1 0 0 0 0)) :yissysrespi?s? .M,D); +¢-0:0.01:4;subplot(2,1,1),plot(t,eval (ys)) subplot (2,1,2),plot(t,eval(yi)) ,pause WPART Cc) w= (1,01;D=[1,1,195 yersyerespi('s'.N,D,[1 0 0 0 0]);yiesyerespt (7s? 1D); $=0:0.01:4;subplot(2,1,1),plot(t eval (ys)) subplot (2,1,2) plot (t eval (yi) ,pause ‘Wpant (@) NeasDe(1,2,2,10; ysrsysrespi('s?,§,D,[1 0 0 0 0);yissysrespi(’s? ND); 4*0:0.01:4; subplot (2,1,1),plot(t,eval (ys)) subplot(2,1,2) ,plot(t,eval(yi)) 4.88 (Solution) For step response and impulse response, see previous problem, YPROBLEM 4.38 Uses the ADSP routine trby Neat ;De(1,1] ;exbe(H,D,5) ,pause Net;D°C1,eqre(2) ,1] ezbv(W,D,5) ,pause ‘ove [1,01 ;0-C4,4,4 trow(H,D,6) Ytais will produce an error Ne(t,0) ;DeL1,1,1] ;yseeysresptC's?,¥,D,[1 0 00 01); t=0:0.01:10;yeeval (ys) jsubplot ,plot(t, 9) ee nt; intine(yor0.1 byce0.9) pLndength() strisent(4(2))-t(4(1)) infind (abs (1-y)>=0..05) sLeLength(4) ;taet=t (2 (1), pause N=(1];D=(1,2,2,1] serbw(W,D,5) 4.39 (Solution) Uses the ADSP routines sysrespi, txbs {APROBLEN 4.38 ‘PART (a) C+3;i=1 ;D=[1 4,0] sys"sysreept (787 ,N,D, [1,0,0,0,0]) sysmeyer sept (757 yD); €=0:0.01 :Bjeubplot(2,1,1),plot(t eval (ys)) _ subplot (2,1, 2) ,plot(t eval (yi)) pause (Caajtien :D=[1,4,C] syseeysrespi (18? ,N,D, [1,0,0,0,0]) iyieeyerespi (?s” ,¥,D) $-0:0.01:8;subplot(2,1,1),plot(t,eval(ys)) subplot (2,1,2) plot (t eval (yi)) ,pause 64 Chapter 4_ Analog Systems (O-5;:Net ;D=(1,4,C] ;ysesysresp1(’s? ND, [1,0,0,0,0]) ;yissysrespt(’s!,N,D); 90:0.04:S;subplot(2,1,1) plot (t,eval (ys)) subplot (2, 1,2) plot (t eval (y3)) ,pause WPART (b) C*5 shows snallest tr and ts PART (o) Ge3;Net ;D=(1,4,0) strbwN,D) pause (C=4;e1 ;D=C1,4,C) strbwW,D) pause (Ce8 jist ;D=(1,4,C] strbw(W,D) 4.40 (Solution) Uses the ADSP routine ssresp ‘PROBLEM 4.40 27(2,8,-pi/3] i6°0:0.01:35 PART (a) in ;Ne2;D=L1 a] ;yssi=ssresp(?s? ,N,D,x) plot (t,eval (yss1)) ,pause a-2;8*2;D-[1 a] iyss2=ssresp(’s’ ,N,D,x) plot (t,eval (yss2)) ,pause wPART (©) (e3;Net;D=(1 4,¢] ;yss3=ssresp(’s? ,M,D,x) ,plot(t,eval (yss3)) pause (Cad :Net jD=(14,C) jyssd=ssresp('s? ,W,D,x) ,plot (t,eval(yss4)) ,pause (Co8;Ne1 jD=(1,4,C] ;yse5=ssxesp ("s? ,1,D,x) ,plot (t,eval (yss6)) 4.41 (Solution) Uses the ADSP routines urect, ctsim PROBLEM 4.41 Nea ;D=[1 a) x=" urect (t-0.8) 7 ;t=0:0.1:3; yeor(1~exp(-t)) .* (te=1)+(exp(-t+1)-exp(-t)) ynectsin(,D,x,t) ;plot(t,yn,t,ye) ,pause (et); MPART (0) a= ;N=a;DeUt a) jx='ein(t) .#(cemps) stm yanctsin(N,D,x,t) :plot(t,ya,t.eval(x)) a3;HeasD=(t al sx='sin(t) -#(ocepi) ;t=0:0.02:6; yu=ctsin(M,D,x,t) ;plot(t,ya,t ,eval(x)) ,pause ae10;N=a;D> [1a] jx='sin() .* (<=pi);£°0:0.02:6; . ynectsia(W,D.x,t) ;plot(t,yn,t,eval (2)) pause 0.02 wart (©) ‘a=1005I-aD=(1,a] x=? sim(t) *(eeepi)? j£-0:0.02:65 yurctsin(I,D.x,t):plot(t,ya,t,eval(2)) ,pause 8100; Mea; D=[1 ,a] jx=?sin(t) .*(e 0, this simplifies to yfn} = 4 — }121(0.5)" +7(—0.8)"] Chapter § Solutions to Problems 5 5.13 (Solution) (a) vip] =vls—1]=2fo) fa) = Alm —3} +259] A=] =0 n=0: — Alo] =Al-1] +2s(0) =2 nel: Af}=Aloj+2s] =2 n Aig] = Ali] + 2612] 2 n=3: AB] ApJ+259) =2 n=4: Als]=Als]+25q) = 2 (b) ufn)—3yin—1}+6yfn—2) 3] fn] = 8hfn—1]-Ghin—2]+8In—1], Al-I] = AZ] =0 n=O: hl0] = 3h{-1]-6h{-2]+4[-1]=0 n=l: All]=3h(0)~6h{-1]+<[0) =1 n=2: Al]=sh[t]—shio}+en] =s naa: Als) = 3h] ~6A{0) + 5f2) n=4: hid] =9A(3)-6A2)+58] = 9 (© vb]-2yfn-3)=2]n-1] Ap] =2hfn—3]4+4n-2] Al-2]=A[-2] =A[-3] =0 Alo] = 24[-3] + 6[-2] = 0 nal: Af) =2h{-2]+4(0)=1 nm2: Ald] = 2h[-1]+4[1] =0 nm3: Al] =2h(0 +52) = 0 nad: Als]=2nft}+sf] =? (@) vin) -yln 1} + 6yfn —2] =nafn— 1} + 2ein 3}, So An] = Afr ~ 1] ~6hjn ~2)+ nd —1] + 262-3) Al-] =A[-2] =0 [-1] ~ 8hf~2] + 05f-1] + 261-3} =0 0] —Sh[-1} + 150} + 261-2} = 2 A] ~ 60] +2601) +26{-1] = (2) ~ 6) +3614) +25(0) = ~3 [5] — 6h [a] +453) +26] = 9 5.14 (Solution) (@) ye] =2in} +2{n—1]+2{n—2} FIR, Cousal Ho) = G(r] + dfn —1] + 5{n—2), (Na) = (2,1, 1} (®) vial = An) = Sr 1} + dfn] + 5fn — 1}, {Hin} = {2,243} {n+ 1+aln]+2{n-1) FIR, Noncausal (©) vin] +2yhn— 1) ==[n] IR, Causal 1G: Ajo] =1 —Alaj=K(-2)"Af]=1=K — Af} = (~2)"4fn] 76 Chapter 5_ Discrete-Time Systems (4) yfn]+2y[n-2] =2{n-1] UR, Causal Start with hoin) + 2ho[n — 1] = an). From part(e), hola) = (—2)"xln} By timeinvariance, hfn} = hol ~ 1] = (-2)"vfn—1] (©) fr] +2yfn — 1] = 2e{n] + 6[n — 1], IR, Coussl Start with holn} + 2ho[n ~ 1] = 2{n- From part(c), ho{n] = (—2)"x[n]. By lineasity and time-invariance ‘ln] = 2holn] + 6hgfn ~ 1] = 2(~2)"u{n] + 6(—2)"Fufn — 1) (®) ule] +2yfn— 1] = 2[n+1] +4efn} + 62[n—3] TER, Noncausal Start with ho[n] + 2ho[n — 1] = 2{n). From part(c), ho{t] = (—2)"u[n]. By linearity and time-invariance Al] = hol +1] + 4ho[n] + 6holn — 1] = (—2)"+4ufn + 1) + 4(—2)Pufp + 6(—2)"-#u[n — 2] (ge) fL4 428 + 32-4ly = [2-%2, UR, Causal Start with [1-4 4z7! + 32"A]y = z. Its impulse response is hhgfn] = A(-3)" + B(—1)? with ho[-1] = 0, Ao[0] = 2. S0o,-¢-B=0 A+B As15,B=-05 — hofn] =(1.5(~3)*-0.5(—1)"Juln] By time-invariance, Aln] = ho{n ~ 2] = [1.5(—3)"-? ~ 0.5(—1)"-2}uln ~ 2] (h) [27 +424 dy = [2+ 3]z, IR, Cousel Rewrite this as (14427! 4 42~Mly = [21 432M Start with [1+ 42"? 442-2] = Its impulse response is holn] = (A+ Bn)(—2)* with hol—1] <0, holO} =1 80,-0.5(4~B)=0 A=1 Bol hofn]=(1+n)(-2)" By linearity and time-invarisnce fn) = hon — 1] + 3hofr — 2] = [1+ (= 2)](—2)" Ful ~ 1) + 3/2 + (m= 2)](—2)"-2ujn — 2] (i) 2 +4248) =z, DR, Causal Rownite as [1-4 427? + 82°2]y = [2]z 7 Start with fl +42" 4 82%}y =z ‘The roots: ~2:4 32 = -2V2Li 40 give holn] = (—2V2)"|Acos(0.25nx) + Bsin(0.25nn)} Ag] =0=(4-B) fyl]=1=A Bad ‘ofn] = (~2V2)"{cos(0.25nx) + sin(0.25nn)]. By time-invariance fn 2] = (~2V3)"-*[e0s(0.25(n — 2)x) + sin(0.25(n — 2})]ul ~ 2} This simplifies to A[n] = }(—2V2)"[sin(0.25nn) — cos(0.25n2)}ufn — 2] G) vin] + 4yln —3] + 4yln— 2] = z[n) — z[n +2], OR, Noncausal Start with yfn) + dyn —1] + 4yfn — 2] = afr). Its impulse response is ho[n] = (1 + n)(~2)" (from part h). By linearity and time-invariance Alp] = ofr] — hol +2] = (2+ n)(—2)"ufr] ~ [+n + 2](—2)"42ufn +2} Chapter 5 Solutions to Problems baa 5.15 (Solution) (a) vln] =2{n-1]+2[n] +2in +1} Noncausal and stable (FIR filter) (®) yfnj =z{n] +2{n—1]+2[2-2) Causal and stable (FIR filter) (©) vin] —2y[n 1] =2[n] Root is z=2, s0 unstable (J2| > 1). Also, hn] = 2*ufn]. So, causal. (8) yfn] - 0.2y[n 1] =2{n] —22[n+2] Noncausal (due to 2{n + 2}} and stable (root is z = 0.2). {e) yin] +yln 1} +0.5y{n~2]= in] Causal, Roots: 0.5 £ 30.5. So [2| = 0.707, so stable. (0 be sn — 1+ sin ~ 2) = af] [p41] Nonenusal Roots: + = 06:41.5. So [el 2 1, 20 stable (s) vfr} - 2y{n ~1) + yfn - 2] = 2[n] —2{n —3] Causal. Roots: x = 1. So unstable. (a) yin] —Syfn—i] +2y[n—2] = 22{n+3} Noneausal. Roots: z= 2, 22 = 1. So unstable (|2| > 1) 5:16 (Solution) All systems are static. (a) yin} = 3"=[n) Linear, time varying, causal, stable (®) yin] =e%"*z{nj Linear, time varying, causal, stable (c) yln] = cos(0.Snm)z{n} Linear, time varying, causal, stable (A) yln) = [1 + c0s(0.5nx)}z[n] Liness, time varying, causal, stable (e) yln] =e!) Nonlinear, time invariant, causal, stable (©) fn} = <[n} + cos{0.5(n-+ 1)} Nonlinear, time invariant, causal, stable 5.17 (Solution) (a) y[n] = 2[n/3] Linear, time varying, causal, stable (b) vin} = cos(nz)z{n} Linear, time varying, causal, stable, static (e) vln] = [1 +cos(nz)}z{n} Linear, time varying, causal, stable, static (4) fn] = cos(nea[nj) Nonlinear, time varying, csusal, stable, static (€) vin} =cos(nx +2{n}) Nonlinear, time varying, causal, stable, static (©) vin] =a{n)-2[n—2] LTT, causal, stable (6) vin] = 0.5z/n] +0.52ja—1) LTT, causal, stable x (a) vin] = 4 Yo zin-&) LTT, causal, stable t () gla] -ayln~ 1] =az{n], 0 sin(0.Sn)] 5.22 (Solution) Refer to the sketch for the realizations. wba separ Reve fer Iaverse of reve iter (2) ufo] = 2{n) + 0.25y fn — N]Now, $= 2 kl, so t, = 0.5 ms. A delay of 1 ms means N = 2. (©) vfr]~0.25y[n—2] = z{n}. Its impulse response is hf) = A(0.5)"+2(-0.5)", We find AO] =1= A+B, Al-1]=0=24-2B. So, (-05)"] For the step response, v{n] ~ 0.25y/n— 2} = ufn]. We find yr =O = $ So, yln] = $+ A(0.5)" + B(-0.5)", y{-1] =0, y[-2] =0. Thus ee yl-1]=0=24-2B+4, yf-2]=0=4444B4 4. S0,A=-05, B=} and + 05)" 0.252{n — 2]. Its impulse response 25uln- 2]. (6) The diference equation ofthe inverse system is yl] = afr i n} — 0.256(n — 2). Its step response is s[n) = un] 5.28 (Solution) yln] - 0.5y[n~ 3] =a{n). So, yw{n] = K(0.5)" (a) [0] = un). So, yr = C. $0, 0-050 =1 and C= 2. 2SR is yesln) = K(0.5)" +2, yl-t] = 0. This gives 0 = 2+ 2K or K (b) ={r] = (0.5)"uln}. So, ue = Cn(0.5)". So, [Cn — 0.5(n — 1)0(0.5)"](0.5)" = (0.5) and C = 1. ZSR is vealn} = K(0.5)" +1(0.5)", y[-t] = 0. This gives 0 = ~24+2K or K = 1 80 Chapter 5_ Discrete-Time Systems (©) z{n] = cos(nx/2)u(n}. So, yeln] = Acos(0.5ne) + Bsin(0.Sn) = 0.8cos(0.5nn) + 0.4sin(0.5nn) (form Problem 5.44). So, ZSR is vesin] = K(0.5)" + 0.8c0s(0.6n) + 0.4sin(0.5nx), y[-1] So, K(0.5)"? + 0.8cos(~0.5n) + 0Asin(-0.5r) = 2K ~0.4=0 or K = 02. (4) z{n] = (-1)"ufr}. So, yr = C(-1)*. So, [C + 0.5C)(-1)* = (~1)" and C= ZSR is vesln] = K(05)" + 2(-1)", v[-l] = 0. This gives 0 = -3 + 2K or (©) zip] =s"ufn}. 80, yr = OG)* and [0 + 30.5](4)" = i)" or © = ees ZSR is yee(n] = K(0.5)" + pegg(i)", y[-1] =0. So 0 = 2K — aes, Note that the response is complex valued because the input is cormplex valued. (8) fn] = (VIP ula] + (VIM uln = ef + mF = 2.c05(0.25n7) So, ve[n] = Acos(0.25nn) + B sin(0.25n). Substitute into vr(n] ~ 0.5yrln— 1] = 2cos(0.25n7) to find A= 2.3815, B So, ZSR is yasin] = K(0.5)" + 2.3815 cos(0.25n7) + 1.3025 sin(0.25n7), yl So, 0 = 2K + 2.3815 cos(~0.25r) + 1.3025 sin(0.25n) or 3815 0 3025. 5.24 (Solution) For the realization, yln] = 2{n] — 0.5y{n—1] or yfn] + 0.5yfn - 1] = z{n]. So, yin] = (-05)* sD yin) °, Figure P5.24. System realization for Problem §.24 (a) zn) =uln}, yf ). So, yr[n] = C. So, C+05C =1 or C = So, yn] = K(—0.8)" + 2, y[-I] = 0. This gives 0= 24+ For K =} (b) zn) = win, y{-1] = 4 Follow part (a) and set vuln) = K(-05)" +4, y[-1] =4. This gives 4 = 24 + For K= 38 iC) abl = = (05)"ufr], y[-1] = 0. So, ye[n] = C(0.5)". So, [C + 0.50(0.5)“*(0.5)" = (05)* of 08. 50, vin] = K(~0.5)" +0.5(05)", yf— (4) x{n] = (0.5)"uln], [1] = 6. Follow part (c) and set le] = K(-0.5)" +0.5(05)", y[=1] =6. This gives 6 = -2K +1 or K = ~25 (©) afr] = (-08)%uo},_ afl] = 0. So, yale) = Gr-0.5)". So, (On + 050(-05)-1(-05)" = (-05) 1] = 0. This gives O= 24 41 or K= 0.5 So, yln] = K(—0.5) +n(-0.8)", yf-i] = 0. This gives 0= ~2K + 20r K=1 (£) 2{p] = (-0.5)"uln}, y[-1] = ~2, Follow part (e) and set, yfr] = K(~0.5)" +n(~0.5)", y[-l] = 2. This gives -2 = -2K +2 or K Chapter § Solutions to Problems 81 5.25 (Solution) For all parts, start with yo[n] ~ 0.4yofn — 1) = 2(0.5)", vo[—1] = 0, ‘Then, vel) = C(0.5)" ot (C—0.8C) =2 or C= 10. So, yoln] = K(0.4)" + 10(0.5)". So, yo{—1] = 0 = 2.5K +20 or K = -8 So, yoln] 8(0.4)" + 10(0.5)"}ujn] (2) uf) ~0.4y{n— 1] =2(0.5)"*ujn— 1], yf-1] =0 By time invariance, vf} = yo{n — 1] (b) vbr] ~ 0.4yin— 1] = (0.4)"ufn)] +2(0.5)"2ufn—1}, yf-2) = 25 Its ZIR is vuln) = K(0.4)", y[—1] = 2.8. So, K = 1 and vailn] = (0.4)" ur] For the input (0.4) un}, the forced response is ye{n] = Cn(0.4)". So, ele] - OAyrin — 1) = [Cn — 0.4(n ~ 1}0(0.4)-4](0.4)" = (0.4)" or C= 1 Its ZSR is yaln} = K(0.4)" + n(0.4)", va[-2] =O. So, 0 = 2.5K - 2.5 or K = 1. So, vila] = [(0.4)" + n(0.4)"]uln] By linearity and time invariance, y{n] = yoln ~ 1] + vafn) + valn) (©) vfp] = 0.4yfn — 1] = 2(0.8)"uln] + 2(0.5)"*ujn— 1), yl-1] = 2.5 From part (b), ite ZIR is yxifn] = (0.4) ula] For the input n(0.5)"u[n), the forced response is ye{n] = (A + Br)(0.5)". So, yeln] ~ 0.4yp{n — 1] = n(0.5)" or (A + Bn) -0.8[4 + B(n 1] =n or A= -20, B=5. Its ZSR.is yafn] = K(0.4)" — (Sn ~ 20)(0.5)*, yal~I) = 0. So, 0= 2.5K ~50 or K = 20. So, valn] = [20(0.4)" — (Gn — 20)(0.5)"Iuln] By linearity and time invariance, yin] = yo[n ~ 1) + yal) + val") 5.26 (Solution) J = jn] — sf — 1) = ft, ~1p (a) yln] =z[n]—zfn-1] So, (b) pln] = 0.52[n] 4+ 0.52{n 1). fn] = 0.56[n) +.0.55fn—1] = (05, 0.5} 2 2 (© h]=4Sozin—¥) Af) = Sone = 9, 1, 1} & S (@ Afe)= 3 Se— hain ~ = 1820 = (6) vip] ~ ayfn ~ 1] = (1 ~ aan) = {ni}, we have hofn] = K(0.5)", ho[0] = 1 or K = 2. \Sz[n}, we have A{n] ~ 0.5h9[n] = 0.5(0.5)" For y[n) ~ O.5y{n — So, for yin) - 0.6yln ~ 1) 82 Chapter 5 Discrete-Time Systems 6.27 (Solution) System: y[n]+ayln—I]=a(n], (@#0) Response: yfn] = 5 + 90.5)". (2) veln=5 gin) = 300.5)" (b) @ =~0.5 and y[-1] =5 +6=11, (c) yiln] = K(0.5)*, y[-1] = 11. Thus 11 = 2K and yafn] = 5.5(0.5)". alr] = K(0.8)" +5, yl] =0. Thus 0 = 2-4-5 and yesfn] = -2.5(05)" +5 (4) 2{n] = Auln}. So, uefa] - OSueln — 1] = 4 or A= 5-056) =25 [5(0.5)" + 3(-0.5)")uln). Response: yf 5.28 (Solution) System: yln] +0.5yln— (a) veln] = 5005)" wv{n] =3(-0.5)". Also, yf-1] = 10 — So, vuln] = K(-0.5)", y[-1] =4. Thus 4 = -2K and vei edn] = K(—05)" +5(0.5)*, yf Thus 0 = ~2K +10 and ysl 0.5)" 5(-0.5)" + 5(0.5)"}u(n. (©) Ie yl-1} = 20, yaa] = K(-0.5)" and yl=1] = 10 = ~2K and yal} = -5(-0.8)". (©) For ola] + 05y{n.~1] = xf ~ 2, the response is yee — 2] [a =1] + 2x{n, the response is yes[r — 3] + 2yuala] (€) For y(n} +0.5y{n — 1] 5.20 (Solution) System: y[n]+ayln~1]= in] Response: yln — 2] = (5 +2n)(0.5)"uin. (a) We see thet @ = 0.5, yv{n] = 5(0.5)" and yelp) = 2n(0.5)". Also, y[-1] = (5 ~ 2)(0.5)" = 6. K(05)", yl-1] =6. So, 6= 2K or K = 3. Fee [(2 + 2n)(0.5)"}uln] So, vail] (0.5)*. Thus, yes{n) = y{n) ~ veil So, veiln] (b) If yl-1) = 20, yan] = K(0.5)" and y[—1] = 10= 2K and wafn] = 6(-0.5)" (c) For the input z[n ~ 1}, the response is tesln — 1] (d) For the input 2z{n — 1] + z{n], the response is 2¥es{n — 1] + veeln] (0.5)" and y[-1) = 4= 2K and yan] = 2(-0.5)*uln). (e) I yl-1] = 4, ala) So, for the input 2z{n — 1] +2[n), the response is 2yes{n ~ 1] + yuan] + veiln] Chapter § Solutions to Problems 83, 5.30 (Solution) In all cases, the input is un} (a) System 1: y[n] = 2{n]—z[n— 1], System 2: yln} = 0.5yln— 1] + 2[n} Output of system 1 is ys{n) = ufp] — ula — 1] = dfn}. So, the output of system 2 is its impulse response. So yzfn] = (0.5)"ufn} (b) System I: yn] ~ 0.5y[n — 3) , System 2: yfn) = 2{n] — z[n — 1} The output of system 1 is yn] = yeln)+yw{n] = 2+ K(05)". With y[-1] =0 = 242K, we get K = =1and yin] = [2 - (0.5)"Jufn) ‘The output of system 2 i vo[n] = yln] — yin ~ 1] = [2 ~ (0.5)"Julnl — [2 — (0.5)"—"Jula— 1] Simplifying, yp] = 2(ufn] — fr — 1) ~ (08)" ful] —2uln — 1] = 25fn]~ (0.8)"6ln] + (0.5)"ufp — 1) Toa el = A +5)" Ih = (08), Tha the ode of aang dove not mater here (because both systems are (©) System 1: yln} = 2%[n], System 2: a = 0.5y[n—1]+2[n] ‘The output of system 1 is y[n} = u2[n] = ufn). ‘The output of system 2 is thus yafn] = [2 — (0.5)"Jufn] (step response from part (b)) (4) System 1: yfn) = 0.5yfn— 1] +2{n}, System 2: yln} = 2%[n} ‘The output of system 1 is yin] = [2 — (0.5)"}ufn] (step response from part (b)} ‘The output of system 2 is yo[n] = [2 ~ (0.5)*}*uln]. The response is not the same so order of cascading is important (because the squaring eystem is not LT). 5.81 (Solution) Refer to the sketch Figure P5.31. System realization for Problem 5:31. (a) For the two feedback subsystems, yfn] —ayln — 1} = 2[n] and yln] ~ Byfn ~ 1} = 2[n) Their impulse response is hi[n] = a" unj ond hain] = Bul For the overall system, fn) = hyfn] ~ ho[n ~ 1] = a"u[n] ~ 6" ul — 1] (b) For a = 8, hl) = o*uln] - @”Aujn — 1] and the difference equation is ln] ~ ayln - 1] = 2{n] — af] (©) Fora =6=1, Ayla] = hale] = wlp) and inj = uln) - ul — 1) = din). ‘The difference equation is yfn] = z{n]. The overall system is an identity system 84 Chapter 5_Discrete-Time Systems 5.32 (Solution) (a) Afr] = 5p] + 26{n ~ 1] So, yfn) = fn) + 22fn — 1) (b) Ale] = (2, 3, -1) == 26(n-+ 1] +36[n] ~é[n—1] So, vfn} = 22{n +1) +3z{n) - 2{n—1] (©) Afr] =(03)*ufn] So, difference eq has the RHS yln} ~ 0.3yln ~ 1] So, we find Afr] - 0.3h{n ~ 1] = (0.3)"u{n) ~ (0.3)"-Fufn — 1] = (0.3)"(uf So, uf] — 0.3y{n ~ 1] = afr ~ 1) =r] (2) fn] = (0.5) ufn] — (—0.5)"ufn] The roots are z = £05, so the RHS of the difference equation hhas the form yjn] ~ 0.25y/n ~ 2]. So, find hfn}—0.25Afn—2] = (0.5)"ufn]—(—0.5)"ufn]—0.25(0.5)"-2ujn~2]-+0.25(—0.5)"-2ujn—2] So, bln] — 0.25h[n — 2} = (0.5)"(uln} — ula —2}) — (-0.6)*¢ujn] — uf ~ 2) = dfn] +-0.85n — 1] - Sfp} + 0.55[n ~1] = dfn —1] So, yfn] ~ 0.28yfn— 2] = efn— 1] 5.33 (Solution) A[n] = (~1)"u[n]. The difference equation RHS has the form y[n] + ln — 1). So, find Afr] + fn ~1] = (=1)?ufn) — (-2)"-2ufn — 1) = (~1)"(ufr] ~ fn ~ 1) = dfn. So, yln} + ule ~ 1] = 2fn] The difference equation of the inverse system is vf performs an averaging operation. {n) + 2[n 21]. This is an FIR filter thot 5.34 (Solution) (2) O +87 (0) +2960) = 2u(t) Ch. Eq: 8? +35+2=0 Foots: s=—2,-1 Negative real parts, so stable system. (b) Bockward Euler algorithm: y(t) — vin] yla— 1] y"(@) = vln) -2uin— 1} + yf 2] - Soy y(t) + 3y/(t) + 2y(é) = 2u(t) + yfn] ~ 2ylm— 1} + y[n— 2] + 3(yln] —yln —1)) + 2ufn] = 2ufn] This simplifies to: yln] ~ yf — 1] + ulm -2] = dufn] Ch. Bq: A f2+}=0 — roots: z= 4, J. Stable because [zoel ?) pause 5.45 (Solution) Uses the ADSP routine atplot YEROBLEN 8.45 N=0.25¢E1,1,1, 1] ;D=[1,0,0,0,-1] :n=0:605 x-ones (size(n)) ;y=filter(W.D)2) 5 subplot (2,1,1) ,dtplot (a,x, 0"), subplot (2,1,2) ,dsplot(a,y,’0") pause x20. Lenjyatitter(W,D,2); subplot (2,1,1) ,dtplot (a,x, ’0") subplot (2,1,2) ,dtplot (n,y, 707) ,pause xesin(0. 1anspi) :y-fil ter (MD, 2) 5 subplot(2,1,1) ,dtplot (n,x,’0") ,subplot(2,1,2) ,dtplot(m,y,’o") ,pause x=0, Lentsin(0.Senepi) ;yefilter(W,D,x)5 subplot (2,1, 1) ,dtplot (a,x, 70), subplot (2,1,2),dtplot(a,y, 70”) pause xe(zen(n,5)=-0) sy~filter(N.D.2) 5 ‘subplot (2,1,1) ,dtplot (a,x,'0") ,subplot (2,12) ,dtplot (n,y,"0") pause x=(zon(n,4)=0) sy=ti2ter (N,D,2) 5 subplot(2,1,1) ,atplot (n,x,'o") ,subplot(2,1,2) ,atplot(n,y,?0") 5.4 (Solution) Uses the ADSP routine dtplot PROBLEM 5.46 130:199;, xe (0.9 -7 a); yL=[x;O¥x;08x) syeyt(:)? sy=y(1:200) 5 subplot(2,1,1) ,dtplet(a,x,’.’) ,subplot(2,1,2) ,étplot(a.y,?.’) pause x7c0s(0.0¢enspi) ;yncos(0.2404pi) =x; subplot(2,1,1) ,dtplot(a,x,”.”), subplot (2,1,2),dtplot(a,y,’."),pause x=c05 (0.0entpi) sy (1+co5(0.2enepi)) #5 subplot(2,1,1),deplot(e,z,”.'),subplet (2, 1,2),atplot(a,y,?.!) Chapter 5 Solutions to Problems 5.47 (Solution) Uses the ADSP routine depot PROBLEM 5.47 n=0:60;x-0. 1¢ntsin(0.14nepi) ;x1=0.1#(n-1)+sin(0. 1¢(n-1)4pi); x2-0.14(n-2) +5in(0.1*(a-2)*pi) ;x3-0. 1+ (n-3)+ein(0. 1*(n-3) pi); N=0,25+[4,1, 1,1] ;Dedsy-filter (W,D,x) ;yd=0. 25¢ (xrat+x243) ; subplot (2,2, 1) ,dtplot (n,x,’.*),title(?impat’) subplot (2,2,2),dtplot (n,y,?.?),title(*output of FILTER.N?) subplot (2,2,3),dtplot (n,yd,”.?),titleDirect computation of output’) subplot (2,2,4),atplot(a,y-yd,'.?),title Cerror = FILTER - direct’) ,pause WeO.25¢ [4,3,2,4) ;D=1;ynfilter (N,Dyx) jyd-O. 254(4ext3ex14 2422123) ; subplot (2.2.1) ,deplot (a,x,?.1),titte(imput’) subplot (2,2,2),atplot(a,y,’.?),title(output of FILTER.W) subptot (2,2,3),atplot(a,ya,’.') title Direct computation of output’) subplot (2,2,4) ,dtplot(a,y-ya,’.’),title (error = FILTER ~ direct’) ,pause N-0.4;D=[4,-0.6] sy-filter(N,0,x); Wo direct way possible subplot (2,1,1), dtplot (a,x, ?.?),title (input?) subplot(2,1,2),dtplot(n,y,’.?),title( output of FILTER.W?) 89 5.48 (Solution) Uses the ADSP routines dtpiot, randist PROBLEM 5.48 +0:60;x00. ientsin(0. tenepi) trandist (a, ‘uni? ,0); x10. 1¢(a-1) +5in(0.1*G-1) pi); 22=0.1¢(a-2)+5in(0. 1*(a-2)*p4) 2360. 1* (2-3) 4sin(0.14(n-3) pi) ; Woo. 25¢(1,1,1,1] ;D=1 ;y=tilter (ND x) syde0. 25 (xt 4x2423) ; gubplot (2,2,1) ,dtplot a,x,?.°), title input?) subplot (2,2,2) ,deplot(n,y,".’),title( output of FILTER.) subplot (2,2,3),éeplot (n,ya,’.’),title(’Direct computation of output’) subplot (2,2,4) ,deplot (a, y-yd,’.!),title (error = FILTER ~ direct’) pause N=0.254[4,3,2,1] ;D=1 ;y=ti1ter (W,D, x) ;yd-0. 25+ (GextSext+24x20x3) 5 subplot (2,2,1) ,atplot(a,x,?.°),titieC input’) subplot(2,2,2) ,dtplot(a,y,’.?),tétle( output of FILTER.) subplot (2,2.3) ,dtplot (a, yd,’.’),title('Direct computation of output’) subplot (2,2,4) ,dzplot(a,y-yd,?.°) title Cerror = FILTER ~ direct’) pause N=0.4;D=[1,-0.6];y=f41ter(W,D,x); No direct vay possible subplot (2,1,1) ,atpiot(,x,’."),title(input’) subplot (2,1,2) ,dtplot(n,y,?.), titleCoutput of FILTER.W) 5.49 (Solution) Uses the ADSP routine dtplot PROBLEM 5.49 2+0:60;x~sin(atpi/8) ; Ne[1 i] ;Det;y-tilter QI,D,x); subplot (2,1,1) ,dtplot(n,x,’.’), subplot (2,1,2) ,dtplot(a,y,’.") pause N=(t,-2,1] sDetiy=falter (W,D,2); subplot(2,1,1) ,atplot (a,x, ’.7), subplot (2,1,2), dtplot(a,y,’.”) ,pause Ne(1,1,1]/3;Delsy=tilter(N,D,x) ; subplot(2,1,1) ,dtplet (a,x, ’.’), subplot (2,1,2), atplot a, 7, ”27) pause 90 Chapter 5 Discrete-Time Systems Ne(2,2,1] /2;D=1;y=fi1ter(,D,x); eubplot(2,4,1) ,deplot (a,x, ’.*),subploe(2,1,2) ,atplot a,y, ” 5.50 (Solution) Uses the ADSP routine atplot, sysrespi PROBLEN 5,50 2n+0:30;Ne(1,0) ;Del1,-0.8); sskeresysrespt (/2? HD, [1,1,0,0,0,0)) ,Atplot (a,eval(ystep) ,’") ,pause Yimpssysrespi (*2?,N,D),dtplot(a, eval (imp) .’0') .panes yeerevsrespl(’z?,H,D,[1,0.5,0,0,0,0]) ,atplot(a,eval(yzs), ’0") pause wetreyerespt('2? M.D, [1,0.5,0,0,0,0) ,~4) ,dtplot(n,eval (vel) ,’0°) pause Ne[+,0,0} ;De[1,1,0.5}; yt2=sysrespi(’2?,H,D,[1,0.5,0,0,0,0), 531), dtplot (n,eval (yt2) 0") ‘You could also use dtsimgul. The gul shows the results of part (d) Chapter § Solutions to Problems gu. 5.51 (Solution) Uses the ADSP deta file echosig.mat HEXAMPLE 5.51 oad echosig 1 Load echo signal sound(echosig) Listen to echo signal Nt=fix(0,09375*8192) ;2-2401; 4 Filter delays ne[t zeros(,¥2)]; 4 Nuerator of inverse aL1 zoros(1,H1-1) 0.9 zeros(1,N2-Nt~£) 0.8]; % Denominator of inverse noechorfilter(a,d,echosig) ; % Filtered signal sound (noecho) 4% Listen to filtered signal Chapter 6 CONTINUOUS CONVOLUTION 6.1 (Solution) Refer to the figures below (a) 2) =r(t) (b) a) eult-2)— (e) a(¢) =205~ 0) (@) a(t) =e (a) ) 0 HQ) Ye hay (29 ieee ees acy a [a a i i n aes oz @ @ 200 nO) et) po fray fea) 2 pe : ty i a 6.2 (Solution) yt) fs a(A)A(E —A)aA = f © te nO) Att =0, this simplifies to x)= [" servers f° * tm aa)24 (a) x(t) = u(t - 1), A(t) = u(t +2) ul y= [20 neayar= [7 wa-3ue— ajar [arm (©) x(t) = w(O, al = u(t —1) wire fF acaneyte [one-nes [10-0 fi pe tec (c) a(t) = tule +1), A(t) = (¢ + I)u(t) vo)= [7 sayn—nar= f roosaya-a(-ajor= f' x0-Har = (a) =(t) = w(t), Alt) = cos(0.Sxt)rect(t/2) = cos(0.5at)[ult + 1) — u(t ~ 1)] (0) = [Laer = fs ul) c0s(0.50)fu(A +1) — wld 1)}d ad = -2/3 1 ° ° ° v0) = [ {ested} — i corfana)aa = J cos(05na)di = 2 sn(a.sna) 22 - Note: The second integral is zero because upper lim < lower lim. 92 Chapter 6 Solutions to Problems 93. 6.5 (Solution) (a) 2(t) =e-u(t) A(t) = F(t) = tu(t) wo) [ 7 a(t A)R(A)EA = [ . eMule — a) uA ‘With a =1, this simplifies to y(t) = (t—-1+e~)u(t) (b) 2(¢) =te-**u(t) A(t) = ut) at) = f z()R(E — A)aA = f Ae“ u(aju(t —2)d = if dey = T+ wd) f Upon simplification, y(t) = 20 + 4) () 2) = emult) A(t) = cos(tu(t) * s(t ARON = ii * en(e-My(t — A) cos(A)u(A)dA we“! feos() + sin(a) (€) 2) = eFul) (0) = costt) w= [ se ayncayar = f° en Salt — a) cos(Alu(A)eA = [costae ut) =e = 0.5{cos{t) +sin(¢]] 2-00 (all time) (e) a(t) = 2t{et +2) w(t —2)] lt) = u(t) — u(t 4) w= [~ Split this into 4 integrals and simplify the limits om each a(a)R(¢ — 9)2 = £ DAfu(A+ 2) — u(A~2)jfult — a) — ult —4—al}an™ ut) = if aau(a+2)u(e —a)aa if * axu(A + 2)u(t 4 —a)ad - fe 2du(A — 2)ule—ayda+ £ 2au(A~ 2)ult—4— add ‘ ine : ‘ Hone fi rar-2 frar—2 firarsa [aan Ls ln I, > aa ‘The range of the first integral is ¢ > ~2, of the 2nd and Srd is t > 2 and of the dth is t > 6. So, ‘we cannot just add the results. Using appropriate step functions with each result, we get v(t) = (€? — A)u(t + 2) ~ (2e? — 8¢ + S)ult — 2) + (? ~ 8¢ + 12)ult 6) 04 Chapter 6 Continuous Convolution (8) 2(0) = 2tu(e) ACE) = reet(t/2) = u(t +3) — u(t) WO - 2(A)K(E~ A) = ic 2au(A)fu(t +1 =A) —ult —1 = A)}d u(t) = Ee ‘The range of the Ist integral is t > —1 and of the 2nd is # > 1. Upon integration and using appropriate step functions, u(t) = (4 Put 41) - @—1a(t 1) (6) 2(0) =) = Hult), 4G) = (/8)u(¢ 1) [i xt- ane ifs (adult eA =D ay fln(t) — tm(a) ~ (¢ — 1)Ju(t - 1) = [ein(t) —# + Yule — 1) arutayue-t raya [” 2au(adu(t— anes faa [oa Leo b ut) So, y(t) 6.4 (Solution) Refer to the sketches shown. Convolution with an impulse replicates a signal. If the impulse is shifted, so is the convolution. Use these facts and superposition to sketch the results. Coaveltion Convolution? (0) ote) 6.5 (Solution) 1. Signal endpoints: [-2,2], [-1,3] Pairwise sum: [~3,1,5] Range: -Batcl Range: Lacs, v0) 1b) and 4 xt-2) gay fend CA) a i 4 ' 2 7 [ l 2 Cl 2 t wot ws er sae Zz 7 5 Since the signals ere piecewise constant, the convolution is linear and peaks at t = 1. From the figure, y(1) = 32. At the end-points, the convolution is zero. Thus, y(—3) = 0 = y(6) More formally, we compute the convolution by ranges. [ gaa =stt+3) Renge:-3 S(t—k)srect(t) — (b) > S(t — 3k) xtri(t) — (c) iS rect(t — 2k) + rect(t) ee roms 1Sot0 plies A ANS 102 Chapter 6 Continuous Convolution 6.22 (Solution) The step response s(t) is the running integral of the impulse response A(t). A(t) = rect(t - 0.5) = u(t) ~ u(t —1). So, s(t) =r(¢) - r(t = 1) (b) A(t) = sin(2at)u(t). So, s(t) = [ sin(2rA)@\ = 21 ~ cos(21)ju(t) (0 Ho a lnereat-05] satiny, Saat) { BBO) 542 (a) he) =e“, So, s(t) if eciMdA, Evaluate seperately for t <0 and t > 0: t 0: ts0 yijeos fete Meraaosew? [) oranie 10 eos f PNA A = Jet? 6.25 (Solution) Refer to the sketch. The step response is s(t) = (t). So, h(t) = s'(t) = 6"). IE the input is 2(), the output is yt) = AG) #20) = (2) #202) = 2"), ut a [Ra 1 aap te 6.26 (Solution) Refer to the sketches below. The impulse response is h(t) = u(t) ~u(t 1) whose periodic extension gives the desired periodic convolution (remember to ete the normalizing factor of 2) ‘The repens ofthis sytem to 2(2) = rect — 0.5) is simply y(t) = tilt =) Bult) x2e“Mu(t) = Bte“*u(t) o [olan cent) f : u(t). For r= 0.5, v(t) H(0) = e-tu(t) emul) = [ Beta en 9. ts0 yft)= aia en? gd = eH fe & 120 y= af EMA GY = 056° Forr = 1, A(t) = eu Eveluate separately for t < 0 and t > 0: iso =f tana [aed #200 vt)= ie ete ga = deo s-2tl = e-y(t) + e%u(~t). So, superpose the results of parts (a) and (b). Fort = 05, h(t) = 2e-Mu(t). Evalucte separately for t $0 and # > O: = 0.52% © 2) 104 Chapter 6_ Continuous Convolution 6.28 (Solution) (2) uf@) = eM ee“ = [etu(—z) + e*u()] « tut) + eFu(0} With e-fu(t)xe~fu(t) =te~*u(t) and etu(—t)«e~‘u(t) =0.5e~!!, and using the folding property, u(t) = —tetu(—t) + te-fu(#) + ev! (b) y(t) = [etu(—t) — e“*u(t)] * [etu(—t) — e~fu(t)]. From the results of part (a), y(t) = —tetu(—t) + te~*u(t) — el (c) fetu(—t) ~ etu(t)] « [e~fu(t) ~ etu(—t)]. From the results of part (a), uli) = tetu(—t) ~ tertu(t) + ent 6.29 (Solution) The impulse response of the RC circuit, with r = 1, is A(t) = e~*u(t). We use convolution by ranges. Refer to the sketches below. nora) — eran.nc-n) [ amnion napa [= He OHHH e avy x oy 2 Wea a LM 2 Per a fe eT Te ‘Range: Octel_—Rangetot | | Range:Octel Range’ | | Range:Ocrel Range! oI . w » © at’. eat? 0) (a) Hi) = 0S) al eds wl, Be pte ss By) Range:0S¢S1 1 = [ra Range:1 St < 00 Ue) = fl genta wert ‘The maximum value of y(¢) oceurs at t = 1, with y(1) = 1-7? = 0.6321 (b) 2=(t) = trect(t-0.5) Signal endpoints: [0, ce), [0,1), pairwise sum: (0,1, 0) Ranges0StS1 y(t) = [ de Odd tL tent a Range: 1$t salt) = 2etu(t) x S(t) — ev*u(t) = 2etu(e) — 2tetult) — Hf) = H(t) u(t) = 2temHu(t) = e-™ (b) z(t) = 2etult) —+ vat) = 2etult) » tule) = 2tem*u(t) — ylt) = wilt) «6(t) —ertult) = 2te™ u(t) — Pe Outputs are identical because both systems are LTT. 6.34 (Solution) hy(t) = s(t) — e~*u(t) and ho(t) = e~'u(t). (2) p(t) = hu(t) + halt) = 6(t) — e-fu(e) + e-tult) = 5(t) (b) Aaa(t) = [5(t) — e-fu(t)] x etal) = em tu(t) - tertu(t) 2 (©) hanlt) = e*ult) + [8(@) ~ e-tu(e)] = etu(t) — te-tu(t) (4) We find hrz(t) = hax(t) because both systems are LTT. (e) The parsllel connection of Ay(t) and hya(¢) must equal 6(t) So, hr(t) = 6{t) ~ his(t) = é(t) —e~*tu(t) + te-tu(t). -—-—_eo—oooo 6.85 (Solution) For system 1, v(t) = 2'(?)+2(¢). So, hilt) = 6'(t) + 6(0), For system 2, ha(t) = e~tu(s) (a) u(t) = 2erFule) «[6(t) + 4(6)} x emtu(e) = 2e-*u(t) (b) ult) = 6(¢) +6) + 600] xe*uly) = 5(0) (©) One system is the inverse of the other because fy(t) « ha(t) = d(¢) —e—_—_—_—_—_—_—_—_—_—_—________ 106 Chapter § Continous Convolution 6.36 (Solution) Refer to the circuits shown. sean eee eae a sO Dayo 8 aR yO Creal Great (a) For the first circuit, hy(t) = s4(t} = For the second circuit, a(t) = 36(¢) For the third cireuit, simplify to an RL cirenit (as shown) with Ry = R/(3R+1). Thea, ha(t) = (1/r)ent/"u(t) = Rye~**tu(t) where + = L/Ry = 1/Ry Then, hs(t) = Gha(t) = ¥Rie-* u(t) (b) For the ideal cascade, haa(t) = Aa(t) #ha(t) = e-*u(t) + 24(t) = Feru() This does not equal /is(t) for the physical cascade because an ideal cascade assumes an infinite input impedance for the second system. If not, we have an impedance mismatch which causes loading. This can be avoided by using high input impedance, low output impedance, isolating or buffer amplifiers between the two systems. u(t) (©) At t= 0,hi2(0) = 3 and hy(0) = 3R:. For the condition given, 2R1 = (0.99)3 or R ‘The larger the value of R, the less the difference between a(0) and hs(0). 6.37 (Solution) (a) Ait] =e"@+9u(t) Causal and stable (b) Ale) = e-4u(t-+ 1) Noncausal and stable (c) A(t) = 6(t)—e-tu(t) Causal and stable (a) A(t) =6(t}—e'u(-1—z) Nonceusal and stable 6.38 (Solution) Let hp(t) be the impulse response of the parallel combination and ho(t) be the,cascaded impulse response. (@) f(t) = emule), ho(t) = 6(e) Ap is causal, stable; hic is causal, stable (b) halt) =e-tu(¢ ~3), halt) =4(¢#2) Ap is noncausel, stable; Ac Is causal, stable (©) halt) = e~*ule), hale) (4) ha(t) = e~*u(t), Aa(t) = etu(—t) hp is noncausal, stable; he is noncausal, stable (2) aif) =e, Aa(t) = eo (f) Aa(t) sel", halt) = (@) u(t) =e, haf “t7u(t—1) hp is causal, stable; hc is causal, stable Up is noncausal, stable; fc is noncausal, stable It! hp is noncausal, unstable; fig does not exist HK hp is noncousal, unstable; he does not exist Chapter § Solutions to Problems 107. 6.39 (Solution) (a) v(t) =2(¢) unstable because h(t) = H(t), A(t) = u(t) and J |h(@)|at = co. (b) y(t) +ay(t) = z(t) stable for a> 0 because h(t) = Ke-**u(t) and f A(t)idt = K/a. (©) !%(e) = 2(¢) unstable for n 21, since A(t) will be a step (J 6(¢)) for m= 1 or a polynomial for n> 1, and thus f {A(E)|dt = oo. (4) v(t) = 2")(t) unstable for any n > 1, since A(t) will be ’(t) for n = 1 or 6!(4) for 2.2 1. These derivatives of the impulse are not absolutely integrable. Alternatively, a step input (bounded) will yield impulses (n = 1) or their derivatives (n > 1), which are unbounded (at ). 6.40 (Solution) (a) z(t) = a(t) - ule). (2) Ax(8) = 26(8) a(t) = 2) + 26(¢) = 2e(6) = 2fult) — ule] (2) halt) = s(t) + 40-3) volt) = (ule) ~ ule] + ful ~ 3) — ut ~ 4) (8) halt) = erFu(e) volt) = ental) ~ (eM ult 1) (b) The statement applies only to instantaneous systems. (c) System 1 is instantaneous. Its system equation y(t) = 2z(t). System 2 is dynamic because u(t) = a(t) ~a(¢ ~ 3) the arguments of the input and output do not match ¢ ~ 3. System 3 is Gynamic and deseribed by the dilferential equation y(t) + y(¢) = =(t) (A) For an instantaneous system, h(t) must have the form K6(t) (and not K6(t a), for example). 6.41 (Solution) {a) rect(t) «tri(t) Convolution is smoother and Jonger in duration (b) rect(t) *(¢) Convolution has same duration and form as rect(t). (©) rect(t) x(t) Convotation is derivative of rect{t) and less smooth! (4) sinc(#) * sine(t) Convolution equals sinc(t) and shows no smoothing. y(t) = e~7® * e~** Convolution has the same (Gaussian) form but is more stretched out. (e) sin(2rt)+rect(t) Convolution is zero. As we slide the folded rect pulse, the product over one unit (the period of the sine) integrates to zero, 6.42 (Solution) (a) =(¢) = cost), uit) = }sin(t — 4x) ‘This deseribes a linear system; the responce is at the Input frequency. (b) 2(t) = cos(!), y(t) = cos(2t) This is a nonlinear system; the response is not at the input frequency. 108 Chapter 6 Continuous Convolution 6.43 (Solution) (a) True. 2(t) + 6(t) = Ax(t). (b) True, Example: oie-fu(t) = is PetnO gy = ich as that described by the topulse response A(t) = e~#*u(t). Mg = eae = Kel is an ig eigensigual of any LTT system (0) Not true, IF2(¢) = cos(at) and v/(t) + Ay(t) = a(t), then y(t) = Acos(¢) +B sin(t) = Ccos(t+8) Only in special cases will 4 (or 8) equal zero. (A) True. Examples sine(t)xsinc(t) = sine(t) _sine(t) + sine(24) = 0.5sino(t) 6.44 (Solution) (a) No___(b) Yes__(c)No__(d) No 6.45 (Solution) For stability, {Jh(#lat must be finite. For causality, A(t) = 0, t <0 (a) A(@) =u(t) Unstable, causal y(t) Stable, causal (¢—1) Stable, causal (d) A(z) = rect(t) Stable, noncausal (e) A(é) =sinc(t) Unstable (sine is not absolutely integrable), noncausal (8) A(t) =sine?(t) Stable(fsinc®(t)at = 1), noncausal 6.46 (Solution) (a) A(t) = e-*u(t) Invertible. Describes y/(d) + 2u(t) = a(t). So, inverse system is y(t) = 2"(t) + 2a(t) and hy(t) = 6'(t) + 25(¢) (b) A(Q) = 5{t~1) Invertible, averse system is y(t—1) = 2(t) or y(t) = 2(t4+1) and hi(t) = (t+2) (c) A(t) = sinc(t) Not invertible. Diferent Inputs can produce identical outputs. For example, sinc(t) « sinc{t) = sinc(¢) and sino(t) + 2eine(2t) = sinc(#) 6.47 (Solution) (@) at) =eUrut) aalt) Ket Ostet a 2 f[ e-*Vd4(0,00) f Ke“ldt = Kr(1— eT") SoraKr(l-eM) Ke pdee (b) aft) =te-Vult) apt) (AFB Ost T = r [ te! at =? f[ (Att B)enW dt = Ar(1— eT) — Are + Bra — 7/7) 5 lo Equating the two results and comparing the coefficients of 7 and 72, we have Ae )s1 | Bde T)~ eT m0 This gives A= Chapter 6 Solutions to Problems 6.48 (Solution) Refer tothe folowing sketches, o| : | ead : : £ j ne ne ae 209 (@) (4) ut) x sin(ne)[u(e) — u(t — 2)]._ As we fold and slide the sine pulse, the convolution after 2 Units is the area under the sine pulse and equals 0. So the convolution duration is 2 units. (2) rect(t}«cos(2zt)u(t). As we fold and slide the rectangular pulse, the convolution after 1 unit, is the area under cos(2nt) over one unit and equals 0. So the convolution duration is 1 unit, (b) After Ty units, the convolution equals the area under 2(t) = 0 (©) After 1 unit, the convolution equals the area under 2( 6.49 (Solution) Use the ares property of convolution. (a) (at) *5(at) = Ad(at). The area of 6(at) is 1/la]. 1ypty_A 1 So, (@G a'4"ta {b) sinc(at) « sine(at) = Asinc(at). The area of sine(at) is 1/la. lyfly_ A 1 So, (a)Ga) “atta (©) ot? er™ So, (1}(1) AeW*#/2, The area of e~** is 1. The area of e~*®/? is V3. VE or A =1/v2. 1 1 A 1 @ patie ise Tee! +8 1 is and the aren of py is 2 So, (7)(=) = 2A or A= 0.57. 6.50 (Solution) (2) 2(t) = A(t) = rect(t) 1p ap role) = molt) = [7 dt=a,m(a)=m(h)= f eae=0 WA peer sma(2) = m2(8) = f co B mbe=nlt)= et 3 Now y(t) = x(t) + h(t) = tri(t). Since y(t) is even, we compute 1: mati)= f idae=1—mtn= f exey=0 fe =} = motu) _ mtv) 2 ma) f euiee= 5 nt) = MF atu) _ mals) mala) _ ‘We find ma(y) = mo(z)ma(h) mo(y) — mo(z) ~ mo(h) 0 waly) = wa(z) + walh) = 3 10 Chapter 6 Continuous Convolution uth ate) = oul) etdt=1 — m(z)= mms) = ["Petat= 2 pa(e) = 22 - a = malt) = [Weta=05 min) = [eta =02s matt) = [Pe *t=025 p(t) = 2-2 = oa ma) = [ete e=05 miy)= pe fre =e at = 0.75 mat) = [ete *)dh= 1.75 u(t) = BE a ae solv) = mote)ma(h) =05 BAC) .. mule) ml Tol Fat ale) ay ES aly) = a(t) + wa(h) = 1.25 6.51 (Solution) @) hat) = 2S) (y= =P ‘The maximum value of ha(t) occurs when hy (t) = 0 or when (nu — ten) (b) galt) = Keren? fe Thus, gn(n) = K = (n°fnlje® (t= n) aoe bela © Kem [Se] (d) From the aree property, {f° hn(t)dt = 1. The area of gq(t) must also equal unity. Since shifting oes not change areas, we use fee ee ce Kev dt = 2K | edt = Kynja= al a ee anat a 6.52 (Solution) Refer to the following sketches, 0 no | ry £ L t 1 25s Tec Signal Marched ier Inpoe Oupat (a) Since s(t) = u(t) ~ u(t ~ 1), the impulse response of the matched filter is A(t) = s(—t). (b) The response y(t) is y(t) = 2(¢) + A(t) = tr(t — 2). (©) The response y(t) is maximum at ¢ = tm = 2's. This also corresponds to the time d by which the signal s(¢) is delayed to obtain z(t). x0 se) Chapter 6 Solutions to Problems peer 6.53 (Solution) An autocorrelation function must be & non-negative, even symmetric function with a maximum at the origin u(t) Canpot be an autocorrelation function (not even symmetric). sl Can be an autocorrelation function Cannot be an autocorrelation function (not even symmetric). Cannot be an autocorrelation function (not maximum at origin) Can be an autocorrelation function Con be an autocorrelation function i TEP Cannot be an autocorrelation function (not even syrametri). 158 Can be an autocorrelation function “ae 1 i : () rax(t) = FEF Cannot be an autocorrelation function (not non-negative) 6.84 (Solution (#) and mje Sn teu(—t) Hi 4-te“tu(®) ~ te'u(—t) (Prob 6.28a) Du(t) + etu(—t) = 0.52 (4) ran(t) =e and rae(t) = ren(—t) COMPUTATION AND DESIGN 6.55 (Solution) Use ctcongui to animate the convolution. The result shown is the partial convolution, for part (4). 12 Chapter 6 Continuous Convolution 6.56 (Solution) Use ctcongui to animate the convolution, Chapter 7 DISCRETE CONVOLUTION Tat (Solution) Refer tothe sktehes, Note chet of] = 2[3 ~H] va and fk = 2+) vs fel thl= 3, 4} @)aml= 5, 3,2, 2.2) fi. ac Pes a i Hin fill, = Wit 7.2 (Solution) (a) ofp] = afr] vin] = =ntlyn>0or(n+I)uln] (®) zn] = } Alm] = (0.4)"uln] vin] = = (0.8)*u[h](0.4)" “Ful — &] = Resrog = (04 oot tam Es = 5, yin) = (04 SO =(0.4)"2"" — aIufn) (©) fn] = (0.5)"¥fn) | = 05)"(ufn +3) — uf ~ 4} sel = SS tn Hate 9) $0, yn} = 0 (¢) zir] =(@)"u[n}_—_ ln) = (@)" un] vin) = 5 bultja™tuln —K) = Shakar = 2)" Sot = (9+ De)" aia} & is =o" S1-ery a=) i (0.5)"(n + 4)ufn +3] — (0.5)%(n ~ 3)ufn — 4} (©) z[n] = (@)"uln} yin} = (6)" ln) 113 14 Chapter 7_Discrete Convolution (Bley _ gett qntt Gia) * Baa tl #0) vb ~ Sete (3). (£) zn] =(@)"ufn] fn] = rect{n/2N] = uln +N} — ula —N ~1) oe Start with (a)"ufn] « uf fn) Toa = 7.8 (Solution) () ab)=¢h.2.02) ain) = 62,3} Both z{n] and Afn] start at n = 0, so yln] starts at n = 0 Indexn 0.12 3-4/5 = T A 2 2 7 2 3 rae z (b) fn) = (6,2,4,6} ln) = (6,4,2,0} Both 2fni] and hin] start at n = 0, s0 yf] starts at n= 0 Indexn 0 2 2 3 4 5 z 0 2 4 6 Ao 4 2 0 2 is 0 8 16 24 - o 4 8 2 02s 2 12 (©) ain) = (-3,-2,1,0,1), Afr] = (2.3.2) _{n) starts at n= ~2, h(n] starts at n = 0, so yfn) starts at n = -2 Indexn 2 1 0 1 23 4 32 ia 4.302 2-8 oF 8 63 03 6-4 20 2 232 Ghepter 7_Sotutions to Problems us ‘ : (@) ln} = {3,2,1,1, 2}, Aln] = {4,2,3,2} a(n) starts at m = ~2,h[n) starts at n= —1, so yfn) starts at n= Indexn 9 2 1 0 1234 ape Siero iceaaeeee A423 2 rr ar 6 42 24 96 336 64224 you iw 9 84 (©) afr] = £8,0,2,0,4,0,1,0,2}, Ale] = (4,0,2,0,3,0,2} afr] starts at r= 4, hfn] starts at n = —2, so yin] starts at n = —6. Both z[n] and h(n] are zero interpolated versions of part(d), 50 4 fr} = {22,0,14,0,17,0,18,0,17,0,9,0,8,0,4} (6) 2{n) = (6,0,0,3, 1,2}, hfe] = (4,3,8, 2) [nl] starts at n = 3 (ignore leading zeros) hn] starts at n= —1, so yf] starts at Index a2 567 24 z A_3 TZ e 32 464 y 2 0 Bs As a sequence, y[n] = {0,0,12,10,19,13,8,4} {3,4,2,2}. (@) vin] = ain) x Afn] = G, 24, 28, 22, 12, 4, 1) 7-4 (Solution) z{n] = hfn) {1, 4, 12, 22, 28, 24, 8) (folding property) (b) ain} n] + h[—n] (©) pin] = 2{n) + Al-n] = (3, 10, 22, 30, 22, 10, 3) (2) Sin) = {3, 10, 22, 30, 22, 10, 3} (folding property) () (f) sfx) =zfr 1] +Aln +4] =yfn +3] == (9, 24, 28, 2, 12, 4, 2} nl x hl = zip lehin + I= vir] = (8, 24, 28, 22, 12, 4, 1} us Chapter 7_Discrete Convolution 75 (Solution) z{n] = hfn] = (2,6, 0,4). (a) ula} = z/2n) x Al2n) = (2, 0} (3, 0} = (4, 0, 0} (b) ofp) = 2{n/2] +:Ajn/2]. Now, z[n/2| = fn] = (3,0, 6,0,0,0,4,0} (zero interpolation). So, z[n/2}« hfn/2] = {4,0,24,0,36,0, 16,0, 48,0, 0,0, 16,0,0,0} font Now, z[n/2] = (3,2,6,6,0,0,4,4} (step interpolation) So, z{n/2}+ hin] = >{n/2] x hl] 16,24, 56, 44,24, 32, 32,24, 16,16} (A) r{n} = z[n] *Afn/2]. Now, Afn/2)= {2,4,6,3,0,2, 4,2} (linear interpolation) So, z{n] +Afn/2] = (4,20, 36,50, 34,28, 32,28, 20, 16,8} 7.6 (Solution) (a) The difference equation is yln) = H=(n] +2{n—1]}. (b) Phe impulse response is Aln] = }{6[n] + d[n —1]} or fn] (c) The response of this eystem to {1,2,3, 4,5} is 2a Indxn 0 1284S iat ota sramaceeas h_05 05 05 10 18 20 35 05 10 15 20 25 y 05 19 25 35 45 25 (2) The system does perform the required averaging operation. The first and last samples of a(n) are averaged with zero. ‘7.7 (Solution) (a) Alo} = (2)*ufn — 1]. Causel but unstable (Sl2"ufn— 1] =2+ 448+... is 00) (b) ula} = 2zjn + 1] + 3efn] —2[n— 1], Noneausal but stable Af] = {2.3.1}, ElAln|| <6 (©) Ala} = (~0.5)"ufn], Causal and stable (I Afal| =1epHd+d+....=2) (4) ln] = {3,2,1,1,2}. Noncausal, but stable (S> A[n]| = 9) (©) (£) Aln] = (0.5)!*!. Noncausal and stable (two-sided decaying exponential), (0.5)-"ul-n}. Noncausal and stable (folded version of (0.5)*u(n]).. Chapter 7_ Solutions to Problems uz 7.8 (Solution) We use wrap-around to find the periodic convolution in each case. (@) 2h) =(1,2,0.1} Ain] = (8,2,3,0} + hin} = (2,6,7,8,2,3,0} {2,6,7,8} +2,3,0,0= {4,9,7,8} (WW =4) T. So, the inimum number of padded zeros is 7 — Regular convolution yin} Periodic convolution = ph Now, Nz =, =4.and N, air] = (6,2,4,6) fo} = {8,4,2,0} Regular convolution yln] = {n) + hin] = {0,12,32,56, 32,12, 0} Periodic convolution ysln] = {0, 12,32, 58} + (32, 12,0,0} = (82, 24,32, 55} (V = 4) Now, Ne = Ny =4 and Ny =7. So, the minimum number of padded reros is 7— 4 = 8 gz (©) ata} ={-3,-2,1,0,2) inl = (8,3,2,0,0) 12,17, -16,-7,2,3,2,0,0} Regular convolution yf] = Periodic conv: yn} = {—12,~17,16,~7,2} + {8,2,0,0,0) = {—9,—15,—16,-7,2) oes Now, Nz =, =5 and N, = 9. So, the minimum number of padded zeros £3,24,1,2) Mn] = {4.3,3,2,0} 4 Regular convolution y[n} = (12, 14,17, 18,17, 9,8,4,0} (@) a a Periodic convolution = ypfn] = {12,14,17,18,17} + {9,8,4,0,0} = {21,22,21,18,17} (N= 5) Now, Ne= Nh = 6 and Ny =9. So, the minimum mumber of padded zeros is 9 — 5 VS __. 7.9 (Solution) 2] [2424040] [4 s 2}_| 4424340) _]9 3|~|osassz0] 7] 7 4] [2toseso] [8 As a sequence, yp{n} = {4,9,7, 8} 8,2,4,6) Ale) = 6.4.20) 3e cireulent matrix for z[n}, we find 06 42)/6] faz 2064//4]_] a 4206/12] 7| a - 642o0}lo} [86 {32,24,92,56} 18 Chapter 7_Diserete Convelution = (8,3,9,12,15, 18). {n] —+ [Zero-Interpolate by N] —+ [Filter] — y{n] 7.10 (Solution) = (a) tir} = (4,1). with =2, zfn/2] = (5,0,3,0,9,0, 12,0,15,0, 28,0}. So, yjn| = 2{n/2] «Afn} = (8,0, 3,3, 9, 9, 22,12, 15, 15,18, 18,0}. Except for end effects, the output describes a step interpolation between the samples of zn). (b) Af) = lian). with wv =3, ain/3] = 8,0,0,3,0,0, So, yln] = 2{n/3] + hf] = {8,0,0,3,3, 3,9, 9,9, 22, 12, 12,15, 18,15, 18, 18,18, 0,0} Except for end effects, the output describes a step interpolation between the samples of z{n] 0,0, 12,0,0,25,0,0,28,0,0} (c) For step interpolation by 4, we require N = 4 and fn] = (4,1,1,1) {0,3,9,12,15,18). 2{n} — [Zero-Interpolate by N] —+ [Filter] — yf 711 (Solution) zh (a) Aln} = tri(n/2) = {0,0.5,4,0.5,0}. With N= 2, z[n/2| = (8,0,3,0,9,0, 12,0,15,0, 18,0}. So, yf] = z{n/2}« hin} = {0,0,8, 1.5,8,6,9, 20.5, 12, 18.5, 15, 16.5,18,9,0,0). Except for end effects, the output describes a step interpolation between the samples of z[n}. (b) Al] = (0,43,4,3, 4.0), with 2 =, 2[n/3] = {8,0,0,3,0,0,9,0,0,12,0,0, 15,0, 0,18,0,0) So, yfa] = z{n/3]« Afr] = {0,0,0,0,1,2,3,5, 7,9, 10, 11, 12,13, 14,15, 16, 17,18, 12, 6,0,0,0}. Except for end effects, the output describes a step interpolation between the samples of z{n]. (c) For linesr interpolation by 4, we require N = 4 and Aln] = tri(n/4) 7.12 (Solution) (a) 2{n] = (2,2,0,1}, Afn] = B,2,3) = €1,2,0,2} + (2,0,2,5} = 1,2,2,8,2,2,} 6, 10,17, 10,6} «© renlel = 2{n] x Af—n} = {3,8,8,7,2,2) ‘© raeln) = 2{—n) « Afn] = real—n] = (22,7883) 8 reel] = 2p] *l- rn] + Bn] + raaln] (b) fn) = (6,2,4,6}, bln) = 6,4,2} & x2[—n] = (0, 12,32,$6,32, 12, 0}

You might also like