+ All Categories
Home > Documents > waveforms.ppt

waveforms.ppt

Date post: 13-Apr-2015
Category:
Upload: sujith
View: 11 times
Download: 2 times
Share this document with a friend
Description:
sample and hold
19
Transcript
Page 1: waveforms.ppt
Page 2: waveforms.ppt

IntroductionIntroductionIntroductionIntroduction• For periodic waveforms, the duration of the For periodic waveforms, the duration of the

waveform before it repeats is called the waveform before it repeats is called the period of the waveformperiod of the waveform

Page 3: waveforms.ppt

FrequencyFrequencyFrequencyFrequency• the rate at which a regular vibration pattern the rate at which a regular vibration pattern

repeats itself (frequency = 1/period)repeats itself (frequency = 1/period)

Page 4: waveforms.ppt

Frequency of a WaveformFrequency of a WaveformFrequency of a WaveformFrequency of a Waveform

• The unit for frequency is cycles/second, The unit for frequency is cycles/second, also called Hertz (Hz). also called Hertz (Hz).

• The frequency of a waveform is equal to The frequency of a waveform is equal to the reciprocal of the period.the reciprocal of the period.

frequency = 1/period frequency = 1/period

Page 5: waveforms.ppt

Frequency of a WaveformFrequency of a WaveformFrequency of a WaveformFrequency of a Waveform

• Examples:Examples:frequency = 10 Hzfrequency = 10 Hz

period = .1 (1/10) secondsperiod = .1 (1/10) seconds

frequency = 100 Hzfrequency = 100 Hz

period = .01 (1/100) secondsperiod = .01 (1/100) seconds

frequency = 261.6 Hz (middle C)frequency = 261.6 Hz (middle C)

period = .0038226 (1/ 261.6) secondsperiod = .0038226 (1/ 261.6) seconds

Page 6: waveforms.ppt

Waveform SamplingWaveform SamplingWaveform SamplingWaveform Sampling• To represent waveforms on digital computers, we To represent waveforms on digital computers, we

need to digitize or sample the waveform.need to digitize or sample the waveform.

• side effects of digitization:side effects of digitization:• introduces some noise introduces some noise • limits the maximum upper frequency rangelimits the maximum upper frequency range

Page 7: waveforms.ppt

Sampling RateSampling RateSampling RateSampling Rate

• The sampling rate (SR) is the rate at which The sampling rate (SR) is the rate at which amplitude values are digitized from the amplitude values are digitized from the original waveform.original waveform.• CD sampling rate (high-quality):CD sampling rate (high-quality):

SR = 44,100 samples/secondSR = 44,100 samples/second• medium-quality sampling rate:medium-quality sampling rate:

SR = 22,050 samples/secondSR = 22,050 samples/second• phone sampling rate (low-quality):phone sampling rate (low-quality):

SR = 8,192 samples/secondSR = 8,192 samples/second

Page 8: waveforms.ppt

Sampling Sampling RateRate

Sampling Sampling RateRate

• Higher sampling Higher sampling rates allow the rates allow the waveform to be waveform to be more accurately more accurately representedrepresented

Page 9: waveforms.ppt

Nyquist Theorem and AliasingNyquist Theorem and AliasingNyquist Theorem and AliasingNyquist Theorem and Aliasing

• Nyquist TheoremNyquist Theorem::We can digitally represent only frequencies up to We can digitally represent only frequencies up to half the sampling rate. half the sampling rate.

• ExampleExample::CD: SR=44,100 HzCD: SR=44,100 HzNyquist Frequency = SR/2 = 22,050 HzNyquist Frequency = SR/2 = 22,050 Hz

• ExampleExample::SR=22,050 HzSR=22,050 HzNyquist Frequency = SR/2 = 11,025 HzNyquist Frequency = SR/2 = 11,025 Hz

Page 10: waveforms.ppt

Nyquist Theorem and AliasingNyquist Theorem and AliasingNyquist Theorem and AliasingNyquist Theorem and Aliasing

• Frequencies above Nyquist frequency Frequencies above Nyquist frequency "fold over" to sound like lower "fold over" to sound like lower frequencies.frequencies.• This foldover is called This foldover is called aliasingaliasing..

• Aliased frequency f in range [SR/2, SR] Aliased frequency f in range [SR/2, SR] becomes f':becomes f':

f' = |f - SR|f' = |f - SR|

Page 11: waveforms.ppt

