Class Notes ( A Draft ) I547 Music Information Processing: Audio Prof. Christopher Raphael Indiana University, Bloomington Spring 2008 Week 1 (Last updated: Jan. 18) 1 Sound Propagation From this figure, we could see that tuning fork is changing pressure over time ear drum (changing displacement). One can think of sound time-varying changes of pressures or displacement. This figure tries to give the answer to the question: what is sound? It starts as physical vibration -- actual time-varying displacement of something (like a folk). These are propagated through the air as time-varying pressure. Then when they hit some object they are translated back into time-varying displacement. Processing 2 Sampled Audio Sampled Audio represents sound as sequence of numbers corresponding to evenly spaced measurements of pressure. 3 Important Sampling Parameters • Sampling Rate = SR = # of sample per unit time. (Usually measured in HZ = cycles (samples) per second or in KHz = 1000 Hz) Audio on compact disc 44.1 KHz Audio on DAT (digital audio tape) 48 KHz Internet telephony 8KHz As SR decreases sound quality degrades. Arguments suggest no point (for humans) if SR is much larger than 40KHz. Samples usually represented on computer as integers. • The bit depth = # bits per sample Most common representation is signed integers. Usually measured in HZ = cycles (samples) per second or in KHz = 1000 Hz) Say bit depth = 16, so sample is 2 bytes. 0 = 0000 0000 0000 0000 ambient pressure (all measures are relative to this.) 1 = 0000 0000 0000 0001 2 = 0000 0000 0000 0010 ...... 215 -1 = 0111 1111 1111 1111 are positive pressures -1 = 1111 1111 1111 1111 215 -1 = 1000 0000 0000 0001 Typical bit depth = 16 though some compression schemes such as “mulaw” use fewer bits and represent non-evenly space numbers (numbers more densely clustered near 0). Sound quality degrades as bit depth decreases. Do experiments with SR and bit depth. Listen to Mozart Oboe Concerto samples on the webpage http://www.music.informatics.indiana.edu/courses/I547/course.html#sound 4 The Sine Wave The unit circle is circle with radius 1 centered at “origin” (0,0). Start at (1,0) and move counter clockwise around circle making full cycle each second (1Hz). Look at The projection onto x axis. One could think of projection as function of arc distance travelled around circle rather than time. This function is cosine cos(t). If we examine the projection onto y-axis, we get sin(t) is the projection onto y-axis as we travel distance t around circle. Note: Projection onto x-axis is starting at (1, 0)[0] is same as the projection onto y axis starting at (0,1) [π/2]. Sine and cosine are same except for shift. Since cos(t) and sin(t) are “x” and “y” coordinates of points an unit circle with angle t (radians), we have: