Commentary On The DSP First Labs - Massachusetts Institute Of Technology

1y ago
10 Views
2 Downloads
1.49 MB
108 Pages
Last View : 8d ago
Last Download : 3m ago
Upload by : Adele Mcdaniel
Transcription

Commentary on the DSP First Labs,In which is discussed the concerns of such labs as mightbe found in the book of record, in addition tosupplemental work suitable for a college class on thesetopics.Jimmy Rising July 25, 2005This document reflects the labs taught in Signals and Systems at Olin College during Fall 2003 andSpring 2004, under Dr. Diana Dabby. 1

Contents1234Preface1.1Document Format . . .1.1.1Typefaces . .1.2Past Lab Policies . . . .1.2.1Deliverables .1.2.2Collaboration1.3Example Syllabus . . . .1.4Future Work . . . . . . .55666778General Notes2.1The CD . . . . . . . . . . . . . . . . . . . .2.2Book Notation . . . . . . . . . . . . . . . .999.Lab 1: Introduction to Matlab3.1Introduction . . . . . . . . . . .3.1.1Installing DSPFirst .3.1.2Measuring Phases . .3.2Additional Notes . . . . . . . .3.2.1Question Help . . . .3.3Deliverables . . . . . . . . . . .12121212141415Lab 3: Synthesis of Sinusoidal Signals5.1Introduction . . . . . . . . . . . . . . . . . .5.1.1Minimal Music Theory . . . . . .5.1.2Harmonics and Other Improvements5.2Additional Notes . . . . . . . . . . . . . . .5.2.1Student Supplement . . . . . . . .5.2.2Question Help . . . . . . . . . . .5.3Deliverables . . . . . . . . . . . . . . . . . .1515161617171818Lab 4: AM and FM Sinusoidal Signals6.1Introduction . . . . . . . . . . . . . .6.1.1Instantaneous Frequency .6.1.2Reading Spectrograms . .6.2Additional Notes . . . . . . . . . . .6.2.1Section Commentary . . .6.3Deliverables . . . . . . . . . . . . . .19202020212122Lab S: Sampling and Aliasing7.1Introduction . . . . . . . . . . .7.1.1Tone Shifting System7.2Additional Notes . . . . . . . .7.2.1Question Help . . . .7.3Deliverables . . . . . . . . . . .2222232323238Lab C: Convolution Lab8.1Introduction . . . . . . . . . . . . . . . . . .8.2Additional Notes . . . . . . . . . . . . . . .8.3Deliverables . . . . . . . . . . . . . . . . . .242425259Lab 5: FIR Filtering of Sinusoidal Waveforms 259.1Introduction . . . . . . . . . . . . . . . . . . 269.2Deliverables . . . . . . . . . . . . . . . . . . 2767.10 Lab 6: Filtering of Sampled Waveforms: Cascading Systems10.1Introduction . . . . . . . . . . . . . . . . . .10.2Additional Notes . . . . . . . . . . . . . . .10.2.1Question Help . . . . . . . . . . .10.3Deliverables . . . . . . . . . . . . . . . . . .11 Lab 6: Filtering of Sampled Waveforms:tering the Speech Waveform11.1Introduction . . . . . . . . . . . . . . .11.2Additional Notes . . . . . . . . . . . .11.2.1Question Help . . . . . . . .11.3Deliverables . . . . . . . . . . . . . . .13 Lab 7: Everyday SinusoidalAmplitude Modulation13.1 Introduction . . . . . . . .13.2 Additional Notes . . . . .13.3 Deliverables . . . . . . . .9101011111111Lab 2: Introduction to Complex Exponentials4.1Introduction . . . . . . . . . . . . . . . . . .4.1.1Fixing zvect and zcat . . . . . .4.1.2Explaining sumcos . . . . . . . . .4.2Additional Notes . . . . . . . . . . . . . . .4.2.1Student Supplement . . . . . . . .4.3Deliverables . . . . . . . . . . . . . . . . . .512 Lab 7: Everyday Sinusoidal Signals:phone Touch Tone Dialing12.1 Introduction . . . . . . . . . . . . . .12.1.1Detecting Energy . . . . .12.2 Additional Notes . . . . . . . . . . .12.2.1Question Help . . . . . . .12.2.2Section Commentary . . .12.3 Deliverables . . . . . . . . . . . . . .28282828292.29293030303031Signals: Tone. . . . . . . . . . . . . . . . . . . . . . . . . . . .313132323232333315 Lab 9: Sampling and Zooming of Images15.1 Introduction . . . . . . . . . . . . . . . .15.2 Additional Notes . . . . . . . . . . . . .15.2.1Question Help . . . . . . . . .15.3 Deliverables . . . . . . . . . . . . . . . .3636373738ω̂ Domains. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3838383917 Lab 11: Extracting FrequenciesTones17.1 Introduction . . . . . . . . . .17.1.1Question Help . . .17.2 Deliverables . . . . . . . . . .Fil-.14 Lab 8: Filtering and Edge Detection of Images14.1 Introduction . . . . . . . . . . . . . . . . . .14.1.1Mechanics of show img . . . . . .14.1.2Applying Filters to Images . . . .14.1.3Understanding Image FrequencyContent . . . . . . . . . . . . . . .14.2 Additional Notes . . . . . . . . . . . . . . .14.2.1Question Help . . . . . . . . . . .14.3 Deliverables . . . . . . . . . . . . . . . . . .16 Lab 10: The z , n , and16.1 Introduction . . . . .16.2 Additional Notes . .16.3 Deliverables . . . . .2727272728Tele-.34353535of Musical. . . . . . . . . . . . . . . . . . . . . .39394040AFrequently Asked QuestionsBMatlab Function NotesB.1Freqz . . . . . . . .B.2Specgram . . . . .B.3Hist . . . . . . . .B.4Wavread . . . . . .B.5Wavwrite . . . . .414142424343COther Exercises and DemonstrationsC.1Sound Demos . . . . . . . . . . . . . . . .C.2Convolution Theater . . . . . . . . . . . .C.2.1Graphical Convolution Method .C.2.2System Processing Method . . .4343444444DYour Everyday Sinusoid46EIndependent Project Proposal48FLab S: Sampling and AliasingF.1Simple Examples . . . . . .F.1.1Chirp Folding . .F.1.2Sinusoid SamplingF.1.3Folding in Music .F.2Adjusting Pitch . . . . . . .40.505050505051

