# Frequency at which the maximum amplitude occurs of a signal

How can i find the frequency corresponding to maximum amplitude of each frame after uniform segmentation. • So? You didn't ask a question! – Marcus Müller Dec 7 '16 at 9:47

What you want in this case is to find the argmax of the FFT, the index (function 'argument'/arg) which yields the maximum (max), which is obtained via the findpeaks() function in matlab. If you're working in a different language, just search for argmax algorithm. It's not so easy to find the argmax (although the derivative of the signal will tell you a great deal).

The argmax given via findpeaks() will give you the index into the FFT at which the peak amplitude occurs.

Note: Using this technique will only give you a peak amplitude for a frequency $$\pm \, \frac{Fs}{2 \cdot \text{NFFT}}$$

But first off, you need to take the real part of your signal, just look at the second half of it. It's symmetrical.

When you get the argmax, you can compute the frequency of the peak amplitude by taking the argmax and multiplying by the width of your frequency bins, which is $$\frac{Fs}{\text{NFFT}}$$

For example:

If $$argmax(FFT(x[n]) = argmax(X[n])$$

then $$f_{peak} = \frac{argmax(X[n])*Fs}{\text{NFFT}}$$

where $$Fs$$ is the sampling frequency and $$\text{NFFT}$$ is the size of the FFT.

If you are using matlab, you can use spectrogram() and then find the maximum row in each column.