The Goertzel algorithm can be used to detect single tone sinusoidal signals. We want to detect single tone signals of frequencies 490, 1280, 2730, and 3120 Hz generated by an oscillator operating at 8kHz. The Goertzel algorithm computes only one relevant sample of an N -point DFT for each tone to detect it.
1. What should be the minimum value of DFT length N so that each tone is detected with no leakage in the adjacent DFT bins. The same algorithm is used for each tone.
2. Modify the gafft function on page 461 and write a new MATLAB function X = gafft_vec(x,N,k) that computes DFT values at the indices given in the vector k.
3. Generate one second duration samples for each tone and use the above function on each set of samples to obtain the corresponding X vector. How would you set the threshold to detect each signal?