GJLab C: Convolution Lab54G.1Short Discussion of Calculating Convolutions 54G.1.1Using the Impulse Response . . . 54G.1.2Using the “Graphical Method” . . 55G.2Block Diagrams . . . . . . . . . . . . . . . . 55G.2.1Basic Add and Multiply Blocks . 56G.2.2The Delay Block . . . . . . . . . . 56G.2.3Improving the Blocks . . . . . . . 56G.2.4Creating Systems . . . . . . . . . 57G.2.5Making the Demos . . . . . . . . 57G.3Demo Sound-track . . . . . . . . . . . . . . 58G.3.1Loading Music . . . . . . . . . . . 58G.3.2Note-Pass Filter . . . . . . . . . . 58G.4Final Notes . . . . . . . . . . . . . . . . . . 60HImage Magnitude and Phase Supplement61ILab 11: Extracting Frequencies of MusicalTonesI.1Note Filters . . . . . . . . . . . . . . . . . .63633Matlab Primer by Brian StoreyJ.1Getting Started . . . . . . . . . . . . .J.2Calculator . . . . . . . . . . . . . . . .J.3Variables . . . . . . . . . . . . . . . . .J.4One-dimensional arrays . . . . . . . . .J.5Plotting . . . . . . . . . . . . . . . . .J.6Two-dimensional arrays . . . . . . . .J.7Relational operators . . . . . . . . . .J.8Scripts . . . . . . . . . . . . . . . . . .J.9Control flow . . . . . . . . . . . . . . .J.10 Logical Operators . . . . . . . . . . . .J.11 Files . . . . . . . . . . . . . . . . . . .J.12 Example: Numerical Integration . . . .J.13 Example: Rate Equations . . . . . . .J.14 Example: Plotting Experimental DataJ.15 Functions . . . . . . . . . . . . . . . .J.16 Problems . . . . . . . . . . . . . . . . .65. 66. 66. 68. 70. 75. 77. 80. 83. 83. 88. 88. 90. 92. 94. 97. 104

