# Correlation and the Fourier transform

In the book Fundamentals of Music Processing: Audio, Analysis, Algorithms, Applications by Meinard Müller, the coefficients $$d_\omega$$ and $$\phi_\omega$$ are defined as where $$\cos_{\omega,\phi}(t) = \sqrt{2}\cos(2\pi(\omega t - \phi))$$. Also it's said that "The computation of $$d_\omega$$ and $$\phi_\omega$$ feels a bit awkward, since it involves an optimization step. The good news is that there is a simple solution to this optimization problem, which results from the existence of certain trigonometric identities that relate phases and amplitudes of certain sinusoidal functions. Using the concept of complex numbers, these trigonometric identities become simple and lead to an elegant formulation of the Fourier transform."

I don't understand how the Fourier transform itself solves the optimization problem. Obviously in the defining the Fourier transform we don't consider any optimization but it seems that the author claims the Fourier transform's definition takes into the account $$\max_{\phi \in [0 , 1)}$$ and $$\text{argmax}_{\phi \in [0 , 1)}$$. What am I missing here? Are the optimizations $$\max_{\phi \in [0 , 1)}$$ and $$\text{argmax}_{\phi \in [0 , 1)}$$ included in the Fourier transform?

That's a pretty tortured way of defining the Fourier Transform.

Are the optimizations $$\max_{\phi \in [0 , 1)}$$ and $$\text{argmax}_{\phi \in [0 , 1)}$$ included in the Fourier transform?

Yes. The optimization steps are completely unnecessary. Instead of "finding the phase that maximizes the integral", we can just simply calculate that phase directly.

Also it's said that "The computation of dω and ϕω feels a bit awkward, since it involves an optimization step.

No, it really doesn't. The optimization is just an artifact of a somewhat unusual definition (to put it politely).

If the author is afraid of complex numbers, you can simply break it down as

$$A = \int x(t)\cos(\omega t)dt, B = \int x(t)\sin(\omega t)dt$$

Then $$d_\omega = \sqrt{A^2+B^2}, \phi_{\omega} = {\rm atan2}(\frac{B}{A})$$

No optimization required.

• Thanks. So the optimization is redundant here. By applying the Fourier transform, we simply measure the correlation of the function with $e^{-2\pi i \omega t}$ for every $\omega$. In fact, $|\hat{f}(\omega)|$ expresses the intensity of frequency $\omega$ and $\measuredangle \hat{f}(\omega)$ shows how the sinusoid of frequency $\omega$ needs to be displaced in time. Is this correct? Jul 31, 2021 at 21:56
• @S.H.W Yes. See this question and its answers for more details about the Fourier Transform.
– Peter K.
Jul 31, 2021 at 22:51
• @S.H.W It's actually a lot simpler than this. The FT is simply one of the many ways you can express a function as being made up of its "building blocks". The most convenient building blocks form an orthonormal basis which the FT is (sort of). It simply says: any function of time can be expressed as a sum/integral of complex exponentials with different weights and phases. Aug 1, 2021 at 1:46
• @PeterK. Thanks for the helpful link. Aug 1, 2021 at 6:53
• @Hilmar I appreciate your help. Thanks. Aug 1, 2021 at 6:55