From follett at ece.msstate.edu Mon Apr 2 08:08:07 2007 From: follett at ece.msstate.edu (Randolph F. Follett) Date: Mon Apr 2 08:08:46 2007 Subject: [ece4923] Classes for April 2, 2007 Message-ID: <20070402130841.WFWI23400.ibm57aec.bellsouth.net@eagle.ece.msstate.edu> Due to illness, I will not make it to either of my classes today. I am hopeful that I will be back to work tomorrow, at which time I'll try to let you know about any plan to make up the material for today. Randy Follett ----------------------------------------------------------------------------------------- Randolph F. Follett, Ph.D., P.E. Assistant Professor Department of Electrical and Computer Engineering Mississippi State University Box 9571 Office: 662-325-3073 Mississippi State, MS 39762-9571 FAX: 662-325-2298 e-mail: follett@ece.msstate.edu ------------------------------------------------------------------------------------------ From follett at ece.msstate.edu Thu Apr 19 15:04:19 2007 From: follett at ece.msstate.edu (Randolph F. Follett) Date: Thu Apr 19 15:04:21 2007 Subject: [ece4923] ECE 4923/6923 - Quiz 3 Scheduling Message-ID: <20070419200419.C32CE52C72F@zimbra.ece.msstate.edu> As discussed in class yesterday, I have suggested that we do the third quiz in an outside-of-class situation. I would make the test exactly the same as it would be for an in-class quiz, but would allow you additional time. A suggested time and date is next Tuesday at 6:00 p.m. In order for this to work, I need two things from each person in the class: 1. Agreement to do the quiz outside of class. 2. Either agreement with the suggested time, or a different suggestion based on not being available Tuesday at 6 p.m. If everyone would respond as soon as you get this, we could probably get things arranged before class tomorrow, and I could announce the specifics. Thanks, Randy Follett ----------------------------------------------------------------------------------------- Randolph F. Follett, Ph.D., P.E. Assistant Professor Department of Electrical and Computer Engineering Mississippi State University Box 9571 Office: 662-325-3073 Mississippi State, MS 39762-9571 FAX: 662-325-2298 e-mail: follett@ece.msstate.edu ------------------------------------------------------------------------------------------ From follett at ece.msstate.edu Sun Apr 22 23:04:26 2007 From: follett at ece.msstate.edu (Randolph F. Follett) Date: Sun Apr 22 23:04:41 2007 Subject: [ece4923] ECE 4923/6923 - Problem Session Problem Message-ID: <20070423040428.YXUF2148.ibm69aec.bellsouth.net@eagle.ece.msstate.edu> Unfortunately, I was out of town this afternoon, and completely forgot the fact that I had agreed to do a problem session at 2:00 p.m. As a result, we'll try to set something up for tomorrow afternoon or evening to try and address any questions. I sincerely apologize for missing this. We will talk more about this in class in the morning. Randy Follett ----------------------------------------------------------------------------------------- Randolph F. Follett, Ph.D., P.E. Assistant Professor Department of Electrical and Computer Engineering Mississippi State University Box 9571 Office: 662-325-3073 Mississippi State, MS 39762-9571 FAX: 662-325-2298 e-mail: follett@ece.msstate.edu ------------------------------------------------------------------------------------------ From follett at ece.msstate.edu Mon Apr 23 14:42:14 2007 From: follett at ece.msstate.edu (Randolph F. Follett) Date: Mon Apr 23 14:42:19 2007 Subject: [ece4923] ECE 4923/6923 - Typo in book on Problem 13.10 Message-ID: <20070423194215.9983552C72B@zimbra.ece.msstate.edu> Please note that Problem 13.10 says to use the system in Figure 13.1, when it actually should say that you are to use the system of Figure P13.1. That way, the results of Problem 13.2 are available for comparison to the results obtained by use of the Nyquist plot. Randy Follett ----------------------------------------------------------------------------------------- Randolph F. Follett, Ph.D., P.E. Assistant Professor Department of Electrical and Computer Engineering Mississippi State University Box 9571 Office: 662-325-3073 Mississippi State, MS 39762-9571 FAX: 662-325-2298 e-mail: follett@ece.msstate.edu ------------------------------------------------------------------------------------------ From follett at ece.msstate.edu Mon Apr 23 18:50:02 2007 From: follett at ece.msstate.edu (Randolph F. Follett) Date: Mon Apr 23 18:50:09 2007 Subject: [ece4923] ECE 4923/6923 - Frequency Response Calculations Message-ID: <20070423235003.67AA352C723@zimbra.ece.msstate.edu> As discussed in the problem session earlier, I am sending this code out to you for use in calculating sampled-data frequency responses. At present, it only works with z-domain transfer functions. (My *-domain code is not working yet, but I only had about 30 or 45 minutes to put into it this afternoon.) If I get the *-domain part working, I will also send it out to you. By the way, it follows the handout that I gave you in class, in which calculations for various sampled-data frequency responses were described. (Although I didn't actually implement Horner's method directly, I believe that MATLAB might actually use such a technique for doing the polyval function.) Randy Follett P.S. If you have questions about the code, let me know. Also, if you have questions about any other problems, you can e-mail me, and I will try to respond to you, or set up a time when we can talk face to face about it. ----------------------------------------------------------------------------------------- Randolph F. Follett, Ph.D., P.E. Assistant Professor Department of Electrical and Computer Engineering Mississippi State University Box 9571 Office: 662-325-3073 Mississippi State, MS 39762-9571 FAX: 662-325-2298 e-mail: follett@ece.msstate.edu ------------------------------------------------------------------------------------------ -------------- next part -------------- % sdfreq.m % sampled-data frequency response calculations % % For now, the only one included is the z-domain routine % % For more flexibility, you should add in the *-domain % calculations. % disp('Enter the z-domain transfer function in MATLAB vector format:') num=input('numerator=? '); den=input('denominator=? '); T=input('sampling period=? '); N=input('number of frequencies to be calculated=? ') omegalow=input('lowest frequency point=? '); omegahigh=pi/T; omega=omegalow; multiplier=(omegahigh/omegalow)^(1/(N-1)); numtemp=0;dentemp=0; disp(' Frequency Magnitude(dB) Magnitude Phase(deg)') for k = 1:N ejwt=exp(j*omega*T); numtemp=polyval(num,ejwt); dentemp=polyval(den,ejwt); mag=abs(numtemp/dentemp); phase=angle(numtemp/dentemp)*180.0/pi; disp([omega 20*log10(mag) mag phase]) omega=omega*multiplier; end From follett at ece.msstate.edu Tue Apr 24 16:52:02 2007 From: follett at ece.msstate.edu (Randolph F. Follett) Date: Tue Apr 24 17:40:51 2007 Subject: [ece4923] ECE 4923/6923 - Sampled-Data Frequency Response code Message-ID: <20070424224047.EA0E652C737@zimbra.ece.msstate.edu> Here is the updated frequency response code (in MATLAB). It now computes either the z-domain response or the *-domain response. For the convergence factor, a "small" number, like the suggested 1e-8, is usually fine. If you run into convergence issues, you might want to back off to about 1e-5. I am fairly certain that everything is working correctly at this point, but if you run into an inconsistency, please let me know. Randy Follett ----------------------------------------------------------------------------------------- Randolph F. Follett, Ph.D., P.E. Assistant Professor Department of Electrical and Computer Engineering Mississippi State University Box 9571 Office: 662-325-3073 Mississippi State, MS 39762-9571 FAX: 662-325-2298 e-mail: follett@ece.msstate.edu ------------------------------------------------------------------------------------------ -------------- next part -------------- % sdfreq.m % sampled-data frequency response calculations % You can use the z-domain or the *-domain set of calculations. % For yes/no questions, type either Y or y for yes, and N or n for no. % disp('This routine will calculate a frequency response for a sampled data system.') disp(' ') domain=input('Would you like to use the z-domain or the *-domain? (z or *)','s'); if domain=='z', disp('Enter the z-domain transfer function in MATLAB vector format:') num=input('numerator=? '); den=input('denominator=? '); T=input('sampling period=? '); N=input('number of frequencies to be calculated=? ') omegalow=input('lowest frequency point=? '); omegahigh=pi/T; omega=omegalow; multiplier=(omegahigh/omegalow)^(1/(N-1)); numtemp=0;dentemp=0; disp(' Frequency Magnitude(dB) Magnitude Phase(deg)') for k = 1:N ejwt=exp(j*omega*T); numtemp=polyval(num,ejwt); dentemp=polyval(den,ejwt); mag=abs(numtemp/dentemp); phase=angle(numtemp/dentemp)*180.0/pi; disp([omega 20*log10(mag) mag phase]) omega=omega*multiplier; end elseif domain=='*' delta=input('Enter delta, the accuracy requirement for the series calculations. (e.g., 1e-8) '); disp('Enter the s-domain transfer function in MATLAB vector format: ') num=input('numerator=? '); den=input('denominator=? '); T=input('sampling period=? '); value=lower(input('Do you want a ZOH included? ','s')); if value=='y' zoh=1; end N=input('number of frequencies to be calculated=? '); omegalow=input('lowest frequency point=? '); omegahigh=pi/T; omega=omegalow; multiplier=(omegahigh/omegalow)^(1/(N-1)); numtemp=0;dentemp=0; disp(' Frequency Magnitude(dB) Magnitude Phase(deg)') for i=1:N; jw=j*omega; val1=polyval(num,jw); val2=polyval(den,jw); val1=val1/val2; if zoh==1 val1=val1/jw; end gstar=val1; for k=1:1000; jwp=jw+k*2.0*j*omegahigh; jwm=jw-k*2.0*j*omegahigh; val1=polyval(num,jwp); val2=polyval(den,jwp); val3=polyval(num,jwm); val4=polyval(den,jwm); if zoh==1 val1=val1/(jwp*val2)+val3/(jwm*val4); else val1=val1/val2+val3/val4; end gstar=gstar+val1; end gstar=gstar/T; if zoh==1 gstar=gstar*(1.0-exp(-jw*T)); end disp([omega,20*log10(abs(gstar)),abs(gstar),angle(gstar)*180/pi]) omega=omega*multiplier; end end From follett at ece.msstate.edu Thu Apr 26 11:29:39 2007 From: follett at ece.msstate.edu (Randolph F. Follett) Date: Thu Apr 26 11:30:00 2007 Subject: [ece4923] ECE 4923/6923 - Quiz 3 Message-ID: <20070426162954.CVON27044.ibm64aec.bellsouth.net@eagle.ece.msstate.edu> The solution key to the third quiz is now posted on the website. Let me know if you have any trouble accessing it. As mentioned yesterday, I'll be around this afternoon, starting at 2:00, and will be available for questions regarding tomorrow's exam. Randy Follett ----------------------------------------------------------------------------------------- Randolph F. Follett, Ph.D., P.E. Assistant Professor Department of Electrical and Computer Engineering Mississippi State University Box 9571 Office: 662-325-3073 Mississippi State, MS 39762-9571 FAX: 662-325-2298 e-mail: follett@ece.msstate.edu ------------------------------------------------------------------------------------------