Afia Nyarko <nyarkoafia2910@...>
Hi all,Can anyone help me with this? I keep getting different answers. What is the interval between the spectral components in an FFT spectrum if the sampling rate is 44100 Hz and the window is 12 ms long? If the window is 120 ms long? If the window contains 4096 samples?
Afia


W dniu 23.03.2023 o 05:26, Afia Nyarko
pisze:
Hi all,
Can anyone help me with this? I
keep getting different answers.
What is the interval between the spectral
components in an FFT spectrum if the sampling rate is 44100
Hz and the window is 12 ms long? If the window is 120 ms
long? If the window contains 4096 samples?
Afia
If sampling frequency of your signal is 44100 Hz, then window
length for 4096 samples of this signal is 0.09287979 s (1 / 44100
Hz * 4096 samples) So, it is neither 12 ms, nor 120 ms. Using FFT
(option "Fast" checked) to calculate spectrum of 4096 samples
produces bin width of 1.0009765625 Hz (44100 / 4096). If you take
12 ms of signal sampled @ 44100 Hz, you obtain 529,2 samples. For
spectrum calculation with option "Fast" set (using FFT instead of
DFT), you obtain spectrum calculated for 1024 samples (the closest
higher power of two for 529 samples is 1024). Bin width for 1024
samples signal @ 44100 Hz sampling frequency is 43,06640625 Hz. By
analogy, bin width for signal of 120 ms long (using FFT) will be
44100 Hz / 65536 samples which gives 0.6729125977 Hz.
Best, Bogdan.


Afia Nyarko <nyarkoafia2910@...>
Thank you so much Bogdan.
toggle quoted message
Show quoted text
W dniu 23.03.2023 o 05:26, Afia Nyarko
pisze:
Hi all,
Can anyone help me with this? I
keep getting different answers.
What is the interval between the spectral
components in an FFT spectrum if the sampling rate is 44100
Hz and the window is 12 ms long? If the window is 120 ms
long? If the window contains 4096 samples?
Afia
If sampling frequency of your signal is 44100 Hz, then window
length for 4096 samples of this signal is 0.09287979 s (1 / 44100
Hz * 4096 samples) So, it is neither 12 ms, nor 120 ms. Using FFT
(option "Fast" checked) to calculate spectrum of 4096 samples
produces bin width of 1.0009765625 Hz (44100 / 4096). If you take
12 ms of signal sampled @ 44100 Hz, you obtain 529,2 samples. For
spectrum calculation with option "Fast" set (using FFT instead of
DFT), you obtain spectrum calculated for 1024 samples (the closest
higher power of two for 529 samples is 1024). Bin width for 1024
samples signal @ 44100 Hz sampling frequency is 43,06640625 Hz. By
analogy, bin width for signal of 120 ms long (using FFT) will be
44100 Hz / 65536 samples which gives 0.6729125977 Hz.
Best, Bogdan.


The bin width for a window of 120 ms will be 44100 Hz / 8192 = 5.38330078125 Hz.
That's all done with FFT ("fast"), which is fast implementation of the DFT. With "fast" switched off, you'll get a slow implementation of the DFT, with a predictable bin width of 83.3648393194707 Hz and 8.333333333333334 Hz, for 12 and 120 ms, respectively.
This is always close to 1 divided by the duration, independently of the sampling frequency. This works perfectly for 120 ms (1/0.120 = 8.333333333333334 Hz), but for 12 ms we have to round the duration of the window to 529 samples, so you get 1/0.012 * 529.2/529
Hz for the bin width.
On 27 Mar 2023, at 09:49, Bogdan Rozborski via groups.io <b.rozborski@...> wrote:
W dniu 23.03.2023 o 05:26, Afia Nyarko pisze:
Hi all,
Can anyone help me with this? I keep getting different answers.
What is the interval between the spectral components in an FFT spectrum if the sampling rate is 44100 Hz and the window is 12 ms long? If the window is 120 ms long? If the window
contains 4096 samples?
Afia
If sampling frequency of your signal is 44100 Hz, then window length for 4096 samples of this signal is 0.09287979 s (1 / 44100 Hz * 4096 samples) So, it is neither 12 ms, nor 120 ms. Using FFT (option "Fast" checked) to calculate spectrum of 4096 samples
produces bin width of 1.0009765625 Hz (44100 / 4096). If you take 12 ms of signal sampled @ 44100 Hz, you obtain 529,2 samples. For spectrum calculation with option "Fast" set (using FFT instead of DFT), you obtain spectrum calculated for 1024 samples (the
closest higher power of two for 529 samples is 1024). Bin width for 1024 samples signal @ 44100 Hz sampling frequency is 43,06640625 Hz. By analogy, bin width for signal of 120 ms long (using FFT) will be 44100 Hz / 65536 samples which gives 0.6729125977 Hz.
Best, Bogdan.
_____
Paul Boersma
Professor of Phonetic Sciences
University of Amsterdam
Spuistraat 134, room 632
1012VB Amsterdam, The Netherlands
http://www.fon.hum.uva.nl/paul/