1PrefaceThis document is intended to supplement the Matlab labs included in DSPFirst1for usein a class on Signals and Systems. It includes the clarifications, corrections, and lecturenotes (’class-ifications’) that we found to be necessary, and occasionally helpful. The noteshere are generally not intended to replace the lab descriptions in DSPFirst, and should beused in combination with them. This commentary is based on the experiences from the labsand class taught by Jimmy and Diana, respectively, during Fall 2003 and Spring 2004. Wehoped to save these thoughts for future generations of students.1.1Document FormatThis document is organized around each DSPFirstlab and class activity. A subset of thesewere presented, in order, throughout each semester. A sample syllabus is included at theend of this section.Each lab is divided into three sections.Introduction : The lab introduction maps to my discussion of each lab before setting thestudents loose to work on it during the lab time. It variously includes content delivery,explanations, and warnings.Additional Notes : This section might include several different topics: “Student Supplement” sections to be made available to the students directly; “Question Help”concerning how to help students through common problems; and “Section Commentary”, with notes and clarifications on the labs on a section-by-section basis.Deliverables : This describes what should be turned in for evaluation. In the instructor’sversion of this document, this section includes a part on Grading, with notes on whatto look for and how to respond.1DSP First: A Multimedia Approach by James H. McClellan, Ronald W. Schafer,and Mark A. Yoder (Prentice Hall, 1997), ISBN 01324317184

