Implement the equivalent of the MSP cycle~ object in Matlab. Create a sinewave "table" of length 512 samples (a single period of a sinusoidal function). Then define a variable rate that controls the phase increment used for the determination of each output sample. The value of rate should be calculated from a desired sounding frequency and a specified sample rate, as well as the table size. Experiment with rounding and truncation of the lookup index and view the resulting spectra. Implement linear interpolation and compare.
Lab #3
24 January 2012
Create numerator and denominator coefficient vectors for feedforward and feedback comb filters in Matlab and view their frequency response using the freqz function.
y[n] = x[n] + 0.95 x[n-7] (feedforward comb)
y[n] = x[n] - 0.95 y[n-7] (feedback comb)
Lab #2
17 January 2012
Use Matlab to define and evaluate the following digital filters. In particular, note the relationship between the frequency magnitude response and the zero / pole locations for each using the freqz and zplane functions.
y[n] = x[n] + x[n-1]
y[n] = x[n] - x[n-1]
y[n] = x[n] + 0.9 y[n-1]
y[n] = x[n] - 0.9 y[n-1]
y[n] = x[n] + x[n-10]
y[n] = x[n] + y[n-10]
Lab #1
10 January 2012
Start Matlab and practice using the help command with some of the functions demonstrated during the class lecture.
Load a soundfile into Matlab (see the wavread or auread functions). Play the sound using the sound function. View the sound power spectrum using the spectrogram function (for example, spectrogram( y, 1024, 'yaxis' ) assuming the signal is found in variable y).
Using Matlab, create a sinusoidal signal and practice calculating its signal metrics.