Nyquist Theorem and AliasingNyquist Theorem and AliasingNyquist Theorem and AliasingNyquist Theorem and Aliasing

f' = |f - SR|f' = |f - SR|

• ExampleExample::• SR = 20,000 HzSR = 20,000 Hz• Nyquist Frequency = 10,000 HzNyquist Frequency = 10,000 Hz• f = 12,000 Hz --> f' = 8,000 Hzf = 12,000 Hz --> f' = 8,000 Hz• f = 18,000 Hz --> f' = 2,000 Hzf = 18,000 Hz --> f' = 2,000 Hz• f = 20,000 Hz --> f' = 0 Hzf = 20,000 Hz --> f' = 0 Hz

Page 12: waveforms.ppt

Nyquist Theorem and AliasingNyquist Theorem and AliasingNyquist Theorem and AliasingNyquist Theorem and Aliasing• Graphical Example 1aGraphical Example 1a::

• SR = 20,000 HzSR = 20,000 Hz• Nyquist Frequency = 10,000 HzNyquist Frequency = 10,000 Hz• f = 2,500 Hz (no aliasing)f = 2,500 Hz (no aliasing)

Page 13: waveforms.ppt

Nyquist Theorem and AliasingNyquist Theorem and AliasingNyquist Theorem and AliasingNyquist Theorem and Aliasing• Graphical Example 1bGraphical Example 1b::

• SR = 20,000 HzSR = 20,000 Hz• Nyquist Frequency = 10,000 HzNyquist Frequency = 10,000 Hz• f = 5,000 Hz (no aliasing)f = 5,000 Hz (no aliasing)

(left and right figures have same frequency, but have different (left and right figures have same frequency, but have different sampling points)sampling points)

Page 14: waveforms.ppt

Nyquist Theorem and AliasingNyquist Theorem and AliasingNyquist Theorem and AliasingNyquist Theorem and Aliasing• Graphical Example 2Graphical Example 2::

• SR = 20,000 HzSR = 20,000 Hz• Nyquist Frequency = 10,000 HzNyquist Frequency = 10,000 Hz• f = 10,000 Hz (no aliasing)f = 10,000 Hz (no aliasing)

Page 15: waveforms.ppt

Nyquist Theorem and AliasingNyquist Theorem and AliasingNyquist Theorem and AliasingNyquist Theorem and Aliasing• Graphical Example 2Graphical Example 2::

• BUT, if sample points fall on zero-crossings the BUT, if sample points fall on zero-crossings the sound is completely cancelled outsound is completely cancelled out

Page 16: waveforms.ppt

Nyquist Theorem and AliasingNyquist Theorem and AliasingNyquist Theorem and AliasingNyquist Theorem and Aliasing• Graphical Example 3Graphical Example 3::

• SR = 20,000 HzSR = 20,000 Hz• Nyquist Frequency = 10,000 HzNyquist Frequency = 10,000 Hz• f = 12,500 Hz, f' = 7,500f = 12,500 Hz, f' = 7,500

Page 17: waveforms.ppt

Nyquist Theorem and AliasingNyquist Theorem and AliasingNyquist Theorem and AliasingNyquist Theorem and Aliasing• Graphical Example 3Graphical Example 3::

• Fitting the simplest sine wave to the sampled Fitting the simplest sine wave to the sampled points gives an aliased waveform (dotted line points gives an aliased waveform (dotted line below):below):

Page 18: waveforms.ppt

Aliasing — Sound ExamplesAliasing — Sound ExamplesAliasing — Sound ExamplesAliasing — Sound Examples• [i:33][i:33] sine wave with variable frequency, SR sine wave with variable frequency, SR

= 22050= 22050

Page 19: waveforms.ppt

Aliasing — Sound ExamplesAliasing — Sound ExamplesAliasing — Sound ExamplesAliasing — Sound Examples

• Musical examples on the Bach trumpet:Musical examples on the Bach trumpet:• [i:34][i:34] SR=22050, highest frequency in music is SR=22050, highest frequency in music is

about 7000 Hz. (no aliasing)about 7000 Hz. (no aliasing)• [i:35][i:35] SR=11025 (some aliasing; adds a little SR=11025 (some aliasing; adds a little

metallic quality)metallic quality)• [i:36][i:36] SR=4410 (lots of aliasing; sounds like SR=4410 (lots of aliasing; sounds like

bad video game)bad video game)