You are on page 1of 14

SOME SIMPLE MANIPULATIONS OF SOUND USING DIGITAL SIGNAL PROCESSING Richard M.

Stern
18-791 demo
August 31, 2004

Department of Electrical and Computer Engineering and School of Computer Science Carnegie Mellon University Pittsburgh, Pennsylvania 15213

The original sound and its spectrogram

5000

4000

3000

2000

1000

0 0 0.2 0.4 0.6 Time 0.8 1 1.2

Carnegie Mellon

Slide 2

18-791 Digital Signal Processing I

Downsampling the waveform


Downsampling the waveform by factor of 2:
0.015 0.01 0.005 0 -0.005 -0.01 -0.015 0 10 20 30 40 50 n 60 70 80 90 100

0.015 0.01 0.005 0 -0.005 -0.01 -0.015 0 5 10 15 20 25 n 30 35 40 45 50

Carnegie Mellon

Slide 3

18-791 Digital Signal Processing I

Consequences of downsampling
Downsample
5000

Original:
Downsampled:

4000

3000

2000

1000

0 0 0.1 0.2 0.3 Time 0.4 0.5 0.6

Carnegie Mellon

Slide 4

18-791 Digital Signal Processing I

Upsampling the waveform


Upsampling by a factor of 2:
0.015 0.01 0.005 0 -0.005 -0.01 -0.015 0 10 20 30 40 50 n 60 70 80 90 100

0.015 0.01 0.005 0 -0.005 -0.01 -0.015 0 20 40 60 80 100 n 120 140 160 180 200

Carnegie Mellon

Slide 5

18-791 Digital Signal Processing I

Consequences of upsampling

5000

Original:
4000 3000

Upsampled:
2000

1000

0 0 0.5 1 Time 1.5 2 2.5

Carnegie Mellon

Slide 6

18-791 Digital Signal Processing I

Linear filtering the waveform

x[n]

y[n]

Filter 1: y[n] = 3.6y[n1]+5.0y[n2]3.2y[n3]+.82y[n4] +.013x[n].032x[n1]+.044x[n2].033x[n3]+.013x[n4] Filter 2: y[n] = 2.7y[n1]3.3y[n2]+2.0y[n3.57y[n4] +.35x[n]1.3x[n1]+2.0x[n2]1.3x[n3]+.35x[n4]


Carnegie Mellon
Slide 7 18-791 Digital Signal Processing I

Filter 1 in the time domain


0.015 0.01 0.005 0 -0.005 -0.01 -0.015 0 20 40 60 n 80 100 120

8 6 4 2 0

x 10

-3

-2 0

20

40

60 n

80

100

120

Carnegie Mellon

Slide 8

18-791 Digital Signal Processing I

Output of Filter 1 in the frequency domain

5000

Original:
4000 3000

2000

Lowpass:

1000

0 0 0.2 0.4 0.6 Time 0.8 1 1.2

Carnegie Mellon

Slide 9

18-791 Digital Signal Processing I

Filter 2 in the time domain


0.015 0.01 0.005 0 -0.005 -0.01 -0.015 0 20 40 60 n 80 100 120

0.01

0.005

-0.005

-0.01

20

40

60 n

80

100

120

Carnegie Mellon

Slide 10

18-791 Digital Signal Processing I

Output of Filter 2 in the frequency domain

5000

Original:
4000

3000

Highpass:
2000 1000

0 0 0.2 0.4 0.6 Time 0.8 1 1.2

Carnegie Mellon

Slide 11

18-791 Digital Signal Processing I

The source-filter model of speech


A useful model for representing the generation of speech sounds: Amplitude

Pitch

Pulse train source p[n]

Vocal tract model Noise source

Carnegie Mellon

Slide 12

18-791 Digital Signal Processing I

Separating the vocal-tract excitation from the filter

Original speech: Speech with 75-Hz excitation:

Speech with 150-Hz excitation:


Speech with noise excitation:

Carnegie Mellon

Slide 13

18-791 Digital Signal Processing I

You might also like