W dniu 27.03.2023 o 19:27, Boersma Paul
via groups.io pisze:
The bin width for a window of 120 ms will be 44100 Hz / 8192
= 5.38330078125 Hz.
That's all done with FFT ("fast"), which is fast
implementation of the DFT. With "fast" switched off, you'll get
a slow implementation of the DFT, with a predictable bin width
of 83.3648393194707 Hz and 8.333333333333334 Hz, for 12 and 120
ms, respectively. This is always close to 1 divided by the
duration, independently of the sampling frequency. This works
perfectly for 120 ms (1/0.120 = 8.333333333333334 Hz), but for
12 ms we have to round the duration of the window to 529
samples, so you get 1/0.012 * 529.2/529 Hz for the bin width.
W dniu 23.03.2023 o 05:26,
Afia Nyarko pisze:
Hi all,
Can anyone help me with
this? I keep getting different answers.
What is the interval
between the spectral components in an FFT
spectrum if the sampling rate is 44100 Hz and
the window is 12 ms long? If the window is 120
ms long? If the window contains 4096 samples?
Afia
If sampling frequency of your signal is 44100 Hz,
then window length for 4096 samples of this signal is
0.09287979 s (1 / 44100 Hz * 4096 samples) So, it is
neither 12 ms, nor 120 ms. Using FFT (option "Fast"
checked) to calculate spectrum of 4096 samples
produces bin width of 1.0009765625 Hz (44100 / 4096).
If you take 12 ms of signal sampled @ 44100 Hz, you
obtain 529,2 samples. For spectrum calculation with
option "Fast" set (using FFT instead of DFT), you
obtain spectrum calculated for 1024 samples (the
closest higher power of two for 529 samples is 1024).
Bin width for 1024 samples signal @ 44100 Hz sampling
frequency is 43,06640625 Hz. By analogy, bin width for
signal of 120 ms long (using FFT) will be 44100 Hz /
65536 samples which gives 0.6729125977 Hz.
Best, Bogdan.
_____
Paul Boersma
Professor of
Phonetic Sciences
Ups, FFT length for 120 ms signal @ 44100 Hz sampling frequency
is 8192 not 65536!


Afia Nyarko <nyarkoafia2910@...>
Thank you all but I am wondering why everyone is getting different answers?
toggle quoted message
Show quoted text
W dniu 27.03.2023 o 19:27, Boersma Paul
via groups.io pisze:
The bin width for a window of 120 ms will be 44100 Hz / 8192
= 5.38330078125 Hz.
That's all done with FFT ("fast"), which is fast
implementation of the DFT. With "fast" switched off, you'll get
a slow implementation of the DFT, with a predictable bin width
of 83.3648393194707 Hz and 8.333333333333334 Hz, for 12 and 120
ms, respectively. This is always close to 1 divided by the
duration, independently of the sampling frequency. This works
perfectly for 120 ms (1/0.120 = 8.333333333333334 Hz), but for
12 ms we have to round the duration of the window to 529
samples, so you get 1/0.012 * 529.2/529 Hz for the bin width.
W dniu 23.03.2023 o 05:26,
Afia Nyarko pisze:
Hi all,
Can anyone help me with
this? I keep getting different answers.
What is the interval
between the spectral components in an FFT
spectrum if the sampling rate is 44100 Hz and
the window is 12 ms long? If the window is 120
ms long? If the window contains 4096 samples?
Afia
If sampling frequency of your signal is 44100 Hz,
then window length for 4096 samples of this signal is
0.09287979 s (1 / 44100 Hz * 4096 samples) So, it is
neither 12 ms, nor 120 ms. Using FFT (option "Fast"
checked) to calculate spectrum of 4096 samples
produces bin width of 1.0009765625 Hz (44100 / 4096).
If you take 12 ms of signal sampled @ 44100 Hz, you
obtain 529,2 samples. For spectrum calculation with
option "Fast" set (using FFT instead of DFT), you
obtain spectrum calculated for 1024 samples (the
closest higher power of two for 529 samples is 1024).
Bin width for 1024 samples signal @ 44100 Hz sampling
frequency is 43,06640625 Hz. By analogy, bin width for
signal of 120 ms long (using FFT) will be 44100 Hz /
65536 samples which gives 0.6729125977 Hz.
Best, Bogdan.
_____
Paul Boersma
Professor of
Phonetic Sciences
Ups, FFT length for 120 ms signal @ 44100 Hz sampling frequency
is 8192 not 65536!


