13
votes
Accepted
Bandwidth of an entire song
First of all, kudos to you: I appreciate the effort and thinking you've managed to articulate in your question.
The DFT is a mathematical tool. As such, the parameters used to compute it can hide or ...
9
votes
Accepted
Why doesnt DFT Padding cause sinc like features
The OP is showing very good insight in all the comments stated. A product in the time domain with a rectangular pulse is convolution in the frequency domain with a Sinc. In fact zero padding in time ...
9
votes
Accepted
Why zero-pad at the end of a signal?
What differences does it make?
In one line - The phase information of the Fourier transform changes.
Explanation:
Adding zeros at the start of the signal translates to adding delay.
Consider the ...
7
votes
How Best to Characterise a Window Function
An oldie but a goodie it fred harris's "On the Use of Windows for Harmonic Analysis with the Discrete Fourier Transform". It has a nice table showing different figures of merit for different ...
7
votes
Accepted
FFT: Sinewave frequency displacement when zero-padding
(I show only positive frequencies):
which is part of the problem here :-)
You would get the expected behavior if you used a complex sine, i.e. $x[n] = e^{j2\pi\frac{n}{N}}$ but a sine wave actually ...
5
votes
Accepted
Why are my frequency bins oscillating?
This is indeed spectral leakage and specifically the dependency of the leakage on phase. Here is an example of 30 Hz sine with with a random phase. These are 50 frames with a randomized phase.
The &...
5
votes
Question about zero padding example in Lyons book on Understanding DSP
@gschro, I understand your puzzlement. Find the equation for computing a DTFT, in a textbook or on the Internet, and carefully examine it. In that equation $omega$ is a continuous frequency variable ...
5
votes
Accepted
Question about zero padding example in Lyons book on Understanding DSP
On the left side of Figure 3-21(a) the discrete 16-sample input sequence is represented by the dots. (The lightly-shaded sinusoidal curve is shown for reference only!)
On the right side of Figure 3-21(...
4
votes
Discrete Fourier Transform of the Gaussian
The (continuous-domain) FT of a Gaussian is a Gaussian, as OP knows. To get the DFT pair from a FT pair we need to sample and crop the time domain, which is equivalent to replicating and sampling the ...
4
votes
Why are my frequency bins oscillating?
The idea that you're looking for here is spectral leakage. As alluded to in the comments, the DFT bins will undergo different amounts of spectral leakage depending on the initial phase of the tone ...
4
votes
Why doesnt DFT Padding cause sinc like features
@George kirby. I suggest you discard that notion of "multiplying a step function on top of the original signal to form a longer time sequence". I believe such a multiplication is not ...
4
votes
Why does the frequency sampling method for FIR filter design operate in this manner?
This is how I would define the frequency-sampling method.
Assuming linear phase (to start with).
Draw out your desired frequency response magnitude, with as much detail as you need to to define the ...
4
votes
Why does the frequency sampling method for FIR filter design operate in this manner?
This answer shows one way of understanding why and how frequency sampling works. Let's assume you're given a desired complex frequency response $H(\omega)$ on the interval $\omega\in[0,\pi]$, where $\...
4
votes
Accepted
IFFT return complex values in Matlab
Just repeating what the comments say: The residual imaginary part of the impulse response is simply numerical noise. Matlab uses double precision floating point which has finite precicions
As simple ...
4
votes
Why zero-pad at the end of a signal?
The frequency resolution in the context of the DFT is indeed dependent on the length of the signal in the time domain, not merely the size of the DFT. Here’s a more detailed explanation:
Frequency ...
4
votes
Accepted
How can we tell a sinusoid existing in a time series data is cosine by just looking at DFT?
The DFT is showing you the results extending from DC to very nearly $f_s$ where $f_s$ is the sampling rate. This is equivalently the spectrum going from $-f_s/2$ to $+f_s/2$ if you take the 2nd half ...
3
votes
Accepted
Discrete Fourier Transform of the Gaussian
I'm not sure that
the DFT of the Gaussian is the Gaussian
is correct.
As Cris says:
The Gaussian is almost, but not quite exactly, band-limited, so sampling it will not produce an exact Gaussian in ...
3
votes
Signal power depending on FFT bin size
The PSD doesn't change – the D stands for Density, i.e. "how much power is there per bandwidth), and with an increased DFT length, there's less bandwidth per bin.
3
votes
Accepted
Why dft sine plot is so strange
There are two things you can try, depending on what you're aiming for.
If you want to see a sharp peak at frequency $\omega = 1$, as in the code in your question, then you need to increase the DFT ...
3
votes
What is the difference between the DFS (Discrete Fourier Series) and DTFS (Discrete-Time Fourier Series)
That's primarily due to inconsistent naming.
Typically the term "Discrete Time Fourier Transform" (DTFT) is used for signals that are discrete in time but continuous in Frequency, which is ...
3
votes
Accepted
Show that the similarity between a signal at an analysis frequency with a phase offset with a reference signal is $\frac{N}{2}\text{cos}(\phi)$
Your result is correct, and the final expression is obtained as follows:
$$
\frac12\sum_{n=0}^{N-1}\left[\cos\left(4\pi \frac{m}{N}n+\phi\right)+\cos\phi\right] =\\\qquad\qquad\frac12\sum_{n=0}^{N-1}\...
3
votes
How signal generation affect its spectrum
The primary issue is not having enough interpolated samples in the DFT to properly estimate the desired Discrete Time Fourier Transform (DTFT) as a continuous function in the frequency domain. The ...
3
votes
Accepted
Differences in PSD for windowed vs non-windowed spectra
The equivalent noise bandwidth (ENBW) for a given window $w[n]$ is the reciprocal of the window's processing gain and given as:
$$ENBW_{bins} = N\frac{\sum(w[n])^2}{(\sum w[n])^2} \tag{1} \label{1}$$
...
3
votes
Accepted
Why does the frequency sampling method for FIR filter design operate in this manner?
Explanation:
The impulse response and frequency response of a filter are Fourier Transform pairs.
The time domain response of a filter is its impulse response: you put an impulse at the input of the ...
3
votes
Getting the magnitude and phase of a single specific frequency from an audio signal
You can simply use the DTFT
$$ X(\omega) = \sum_{n= -\infty}^{+\infty}x[n]e^{-j\omega n} $$
for any frequency you want.
The summation limits can be a bit tricky. In practice you can't sum from $ -\...
3
votes
Why is reconstruction of window function from its DFT difficult/noisy when the sidelobes of DFT are higher?
I think you are maybe misunderstanding how the "beamforming DFT" is actually computed. The beamforming equation you reference is
\begin{equation}
X[\theta] = \sum_{n=0}^{N-1}x[n]e^{j\frac{2\...
3
votes
Accepted
Mathematically, why is there a tradeoff between main lobe width and sidelobe level when we apply a window?
There are two main mathematical principles to keep in mind when dealing with this tradeoff: the uncertainty principle (specifically the Gabor limit) and the Gibbs phenomenon.
The uncertainty principle ...
3
votes
Accepted
Frequency resolution in STFT
The $N$ defining the full signal length is not the same as the $N$ in the STFT equation, which defines the DFT length.
The STFT is a sliding DFT so the only value that matters is the latter.
Without ...
2
votes
Why do DFT frequency buckets need to be divided by sample period?
I might be late to this question but the problem with frequency bins isn't about normalization. After your FFT, each frequency bin is calculated as
$$ f_k = \frac{k}{N} \cdot f_\mathrm{s} $$
where $f_\...
2
votes
Accepted
Correcting noise floor of DFT sampled signal
This type of plot is kind of tricky.
The problem here is that DFT is a metric of spectral density. If you have a signal with a total energy of $E$, the spectral density is
$$\frac{\partial E}{\partial ...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
dft × 1124fft × 414
fourier-transform × 264
discrete-signals × 184
matlab × 91
frequency-spectrum × 90
image-processing × 72
convolution × 64
signal-analysis × 57
sampling × 54
filters × 48
python × 45
frequency × 44
frequency-domain × 41
dtft × 38
phase × 37
window-functions × 34
zero-padding × 33
fourier × 32
power-spectral-density × 28
stft × 26
interpolation × 25
dct × 25
audio × 24
homework × 21