A time domain signal can be decomposed into sinusoids which are based on basis functions.

For a N sampled input, a cosine basis function is defined as:

$$C_k[i] = \cos\left[\dfrac{2\pi k i}{N}\right]$$

Range of Frequency $k = 0 \ldots \frac{N}{2}$, Range of $i = 0 \ldots N-1$

Why is the sinusoid angle divided by $N$?


1 Answer 1


This normalises the frequency such that the period of the first cosine is N samples. Then all subsequent cosines are N/2 samples, N/3 samples.... all the way to N/(N/2) = 2 samples, at the Nyqust limit where k = N/2. If you want the full DFT, including negative frequencies, k should range from 0 to N-1.

  • $\begingroup$ I am pretty sure your answer is technically correct and have accepted it, but for a layman like me, the explanation needs to be dumbed down. At the moment, my textbook indicates that the k in the equation is K cycles over N samples. Assuming this signal was sampled at a frequency fs, this leads to K cycles over time N.ts. So my fundamental question now is why are these equations missing the sampling frequency aspect? I expect the denominator to contain ts. Its absence simply does not seem intuitive. Please clarify. $\endgroup$
    – Raj
    Jul 29, 2015 at 2:35
  • $\begingroup$ Hi Raj. So the sampling period is implicit in a sampled signal. Simply, if one of the cosines has a period of 1 sample, its frequency is equal to fs; this would occur when $ k = N $. In your example, bin $ k = N/2 $ will always equal nyquist: $ fs/2 $, because the period of the sinusoid is 2 samples. This is the definition of the Nyquist frequency is a baseband signal. The normalisation of the frequency removes dependence on the sampling frequency. Hope that helps. As someone who needs to understand things intuitively as well as mathematically, it took me a while to get my head around this $\endgroup$ Jul 29, 2015 at 8:12
  • $\begingroup$ Thanks KipperToffee. Its clear now. What I figured out is the following. In order to know what frequencies exist in a signal whose bandwidth is known, it is usually enough to crosscorrelate sinusoid of frequencies from DC to the highest frequency existing in the baseband. If the sampling frequency is known, the highest baseband frequency is half of the sampling frequency [Nyquist]. When a mere sequence of numbers is provided, there is no information on sampling frequency. So no guesses on the real frequencies of sinusoids for crosscorrelation can be made. Normalization helps here. $\endgroup$
    – Raj
    Jul 31, 2015 at 3:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.