lecture # 22 audition, audacity & sound editing sound representation
TRANSCRIPT
Foundations of Computing
Lecture # 22Audition, Audacity & Sound EditingSound Representation
Digitizing Sound
Sound waves through AirDifferent Voltages
Voltage converted to numbers
Physics of Sound
Physics of SoundAmplitude increases sound gets louderLoudness measured in decibels (dB)- dB = 20 * log10(Amplitude/Reference Amplitude)
- 2 x loudness => 10 x amplitude
- 6 dB ~ smallest perceptible difference in amplitude
- Speakers go from 50 to 100 watts => ~ 6 dB increase Main idea human perception is not linear to logarithmic. Reference amplitude is the threshold of audibility at sound pressure levelThis formula is based on Amplitude and is proportional to VoltageAnother formula is based on power (Watts)10 * log10(W1/W2)Old slides based on this scale (power), but it doesnt relate as easily to amplitudeThere are advantages to getting somewhat higher power speakers but the advantage is often in reducing distortion, not as much an advantage in the loudness.In this slide we tried to use loudness as the measure of amplitude (measure of voltage or air pressure). This is fine. But others often use power(measure of intensity or watts). Power is proportional to the square of the amplitude, but, with logarithms, squaring the amplitudes only doubles the decibels.Thus, people can only perceive an 6 dB increase in amplitudes but a 3 dB increase in power. 5Common dB LevelsDecibel scale: smallest audible sound (~ total silence) is 0 dB.Near total silence 0 dB Breathing 10 dBA whisper 15 dBMosquito 20 dB Normal conversation 60 dB Over time, can damage hearing 85 dBA lawnmower 90 dB A car horn 110 dB A rock concert or a jet engine 120 dB Pain 130 dBA gunshot or firecracker 140 dB
These are of course approximate, Ive got different answers from different sites6Decibel Exposure Time GuidelinesAccepted standards for recommended permissible exposure time for continuous time weighted average noise, according to NIOSH and CDC, 2002. For every 3 dBs over 85dB, the permissible exposure time before possible damage can occur is cut in half.
109 dB1.875 min (< 2min)112 dB56 seconds115 dB28 seconds118 dB14 seconds121 dB7 seconds124 dB3.5 seconds127 dB1.75 seconds130 dBAlmost immediately85 dB8 hours88 dB4 hours91 dB2 hours94 db1 hour97 db30 minutes100 db15 minutes103 db7.5 minutes106 dB3.75 min (< 4min)
In other words, be careful or you will go deaf!FrequencyCycles per second or wavelengthMeasured in Hz (Hertz)Wavelength = Speed of sound through air/Hz
The higher the Hz the higher the pitch Lowest Pitch About 15 HzHighest Pitch Approximately 20 kHzLogarithmic in perceptionTone TestWhat range of frequencies can you hear?
Can you hear a 440 Hz Sinusoid?880 Hz?1760 Hz?3520 Hz?..- 10000 Hz?Audacity & AuditionDownload: http://audacity.sourceforge.net/
Loading and Saving/Exporting Files
Mute/Solo/Volume
Select/Cut/Paste
Zoom
Multi-track/StereoSinusoidal Tone Demo in Audacity880 Hz1620 Hz3240 Hz6480 Hz440 Hz220 Hz160 Hz120 HzHow low can you go?FrequencyHow high can you go?Generate > ToneSampling FrequencyHow often do we measure the voltage?
A sound wave
one half as many samples
one quarter as many samplesSampling Frequency
0000000-127-127-127127127127Base Sampling Frequency0-12701270-12701270-12701270Array Representation13Sampling Frequency
Twice Base Sampling Frequency127127127-127-127-1270000000909090909090-90-90-90-90-90-90Nyquist Theorem
0-90-127-90090127900-90-127-90090127900-90-127-90090127900Array RepresentationNyquist Theorem must sample higher than twice the highest frequency for accurate digitization14Sampling frequencyLike resolution in images
More samples = better quality
Fewer samples = less spaceSampling FrequenciesPeople talking on the phone10 KHz 10 KiloHertz 10,000 samples per second
CD quality musicHighest frequency: 22 KHz (44.1 KHz Sampling rate)
StereoTwo different signals, two different arraysQuantizationHow many bits per sample
Sound WaveHeavily QuantizedQuantization
-2-1 0 1-4-3-2-1 0 1 2 31 4 5 6 7 3 2 0-1-2-3-4-5-6-7-8Bits Per Sample:Speech 8 bits (1 byte)CD Music 16 bits (2 bytes)Professional Quality 32 bits (4 bytes)The first fly in is 2 bits / sampleThe second fly in is 3 bits / sampleThe third fly in is 4 bits / sample18Dynamic Range
-4-3-2-1 0 1 2 3-4-3-2-1 0 1 2 3-4-3-2-1 0 1 2 3The dynamic range of the first fly in is just rightThe dynamic range of the second fly in is too smallClipping will occur The dynamic range of the third fly in is goodThe last two meters are examples of input meters that measure dynamic rangeExplain problem of needle or bar going into redYou can show them the dynamic range meter in Audaciy
19QuantizationSpeech8 Bits per sample
CD Music16 Bits per sample
Professional quality32 Bits per sampleRepresenting SoundAn array of amplitudes (voltage measurements)Sampling FrequencyQuantizationDynamic Range
Dynamic RangeHow loud of a noise can you record
Dynamic range
Exceeding dynamic rangeWhere are the Words?
JanelovesthedogRalphknowsFred(Phred)
A sound fontdogJaneknowsFredRalphtheloves
Jane
loves
Fred
Sound ReviewThe physics: pressure, waves, db
Frequency and Sampling
Quantization and Fidelity
Dynamic RangeSheet111212120221-102-100202
Sheet2
Sheet3
Chart100.64421768720.985449730.86320936660.3349881502-0.3507832277-0.8715757724-0.9824526126-0.63126663790.01681390050.65698659870.98816823390.85459890810.3190983623-0.3664791293-0.87969576-0.9791777292-0.61813711220.03362304720.66956976220.99060735570.84574683110.3031183567-0.3820714172-0.8875670336-0.9756260055-0.60483282240.05042268780.68196362010.99276640580.83665563850.2870526513-0.3975556831-0.8951873678-0.9717984457-0.59135752990.06720807250.69416466830.99464477390.82732790060.2709057883-0.4129275492-0.9025546082-0.9676961321-0.57771504440.08397445570.70616945720.99624192880.81776625450.2546823328-0.4281826695-0.9096666718-0.9633202245-0.56390922330.1007170970.71797459280.99755741890.80797340370.2383868717-0.4433167309-0.9165215479-0.95867196-0.54994396960.11743126280.72957673740.9985908724
Sheet10.71000.64421768720.863209366620.70.64421768720.8632093666-0.982452612631.40.98544973-0.35078322770.988168233942.10.8632093666-0.9824526126-0.8796957652.80.33498815020.01681390050.669569762263.5-0.35078322770.9881682339-0.382071417274.2-0.87157577240.31909836230.050422687884.9-0.9824526126-0.879695760.287052651395.6-0.6312666379-0.6181371122-0.5913575299106.30.01681390050.66956976220.82732790061170.65698659870.8457468311-0.9676961321127.70.9881682339-0.38207141720.9962419288138.40.8545989081-0.9756260055-0.9096666718149.10.31909836230.05042268780.7179745928159.8-0.36647912930.9927664058-0.44331673091610.5-0.879695760.28705265130.11743126281711.2-0.9791777292-0.895187367801811.9-0.6181371122-0.591357529901912.60.03362304720.694164668302013.30.66956976220.8273279006021140.9906073557-0.412927549202214.70.8457468311-0.967696132102315.40.30311835670.083974455702416.1-0.38207141720.996241928802516.8-0.88756703360.25468233282617.5-0.9756260055-0.90966667182718.2-0.6048328224-0.56390922332818.90.05042268780.71797459282919.60.68196362010.80797340373020.30.9927664058-0.443316730931210.8366556385-0.958671963221.70.28705265130.11743126283322.4-0.39755568310.99859087243423.1-0.895187367803523.8-0.971798445703624.5-0.591357529903725.20.067208072503825.90.694164668303926.60.994644773904027.30.8273279006041280.270905788304228.7-0.412927549204329.4-0.902554608204430.1-0.967696132104530.8-0.577715044404631.50.083974455704732.20.706169457204832.90.996241928804933.60.817766254505034.30.25468233285135-0.42818266955235.7-0.90966667185336.4-0.96332022455437.1-0.56390922335537.80.1007170975638.50.71797459285739.20.99755741895839.90.80797340375940.60.23838687176041.3-0.44331673096142-0.91652154796242.7-0.958671966343.4-0.54994396966444.10.11743126286544.80.72957673746645.50.9985908724
Sheet1
Sheet2
Sheet3
Chart20.64421768720.8632093666-0.3507832277-0.98245261260.01681390050.98816823390.3190983623-0.87969576-0.61813711220.66956976220.8457468311-0.3820714172-0.97562600550.05042268780.99276640580.2870526513-0.8951873678-0.59135752990.69416466830.8273279006-0.4129275492-0.96769613210.08397445570.99624192880.2546823328-0.9096666718-0.56390922330.71797459280.8079734037-0.4433167309-0.958671960.11743126280.9985908724
Sheet10.71000.64421768720.863209366620.70.64421768720.8632093666-0.982452612631.40.98544973-0.35078322770.988168233942.10.8632093666-0.9824526126-0.8796957652.80.33498815020.01681390050.669569762263.5-0.35078322770.9881682339-0.382071417274.2-0.87157577240.31909836230.050422687884.9-0.9824526126-0.879695760.287052651395.6-0.6312666379-0.6181371122-0.5913575299106.30.01681390050.66956976220.82732790061170.65698659870.8457468311-0.9676961321127.70.9881682339-0.38207141720.9962419288138.40.8545989081-0.9756260055-0.9096666718149.10.31909836230.05042268780.7179745928159.8-0.36647912930.9927664058-0.44331673091610.5-0.879695760.28705265130.11743126281711.2-0.9791777292-0.895187367801811.9-0.6181371122-0.591357529901912.60.03362304720.694164668302013.30.66956976220.8273279006021140.9906073557-0.412927549202214.70.8457468311-0.967696132102315.40.30311835670.083974455702416.1-0.38207141720.996241928802516.8-0.88756703360.25468233282617.5-0.9756260055-0.90966667182718.2-0.6048328224-0.56390922332818.90.05042268780.71797459282919.60.68196362010.80797340373020.30.9927664058-0.443316730931210.8366556385-0.958671963221.70.28705265130.11743126283322.4-0.39755568310.99859087243423.1-0.895187367803523.8-0.971798445703624.5-0.591357529903725.20.067208072503825.90.694164668303926.60.994644773904027.30.8273279006041280.270905788304228.7-0.412927549204329.4-0.902554608204430.1-0.967696132104530.8-0.577715044404631.50.083974455704732.20.706169457204832.90.996241928804933.60.817766254505034.30.25468233285135-0.42818266955235.7-0.90966667185336.4-0.96332022455437.1-0.56390922335537.80.1007170975638.50.71797459285739.20.99755741895839.90.80797340375940.60.23838687176041.3-0.44331673096142-0.91652154796242.7-0.958671966343.4-0.54994396966444.10.11743126286544.80.72957673746645.50.9985908724
Sheet1
Sheet2
Sheet3
Chart30.8632093666-0.98245261260.9881682339-0.879695760.6695697622-0.38207141720.05042268780.2870526513-0.59135752990.8273279006-0.96769613210.9962419288-0.90966667180.7179745928-0.44331673090.1174312628
Sheet10.71000.64421768720.863209366620.70.64421768720.8632093666-0.982452612631.40.98544973-0.35078322770.988168233942.10.8632093666-0.9824526126-0.8796957652.80.33498815020.01681390050.669569762263.5-0.35078322770.9881682339-0.382071417274.2-0.87157577240.31909836230.050422687884.9-0.9824526126-0.879695760.287052651395.6-0.6312666379-0.6181371122-0.5913575299106.30.01681390050.66956976220.82732790061170.65698659870.8457468311-0.9676961321127.70.9881682339-0.38207141720.9962419288138.40.8545989081-0.9756260055-0.9096666718149.10.31909836230.05042268780.7179745928159.8-0.36647912930.9927664058-0.44331673091610.5-0.879695760.28705265130.11743126281711.2-0.9791777292-0.895187367801811.9-0.6181371122-0.591357529901912.60.03362304720.694164668302013.30.66956976220.8273279006021140.9906073557-0.412927549202214.70.8457468311-0.967696132102315.40.30311835670.083974455702416.1-0.38207141720.996241928802516.8-0.88756703360.25468233282617.5-0.9756260055-0.90966667182718.2-0.6048328224-0.56390922332818.90.05042268780.71797459282919.60.68196362010.80797340373020.30.9927664058-0.443316730931210.8366556385-0.958671963221.70.28705265130.11743126283322.4-0.39755568310.99859087243423.1-0.895187367803523.8-0.971798445703624.5-0.591357529903725.20.067208072503825.90.694164668303926.60.994644773904027.30.8273279006041280.270905788304228.7-0.412927549204329.4-0.902554608204430.1-0.967696132104530.8-0.577715044404631.50.083974455704732.20.706169457204832.90.996241928804933.60.817766254505034.30.25468233285135-0.42818266955235.7-0.90966667185336.4-0.96332022455437.1-0.56390922335537.80.1007170975638.50.71797459285739.20.99755741895839.90.80797340375940.60.23838687176041.3-0.44331673096142-0.91652154796242.7-0.958671966343.4-0.54994396966444.10.11743126286544.80.72957673746645.50.9985908724
Sheet1
Sheet2
Sheet3
Chart4008833-7-7-5-55577-3-3-8-8008822-7-7-5-555772-7-7-5-56677-3-3-8-8118822-7-7-5-56666-4-4-8-8116
Sheet180.71000020.70.64421768720831.40.985449738342.10.86320936668-752.80.33498815023-563.5-0.35078322773574.2-0.8715757724-7784.9-0.9824526126-7-395.6-0.6312666379-5-8106.30.0168139005-501170.656986598758127.70.988168233952138.40.85459890817-7149.10.31909836237-5159.8-0.3664791293-351610.5-0.87969576-371711.2-0.9791777292-8-71811.9-0.6181371122-8-51912.60.0336230472062013.30.66956976220721140.99060735578-32214.70.84574683118-82315.40.3031183567212416.1-0.3820714172282516.8-0.8875670336-72617.5-0.9756260055-72718.2-0.6048328224-52818.90.0504226878-52919.60.681963620153020.30.9927664058531210.836655638573221.70.287052651373322.4-0.397555683123423.1-0.8951873678-73523.8-0.9717984457-73624.5-0.5913575299-53725.20.0672080725-53825.90.694164668363926.60.994644773964027.30.8273279006741280.270905788374228.7-0.4129275492-34329.4-0.9025546082-34430.1-0.9676961321-84530.8-0.5777150444-84631.50.083974455714732.20.706169457214832.90.996241928884933.60.817766254585034.30.254682332825135-0.428182669525235.7-0.9096666718-75336.4-0.9633202245-75437.1-0.5639092233-55537.80.100717097-55638.50.717974592865739.20.997557418965839.90.807973403765940.60.238386871766041.3-0.4433167309-46142-0.9165215479-46242.7-0.95867196-86343.4-0.5499439696-86444.10.117431262816544.80.729576737416645.50.99859087246
Sheet1
Sheet2
Sheet3
Chart500.64421768720.985449730.86320936660.3349881502-0.3507832277-0.8715757724-0.9824526126-0.63126663790.01681390050.65698659870.98816823390.85459890810.3190983623-0.3664791293-0.87969576-0.9791777292-0.61813711220.03362304720.66956976220.99060735570.84574683110.3031183567-0.3820714172-0.8875670336-0.9756260055-0.60483282240.05042268780.68196362010.99276640580.83665563850.2870526513-0.3975556831-0.8951873678-0.9717984457-0.59135752990.06720807250.69416466830.99464477390.82732790060.2709057883-0.4129275492-0.9025546082-0.9676961321-0.57771504440.08397445570.70616945720.99624192880.81776625450.2546823328-0.4281826695-0.9096666718-0.9633202245-0.56390922330.1007170970.71797459280.99755741890.80797340370.2383868717-0.4433167309-0.9165215479-0.95867196-0.54994396960.11743126280.72957673740.9985908724
Sheet180.71000020.70.64421768720831.40.985449738342.10.86320936668-752.80.33498815023-563.5-0.35078322773574.2-0.8715757724-7784.9-0.9824526126-7-395.6-0.6312666379-5-8106.30.0168139005-501170.656986598758127.70.988168233952138.40.85459890817-7149.10.31909836237-5159.8-0.3664791293-351610.5-0.87969576-371711.2-0.9791777292-8-71811.9-0.6181371122-8-51912.60.0336230472062013.30.66956976220721140.99060735578-32214.70.84574683118-82315.40.3031183567212416.1-0.3820714172282516.8-0.8875670336-72617.5-0.9756260055-72718.2-0.6048328224-52818.90.0504226878-52919.60.681963620153020.30.9927664058531210.836655638573221.70.287052651373322.4-0.397555683123423.1-0.8951873678-73523.8-0.9717984457-73624.5-0.5913575299-53725.20.0672080725-53825.90.694164668363926.60.994644773964027.30.8273279006741280.270905788374228.7-0.4129275492-34329.4-0.9025546082-34430.1-0.9676961321-84530.8-0.5777150444-84631.50.083974455714732.20.706169457214832.90.996241928884933.60.817766254585034.30.254682332825135-0.428182669525235.7-0.9096666718-75336.4-0.9633202245-75437.1-0.5639092233-55537.80.100717097-55638.50.717974592865739.20.997557418965839.90.807973403765940.60.238386871766041.3-0.4433167309-46142-0.9165215479-46242.7-0.95867196-86343.4-0.5499439696-86444.10.117431262816544.80.729576737416645.50.99859087246
Sheet1
Sheet2
Sheet3