All gave the same answered – only Bogdan grabbed once a wrong value… Paul has the most detailed answer.
toggle quoted message
Show quoted text
On 27 Mar 2023, at 23:31, Afia Nyarko <nyarkoafia2910@...> wrote:
Thank you all but I am wondering why everyone is getting different answers?
W dniu 27.03.2023 o 19:27, Boersma Paul
via groups.io pisze:
The bin width for a window of 120 ms will be 44100 Hz / 8192
= 5.38330078125 Hz.
That's all done with FFT ("fast"), which is fast
implementation of the DFT. With "fast" switched off, you'll get
a slow implementation of the DFT, with a predictable bin width
of 83.3648393194707 Hz and 8.333333333333334 Hz, for 12 and 120
ms, respectively. This is always close to 1 divided by the
duration, independently of the sampling frequency. This works
perfectly for 120 ms (1/0.120 = 8.333333333333334 Hz), but for
12 ms we have to round the duration of the window to 529
samples, so you get 1/0.012 * 529.2/529 Hz for the bin width.
W dniu 23.03.2023 o 05:26,
Afia Nyarko pisze:
Hi all,
Can anyone help me with
this? I keep getting different answers.
What is the interval
between the spectral components in an FFT
spectrum if the sampling rate is 44100 Hz and
the window is 12 ms long? If the window is 120
ms long? If the window contains 4096 samples?
Afia
If sampling frequency of your signal is 44100 Hz,
then window length for 4096 samples of this signal is
0.09287979 s (1 / 44100 Hz * 4096 samples) So, it is
neither 12 ms, nor 120 ms. Using FFT (option "Fast"
checked) to calculate spectrum of 4096 samples
produces bin width of 1.0009765625 Hz (44100 / 4096).
If you take 12 ms of signal sampled @ 44100 Hz, you
obtain 529,2 samples. For spectrum calculation with
option "Fast" set (using FFT instead of DFT), you
obtain spectrum calculated for 1024 samples (the
closest higher power of two for 529 samples is 1024).
Bin width for 1024 samples signal @ 44100 Hz sampling
frequency is 43,06640625 Hz. By analogy, bin width for
signal of 120 ms long (using FFT) will be 44100 Hz /
65536 samples which gives 0.6729125977 Hz.
Best, Bogdan.
_____
Paul Boersma
Professor of
Phonetic Sciences
Ups, FFT length for 120 ms signal @ 44100 Hz sampling frequency
is 8192 not 65536!


W dniu 28.03.2023 o 00:31, Afia Nyarko
pisze:
Thank you all but I am wondering why everyone is
getting different answers?
W dniu 27.03.2023 o 19:27, Boersma Paul via groups.io pisze:
The bin width for a window of 120
ms will be 44100 Hz / 8192 = 5.38330078125 Hz.
That's all done with FFT ("fast"), which is fast
implementation of the DFT. With "fast" switched off,
you'll get a slow implementation of the DFT, with a
predictable bin width of 83.3648393194707 Hz
and 8.333333333333334 Hz, for 12 and 120 ms,
respectively. This is always close to 1 divided by the
duration, independently of the sampling frequency.
This works perfectly for 120 ms (1/0.120
= 8.333333333333334 Hz), but for 12 ms we have to
round the duration of the window to 529 samples, so
you get 1/0.012 * 529.2/529 Hz for the bin width.
W dniu 23.03.2023 o 05:26, Afia Nyarko
pisze:
Hi all,
Can anyone help me with this? I
keep getting different answers.
What is the interval between
the spectral components in an FFT
spectrum if the sampling rate is 44100
Hz and the window is 12 ms long? If
the window is 120 ms long? If the
window contains 4096 samples?
Afia
If sampling frequency of your signal is
44100 Hz, then window length for 4096
samples of this signal is 0.09287979 s (1 /
44100 Hz * 4096 samples) So, it is neither
12 ms, nor 120 ms. Using FFT (option "Fast"
checked) to calculate spectrum of 4096
samples produces bin width of 1.0009765625
Hz (44100 / 4096). If you take 12 ms of
signal sampled @ 44100 Hz, you obtain 529,2
samples. For spectrum calculation with
option "Fast" set (using FFT instead of
DFT), you obtain spectrum calculated for
1024 samples (the closest higher power of
two for 529 samples is 1024). Bin width for
1024 samples signal @ 44100 Hz sampling
frequency is 43,06640625 Hz. By analogy, bin
width for signal of 120 ms long (using FFT)
will be 44100 Hz / 65536 samples which gives
0.6729125977 Hz.
Best, Bogdan.
_____
Paul Boersma
Professor of Phonetic
Sciences
Ups, FFT length for 120 ms signal @ 44100 Hz sampling
frequency is 8192 not 65536!
It all depends whether you use FFT or DFT algorithm. I calculated
bin width for "fast" option using an FFT algorithm. Paul also
included calculations for DFT ("slower" option). \
Bogdan.