1.1.1TypefacesDifferent typefaces are used to denote the use and audience of the comments. Roman font: These are comments for the instructor. Sans serif: These comments are directed toward students. Monospace font: Matlab commands and computer or programming text. Italics: These are thoughts, untested suggestions, and notes to the instructor.The comments to students and methods of teaching are meant to be suggestions and a recordfor how I teach. Even as that, they are incomplete and reflect broad strokes more than actualverbiage. If they do not work for you, do not use them.1.2Past Lab PoliciesEvery week, a two-hour block was set aside for in-class lab. I would use the first 15 to 40minutes of this time to handle general class business, get feedback from students on recenthappenings, introduce the lab and teach any important topics related to it. The rest of thetime was available for students to work and ask questions. If there were too many questionsto answer, I would start a question queue on the board and invite students to add theirnames to the end.Each lab would be due 1 21 weeks later. Students would place the deliverables for each lab in afolder on Olin’s StuFac server (stufps01/stufac/Signals and Systems/Lab Turnins/ Student / Lab and then email me. I would work through the emails in order. I do not use the InstructorVerification Sheets from DSPFirst.I do use repetitive grading. Students could turn in labs as many times as they wished upto the due date, but did not get much credit for incorrect or incomplete work. When I wasbehind on grading, as I often was, I would specify in my emailed reply how many days theyhad remaining from that point to do corrections, discounting all but one of the days theyhad to wait for the feedback.1.2.1DeliverablesMy interest is in the doing of things, not the writing-up of them. What I expect in lab reports,5

then, is exactly as much information as I need to see that you did the exercise and understood it.In general, that means including, succinctly, what you did for the lab (often Matlab code) andwhat you got for results (often graphs). For every lab, turn in a folder with all of your files (onStuFac), plus an index file which tells me what the other files are, as well as your collaboratorsand time-spent. You may make a single document with your comments, code, and graphs, orinclude your graphs and code in separate files in the same directory, as specified by your indexfile. If you wrote an m-file for the lab, include it in your folder; if you just wrote commands intoMatlab’s window, you can just copy those lines into your index file.Irregular reminders to include time-spent and collaborators in lab reports are useful.1.2.2CollaborationYour labs should be your own work. Feel free to work together (e.g., side-by-side, discussing theproblems), but don’t explicitly share your solutions.1.3Example SyllabusAs a way to gauge the semester as a whole, here is a sample syllabus, which reflects a currentsense of the “best practice”. Each actual syllabus will deviate as needed for the structure ofthe semester and for new ideas.6

WeekWeek 1Week 2Week 3Week 4Week 5Week 6Week 7Week 8Week 9Week 10Week 11Week 12Week 13Week 14Class TopicsAppendix A: Complex NumbersAppendix AChapter 2: SinusoidsChapter 2Chapter 3: Spectrum RepresentationChapter 3Chapter 3Chapter 4: Sampling and AliasingChapter 4Chapter 4Exam 1Chapter 5: FIR FiltersChapter 5Chapter 5Chapter 6: Frequency Response of FIR FiltersChapter 6Chapter 6Chapter 7: z-TransformsChapter 7Chapter 7Chapter 8: IIR FiltersExam 2Chapter 8Chapter 8Chapter 9: Spectrum AnalysisChapter 9Chapter 9Chapter 9Lab Introduced and BusinessLab 1: Introduction to MatlabLabLabLabLabLab2: Introduction to Complex Exponentials1 Due3: Synthesis of Sinusoidal Signals2 Due3 ContinuedLab 4: AM and FM Sinusoidal WaveformsLab 3 DueLab S: Sampling and AliasingLab 4 DueLab 5: FIR Filtering of Sinusoidal SignalsLab S DueLab 6: Filtering Sampled Waveforms (either)Lab 5 DueLab 7: Everyday Sinusoidal Signals (either)Lab 6 DueLab 8: Filtering and Edge Detection of Images and supplementLab 7 DueLab 9: Sampling and Zooming of ImagesLab 8 DueIndividual Projects and Lab 10: The z-, n-, and ω̂-DomainsLab 9 DueProjects and Lab 11: Extracting Frequencies of Musical TonesLab 10 DueLab 11 Due; Individual Projects DueAlthough the following are described below, I have not included them in the sample syllabus. Everyday Sinusoids: While this assignment got interesting responses, it is ultimatelynot yet well enough integrated into the course. Lab C: This lab is a bit too advanced for the place in the semester for which it waswritten, and the material is put to better use as a replacement for lab 11.Note that the current replacement for lab 11 uses the same methodology as Lab 7: TelephoneTouch-tone Dialing. If you choose the telephone lab, you may want to do lab 11 differently.1.4Future WorkThere remain some holes to be filled in this class, and in this document:New Convolution Lab : A replacement for Lab C with simple, intuitive exercises tounderstand convolution and its methods of calculation.More Demonstrations : Additional demonstrations were used in the class, and it wouldbenefit greatly from even more.7

22.1General NotesThe CDThere are small differences between material as it appears in the book and on the CD. Forexample, in the labs the section numbers are different between the book and the CD. Thenumbers used below are from the book.In the grading and section-by-section comments, each number refers to a specific book orlab section, as shown below:C.1.3.1: Manipulating Sinusoids with Matlab :1. This refers to C.1.3.1.12.2Book NotationMatlab matrix indices start at 1, while the book consistently starts indices for finitediscrete-time functions with n 0. As a result, the following are equivalent: h[0], h0 ,and hh(1). Generally, for discrete-time functions, the book will use the index n, for FIRfilters it uses the subscript k, and for Matlab vectors, in cases where indices cannot beavoided, nn or ii. This can cause confusion, as n k nn 1.3Lab 1: Introduction to Last Used:C.1.2.2: MatlabArrayIndexing,C.1.2.7: Vectorization, DSPFirst CDbefore other Matlab worknonesee belowFall 2003, Spring 20048C.1.2.5: MatlabSound,

3.1IntroductionPlease review the Course Policies (http://dsp.ece.olin.edu/policies.shtml), Grading(http://dsp.ece.olin.edu/grading.shtml), and Assignment Format http://dsp.ece.olin.edu/hwformat.shtml pages and ask any questions you might have on them.Appendix B of DSPFirst is a wonderful introduction to Matlab. Brian Storey has writtenan even better introduction to Matlab in general, although it is less specifically applicableto our work. The largest time sink students experience in this class is from struggling withMatlab commands. Use help liberally, but if you are struggling with a feature of Matlab,ask for help before you get frustrated!Demo zdrill. In class, you’ve been working with complex numbers. zdrill may be helpful foryou to improve your understanding of them, though we’re not going to use it directly.The first lab is comprised of exercises in Matlab. If you are comfortable with Matlab, theexercises should take very little time.3.1.1Installing DSPFirstHave some network cables for those who do not have their books.1. Copy dspfirst.exe from the CD (MATLAB\WINDOWS\DSPFIRST.EXE) or StuFac /WINDOWS/DSPFIRST.EXE) and place itin your Matlab toolbox directory (C:\MATLAB.\toolbox).2. Run dspfirst.exe. It will open a window and extract its contents (a DSPFIRSTdirectory) to your toolbox.3. Open Matlab.4. From the File menu, select Add Path. Click Add with subfolders and browseto the new DSPFIRST directory. Select it and click okay. Your path list will be updatedwith the subdirectories of DSPFIRST. Then click Save.Spend time this week familiarizing yourself with the CD, which has many goodies and the website,which might too.9

3.1.2Measuring PhasesThere are two common ways to measure the phase of a sinusoid from a graph. You may use anymethod you wish, but your answer should be correct to at least 2 significant figures.The first method is the most intuitive. Draw a sinusoid with coordinate axes and a peak left ofthe origin. Start by measuring the period of your sinusoid. (mark the x-coordinate of two peaks)Consider that if it were an unshifted cosine wave, its first peak would be at 0. Intuitively, then,the fraction of this first peak location (indicate the peak closest to zero) to the total period,times 2π is the phase shift. Remember to adjust the sign of the phase shift: left is positive, rightφ, whereis negative. In other words, the relation between time shift and phase shift is tT0 2πt0 is the peak location, T is the period, and φ is the phase shift.The second method is more analytic, and more precise, if you know the value of your sinusoid at0. The equation for a sinusoid is x(t) Acos(ωt φ). Evaluate this at t 0 and rearrange toget x(0) cos(φ) or φ cos 1 ( x(0)). In other words, if you measure the y-intercept, which youAAcan usually do precisely with Matlab, divide by the amplitude, and take the inverse cosine, youget the phase shift. The result will always be positive, so you still have to add on the sign.3.23.2.1Additional NotesQuestion HelpC.1.2.5: Matlab Sound : It may be difficult to hear the change in the sound, but donecorrectly there will be a definite difference. Note that the change will not be one ofpitch; it will be one of quality.C.1.2.7: Vectorization : If you are having difficulty with this, go back to part 1 and explainhow A A .* (A 0) works. What is the value of (A 0)?3.3Deliverables C.1.2.2: Matlab Array Indexing: Run the commands, understand them, but you only needto include in your write-up your work for part 3. C.1.2.5: Matlab Sound: Do it, and answer the length question. Now change the samplingfrequency to 16000; Do you hear a difference? Now double xx (xx 2*sin(2*pi*2000*t);),still using the doubled sampling frequency. Do you hear a difference? Explain any differences.10

C.1.2.7: Vectorization: Include in your lab report your vectorized code. C.1.3.1: Manipulating Sinusoids with Matlab: Do parts 1, 4, 5, and 6.4Lab 2: Introduction to Complex tions:Last Used:C.2.2.1: Complex Numbers, C.2.2.2: Sinusoid Synthesis with an MFile, C.2.3.2: Verify Addition of Sinusoids Using Complex Exponentials,C.2.4: Periodic Waveformsrelation between sinusoids and complex exponentialsnonesee belowFall 2003, Spring 2004Some labs are built around verifying theory, others around exploring an application. Inaddition, many try to expand one’s abilities in Matlab. A useful improvement to thiscourse would be to specify some of each approach in each lab, as is done in this lab.4.1IntroductionShow the use of zvect, zprint, and zcat, by essentially doing section C.2.2.1: ComplexNumbers for students, on the projector screen.This is a relatively self-explanatory lab, but here are a couple of notes.4.1.1Fixing zvect and zcatReplace the line if( vv(1) ’5’ ) in zvect and zcat with if( vv(1) ’5’ vv(1) ’6’) and then reload Matlab. Otherwise, these functions will not work.4.1.2Explaining sumcosI think C.2.2.2: Sinusoid Synthesis with an M-File is one of the most clever problems in thebook, and well worth a little frustration on the students’ part. In this problem, one wantsto generate a sum of sinusoids given their fundamental information (frequency and phasor).11

The challenge is to manipulate the values so as to do most of the calculation in a way thattakes advantage of Matlab’s optimized matrix multiplication.It is one of the mind-blowing results of Signals and Systems that any periodic function can beproduced by adding together sinusoids of the right amplitudes, frequencies, and phase shifts. Thefirst exercise, writing sumcos is just a way to do that efficiently in Matlab and it will be usefulto us later.There are three areas where you have to make intellectual leaps: How complex numbers canbe used for magnitude and phase; how some matrix elements map to pieces of your sinusoidequation; and how to make the matrix math combine the right pieces.At this point, you can let them work for a while (read the problem and try to figure itout), or you can give in and help them some more. You may also want to explain matrixmultiplication (which indices are summed over) and how to take a transpose in Matlab(the ’ operator).Here is the mapping you want:complex exponent summingzx′ (t) } LXk 1{matrix mathzej2πfk t Xk cn } LXk 1{ank bkSeen another way, you want to make Matlab calculate: x′ (0) x′ ( f1s ) x′ ( f2s ) · · · x′ (tdur )X1 X 2 · · · X L 2πf1 f1s 2e0 ee2πf1 f s · · · e2πf1 tdur21e0 e2πf2 f s e2πf2 f s · · · e2πf2 tdur.2πfL f1s2πfL f2s02πfL tdure ee··· e Note that the number of elements for each dimension works out: there are L sinusoids to sum,and N (for the index n) elements of time.For matrix subscripts, the first element denotes the rows, the second the columns. So you firstneed to make the elements of the a matrix above be such that each element corresponds to adifferent pairing of time and sinusoid. You will need to use transpose to do this.When you’re all done, you need to convert the complex exponentials to cosines by taking the realpart of your results (this is why I use x′ above).12

The way to tackle this problem is to start by combining t and f ; then make that into the exponentof a complex exponential; then multiply by X; then take the real part.4.2Additional Notes4.2.1Student SupplementTest your sumcos (see C.2.2.2: Sinusoid Synthesis with an M-File)! In Matlab, xx sumcos(25*(1:25),(1 j) ./ (1:25), 1000, .1) should result in the following graph (after proper labeling):Sumcos Litmus Test43x sumcos(.)210 1 200.020.040.06t 0:(1/1000):.10.080.1C.2.3.2: Verify Addition of Sinusoids Using Complex Exponentials is not very clear on its overallgoal. They want to show that if you do math with complex exponentials, you will get the sameresults as if you had added together full sinusoids. The process that it wants you to follow is this:1. Generate four sinusoids.2. Add them together to get a fifth sinusoid.13

3. Measure the magnitude and phase of the summed result.4. Generate five complex exponentials, including your measured results, using commands likez A * exp(j*phi), where A and phi are the values that you were given or measured.5. Add together the first four complex exponentials. The result should be approximately equalto the fifth complex exponential.In the last step, you can confirm the result by showing the numbers, but you should also confirm itgraphically. Use zcat to graphically add (by concatenating end-to-end) the first four exponentials.Using hold and zvect, plot the last exponential on the same graph. The results of zvect andzcat should point to the same place, making a closed loop.4.3Deliverables Matlabiness: C.2.2.2: Sinusoid Synthesis with an M-File: Complete the definition ofsumcos; include the three plots from the end of the section Verification: C.2.3.2: Verify Addition of Sinusoids Using Complex Exponentials: Do all 7parts, except for the verification in part 2. Application: C.2.4: Periodic Waveforms: Do parts 1 and 3.5Lab 3: Synthesis of Sinusoidal :Last Used:C.3.2.3: Piano Keyboard, C.3.3: Synthesis of Musical Notessinusoids sounds, harmonicsnoneallow 2 weeks for full effectFall 2003, Spring 2004This has consistently been one of the student’s favorite labs.5.1IntroductionI start by showing off past songs, to get people excited about making their own.14

The goal of this lab is to make a song, with both a treble and a bass line, that sounds plausible.You have more freedom in this lab than the previous ones. I’m going to describe one way toapproach this problem, but there may be others, which you’re welcome to pursue.We can input our songs as arrays of numbers, which index the keys on a piano, and durations.There are 88 keys on a piano, so the piano-key-numbers will range from 1 to 88.5.1.1Minimal Music TheoryThe simplest way to make a song is by stringing together a series of sinusoids of the appropriatefrequencies (the frequency produced by pressing a given piano key). There exists a straightforward relation between the frequencies used in music, and we will use that to translate thepiano-key-numbers into frequencies.Music frequencies are on a logarithmic scale– your ear hears tones as related when one is a simplefraction multiple of the other. The most closely related tones are said to be “one octave apart”,and this corresponds to the higher frequency being exactly twice the lower frequency. On a piano,there are 12 notes within each octave; twelve frequencies are used between a given note and thenote with twice its frequency.During the Baroque era, keyboardists adopted “equal-tempering”– that is, having every noterelated to the one after it by the same multiplicative factor. Since there are twelve notes in eachoctave, and after those twelve notes you need to have a doubling of frequency, that multiplicativefactor is none other than 21/12 .Now all you need is one reference and you have every note. Traditionally, that reference is the Aabove middle-C, key 49, with a frequency of 440 Hz.Now it’s just a matter of data input to get old video-game quality music.5.1.2Harmonics and Other ImprovementsPure sinusoids won’t sound very realistic, but there are several things that you can do to improveyour song. One is to use “harmonics”, adding several higher frequencies, all of which are multiplesof your original frequency. As you saw with sumcos, the result will still have the original frequency,but a different shape. Every instrument has a characteristic pattern of harmonics, and these arewhat largely give its sound its quality.15

This is also what distinguishes different vowel sounds in speech. A vowel sound is characterizedby a particular pattern of harmonics of whatever pitch of the person’s voice is at (the fundamentalfrequency). The sound ’aaaaahhh’ sounds different from a pure sinusoid because it has othersinusoids added in. However, the frequencies of all those other sinusoids are multiples of the pitchfrequency, so that final signal still has the same period as the pure sine wave. ’Aaahhh’ soundsdifferent from ’eeeehhh’ because of how large each of those harmonics is.Another way to improve the sound is to multiply each note by an “envelope”. The notes will soundmore realistic if their volume changes over their duration the way it would if played on a piano:getting loud at one moment and slowly dying off later. Since volume corresponds to the magnitudeof the sinusoids, we can cause this effect by multiplying the sinusoids by an appropriately shapedfunction. This is ADSR scaling (attack, delay, sustain, release) and C.3.3.3: Musical Tweaksexplains it more.The best way to approach this lab is to do C.3.2.3.2, writing the tone function, and thenC.3.2.3.3, the play scale function. You can modify these to make your song and add additionalfeatures. If you need more background, you probably want to read through from the beginningof the lab.5.25.2.1Additional NotesStudent SupplementThe two improvements that will probably make the largest effect are ADSR scaling and harmonics(see C.3.3.3: Musical Tweaks).If you do the warm-ups, ignore the malicious amplitude A 100 in C.3.2.2.1. Use A 1.The following data files, with notes and durations, are available for your use, in the matlabdirectory.16

Song TitleJesu, Joy of Man’s DesiringFur EliseMinuet in GThe Girl from IpanemaGigue Fugue BMV 577Cannon in DFinal Fantasy SongTwinkle, Twinkle Little StarFifth SymphonyCarol of the BellsVariationThe Parting Glass 2PopularTears in HeavenToki ni Ai WaSuite Bergamasque 4th Movement, PassepiedMy io Carlos JobimBachPachelbelUnknownMozartBeethovenPeter J. WilhouskyJacob GrahamTraditionalStephen SchwartzEric Claptonfrom “Shoujo Kakumei Utena”Claude DebussyEvanescenceData InputBen DonaldsonDSPFirst AuthorsNick ZolaRansom ByersKaterina BlazekJeffrey SatwiczChris MurphyJames KrejcarekKevin TostadoDaniel LindquistJacob GrahamCaitlin FoleyJerzy WieczorekJay GantzMikell TaylorFrances HaugenAmanda okiniaiwa.mpassepied.mimmortal.mQuestion HelpThe ADSR envelope can be difficult, depending on how it is approached (see C.3.3.3: MusicalOne systematic way to do it is by choosing slopes and intercepts, than thenprogramming equations for each of the form y mx b. However, note that this equationmust take into account the length of the note, which will change the slope.Tweaks).The easiest way is to use linspace and vector concatenation.5.3DeliverablesCreate one song (treble and bass), plus two “improvements”. You may use song data alreadywritten or write your own. Writing your own song cou

Chapter 7: z-Transforms Lab 7: Everyday Sinusoidal Signals (either) Week 10 Chapter 7 Lab 6 Due Chapter 7 Lab 8: Filtering and Edge Detection of Images and supplement Week 11 Chapter 8: IIR Filters Lab 7 Due Exam 2 Lab 9: Sampling and Zooming of Images Week 12 Chapter 8 Lab 8 Due Chapter 8 Individual Projects and Lab 10: The z-, n-, and ˆω .

Related Documents:

Component Dsp codec wrapper Component Dsp render. HIFI4 Core. Dsp codecs. SAI/ESAI/DMA DAC. Figure 2. Software architecture for DSP processor The DSP-related code includes the DSP framework, DSP remoteproc driver, DSP wrapper, unit test, DSP codec wrapper, and DSP codec. The DSP framework is a firmware code which runs on the DSP core.

May 02, 2018 · D. Program Evaluation ͟The organization has provided a description of the framework for how each program will be evaluated. The framework should include all the elements below: ͟The evaluation methods are cost-effective for the organization ͟Quantitative and qualitative data is being collected (at Basics tier, data collection must have begun)

Silat is a combative art of self-defense and survival rooted from Matay archipelago. It was traced at thé early of Langkasuka Kingdom (2nd century CE) till thé reign of Melaka (Malaysia) Sultanate era (13th century). Silat has now evolved to become part of social culture and tradition with thé appearance of a fine physical and spiritual .

On an exceptional basis, Member States may request UNESCO to provide thé candidates with access to thé platform so they can complète thé form by themselves. Thèse requests must be addressed to esd rize unesco. or by 15 A ril 2021 UNESCO will provide thé nomineewith accessto thé platform via their émail address.

̶The leading indicator of employee engagement is based on the quality of the relationship between employee and supervisor Empower your managers! ̶Help them understand the impact on the organization ̶Share important changes, plan options, tasks, and deadlines ̶Provide key messages and talking points ̶Prepare them to answer employee questions

Dr. Sunita Bharatwal** Dr. Pawan Garga*** Abstract Customer satisfaction is derived from thè functionalities and values, a product or Service can provide. The current study aims to segregate thè dimensions of ordine Service quality and gather insights on its impact on web shopping. The trends of purchases have

Nov 29, 2013 · Title Chip Mega Man X3/ Rockman X3 CX4 Mega Man X2/ Rockman X2 CX4 Suzuka 8 Hours DSP-1 Super F1 Circus Gaiden DSP-1 Super Bases Loaded 2 / Super 3D Baseball DSP-1 Super Air Diver 2 DSP-1 Shutokō Battle 2: Drift King Keichii Tsuchiya & Masaaki Bandoh DSP-1 Shutokō Battle '94: Keichii Tsuchiya Drift King DSP-1 Pilotwings DSP-1 Mic

Chính Văn.- Còn đức Thế tôn thì tuệ giác cực kỳ trong sạch 8: hiện hành bất nhị 9, đạt đến vô tướng 10, đứng vào chỗ đứng của các đức Thế tôn 11, thể hiện tính bình đẳng của các Ngài, đến chỗ không còn chướng ngại 12, giáo pháp không thể khuynh đảo, tâm thức không bị cản trở, cái được