We’re rewarding the question askers & reputations are being recalculated! Read more.

Questions tagged [fft]

The fast Fourier transform is an efficient algorithm to compute the discrete Fourier transform (DFT) and its inverse.

Filter by
Sorted by
Tagged with
13
votes
7answers
5k views

Is there an algorithm to compute the phase for a single frequecy?

If you have a function $f(t)=A \cdot \sin(\omega t+\phi)$, and reference sin wave $\sin(\omega x)$ what would be a fast algorithm to compute $\phi$? I was looking at Goertzel algorithm, but it doesn'...
1
vote
2answers
135 views

Interpolation of estimated frequency between fft bins: what about phase?

I am developing an additive re-synthesier, which involves identifying partials from FFT frames. Partial identification requires amplitude peaks. The simplest way to do this is to just look at the ...
1
vote
1answer
39 views

Is it possible to find precise peak frequency using FFT phase shifts?

Been experimenting with FFT on a generated sinusoid and found something strange that doesn't seem to be described anywhere (though I may be missing something of course). A sinusoid that exactly ...
0
votes
1answer
6 views

Sparse-NMF using NNDSVD to initialize W and H: negative values in first column/row

When NNDSVD is used for initializing W and H for NMF, the first column of W and first row of H are set to: $W(:,1)= \sqrt{S(1)} \times U(:,1)$ and $H(1,:)= \sqrt{S(1)} \times V(:,1)^\top$ ...
2
votes
3answers
255 views

I don't understand harmonics, why do they happen?

I don't understand why harmonics occur in signals. So if I receive a time domain sinusoidal signal at 10 Hz and I perform the FFT of it, I will observe peaks at 10 Hz, 20 Hz, 30 Hz, and so on... with ...
0
votes
3answers
603 views

Frequency response of a (rectangular) integrator

A very simple question which can't really figure out: I have a simple discrete time rectangular integrator with Z transform H(z) = 1/(1-Z^(-1)) Plotting the frequency response with Matlab using ...
1
vote
1answer
34 views

solution on the time domain becomes “periodic” after the inverse fourier transform

I was trying to solve european option pricing problem using Conv method (introduced by Lord in 2008 https://pdfs.semanticscholar.org/0632/460bd50b2151f74ac40028df4cc60e73a884.pdf). The final step of ...
1
vote
1answer
42 views

Why does the FFT of a complex variable create negative frequencies?

So I have a demodulator that streams out X and Y values. I use a spectrum analyzer within this demodulator instrument which plots the |FFT(X+iY)| against the frequency domain, which shows up with ...
0
votes
2answers
191 views

Applying periodogram-based PSD

For plotting a Power Spectral Density graph based on FFT results, I had used two different approaches, but they produced very different results, and it'd be great if anyone knows why. Note: From this ...
0
votes
0answers
29 views

FFT frequency-magnitude not correct when a positive gain EQ point is applied

I have a measurement system, which applies a log sine sweep as stimulus to a DUT and records the return signal. I then extract the impulse response, and perform an FFT on this to examing phase and ...
0
votes
0answers
29 views

FFT first frequency

I have some problems understanding FFT. If I know Fourier analysis frame (1024 samples) and sample rate (48 000 Hz), how can I find the first frequency of harmonic sines and cosines?
0
votes
0answers
20 views

Is fundamental frequency information present in speech-shaped white noise?

I am using a so-called speech-shaped stationary white noise, which means so much as a white noise that has been filtered to match the long-term spectrum of a female speaker. The way it was generated ...
0
votes
1answer
232 views

Wavelet transform and FFT using to extract feature power bands with EEG signals

I am using 5 channels [ fz , cz , c3 , c4 , pz] to detect drowsiness of driver My First Question is, what is the right input to get feature power band ( Theta , alpha , gamma , beta ) to wavelet ...
0
votes
0answers
15 views

how to convert k-scale to frequency scale in FFT?

I have used fft(x) function in Matlab to perform Fast Fourier Transform on a given function and picture is the result. The graph you see is k, X(k). Now I am being asked to rescale frequency axis ...
0
votes
1answer
36 views

Correctly scaling FFT of different lengths

I have been looking at using two FFTs of different lengths and displaying the output magnitudes on the same graph (a shorter length window for the higher frequencies, and a longer one for lower ...
0
votes
0answers
16 views

Some confusion about calculating spectrogram

I am new to DSP and i have a question because it is not the same as theory. I need to get spectrogram of wav file and feed it to CNN. I have used scipy.signal to get spectrogram. I know spectrogram ...
0
votes
0answers
17 views

When is a signal non uniform and do I therefore have to use a non-uniform fft? [closed]

I have a signal, which should be periodic at 10 Hz. But sometimes it is 10.2 Hz, sometimes 9.8 Hz. Is there the assumption that the sample points are strictly periodic still a good assumption. I ask ...
0
votes
1answer
35 views

Why does an anti-symmetric function has zero amplitude at the center of an even length window

I am performing FFT on a real odd function and the resultant transform has zero amplitude in the last bin. Essentially if Y= rfft(X), then Y[-1] is always zero. I stumbled on this answer which says ...
0
votes
0answers
18 views

Transmitting image in certain spectrum without mirroring

I have a problem because I want to transmit string at certain frequency that is simple .png with 0 and 1. I simply take height and width of the image and scale it to the bandwidth and time. Then I ...
0
votes
0answers
32 views

How accurate is Python's FFT?

I am getting started with Python's FFT. I tested it on a signal that is a sum of three signals, two of which have an eigenfrequency of the grid, the third one does not (but due to large no. of data ...
0
votes
1answer
20 views

Peak to Average Power Ratio of an exponentially increasing signal

I am having an exponentially increasing sinusoidal signal. After sampling, I am dividing the signal into frames of length 128 and doing windowing operation with a hanning window of length 128. Then ...
5
votes
5answers
8k views

Fastest implementation of fft in C++?

I have a MATLAB program that uses fft and ifft a lot. Now I want to translate it to C++ for production. I used OpenCV but I ...
0
votes
0answers
31 views

Audio Activity Detection and Classification

I am starting a new project. Actually, my real intention is to learn speech recognition but for warming up I want to improve in audio signal processing. In my project, I aim to record sounds except ...
58
votes
8answers
92k views

How do I implement cross-correlation to prove two audio files are similar?

I have to do cross correlation of two audio file to prove they are similar. I have taken the FFT of the two audio files and have their power spectrum values in separate arrays. How should I proceed ...
0
votes
0answers
12 views

Multitaper F statistics

I'm having some problems interpreting the F-statistics output from multitaper analysis. To illustrate, the following code-snip in R performs multitaper analysis on the same sine-frequency but with ...
0
votes
0answers
42 views

Simple and Efficient FFT C or C++ code for HLS implementation

I'm working on my project and it's related to speech processing. I have to implement parts of the project on an Intel FPGA board using Intel HLS Compiler that converts C code to RTL code for FPGA ...
0
votes
0answers
19 views

Scaling factor for comparing spectrums obtained via Continuous Fourier Transform and Discrete Fourier Transformation?

Essentially I am trying to calculate the Bremsstrahlung spectrum numerically for magnetized plasma and want to compare the resultant spectra with the standard textbook spectrum formula for ...
0
votes
0answers
30 views

Scaling x axis for FFTs in Python

I edited the post to be more specific, see below. I have a dataset, on which I need to perform and IFFT, cut the valueable part of it (by multiplying with a gaussian curve), then FFT back. First it's ...
0
votes
2answers
47 views

STFT window width vs. detectable Hz range

Assuming 44100 samples per second in a short 4-8 second-long audio .wav file, if I want perform FFT to detect the power spectrum, amplitude, and phase shift from 20 Hz to 10000 Hz (humans lose the ...
6
votes
1answer
230 views

Morphing between two FFTs

I'm a musician and I'm making a script that takes a wave file and snaps each of its frequencies from the fourier transforms to the nearest musical harmonic. Thanks to help from another question I ...
0
votes
1answer
60 views

Is it possible to reduce the complexity of radix-2 FFT if the input vector contains identical elements?

my question is about reducing the complexity of radix-2 FFT when the input vector has a specific structure. For an input vector of x with N elements, the complexity is given by O(N log2 N). My input ...
1
vote
1answer
31 views

FFT of white noise with different sampling rate

I have a question on how I should interpret the white noise power level (noise floor) obtain from FFT for different hardware sampling rates. I realized if I sample the same noise at different rates (...
0
votes
2answers
99 views

Overlapping in real time fourier transform?

I have an algorithm and I need to record audio and perform short time Fourier transform to obtain which frequency is the most common. I am using a Hanning window to try and reduce spectral leakage as ...
7
votes
5answers
2k views

Can someone help explain what this FFT workflow is doing to my signal, and why it works?

I am working with a piece of equipment that does acoustic analysis. It does this by acquiring a time domain signal and performing an FFT on it to extract the amplitude and phase at a single desired ...
0
votes
0answers
33 views

Scaling of the PWELCH function in MATLAB

I am trying to compute the power spectral density of a random signal using the PWELCH function in MATLAB. Since I think have not understood properly how Pwelch scales the PSD, I wrote a sample ...
1
vote
3answers
33 views

FFT error when number of samples growth - Matlab/octave

I see when I increase number of samples, the imaginary error part of the FFT growth due to the error of sin(n*pi)!=0 where n is the index of the sample in Matlab or octave. Is there anyway to force ...
0
votes
0answers
19 views

Angle bins for FFT DOA estimation

I have difficulties to calculate my angle bins. After doing a fft over N points over the antenna elements I get N bins. For getting the angle of each bin I do the following: f_bin = (2*pi)/N*n (n ...
0
votes
1answer
41 views

Understanding the FFT phase spectrum with a simple example

I'm trying to compute the DFT using scipy's functions. I don't understand why the phase spectrum of a simple sine wave with 2 Hz frequency doesn't show $\pm\pi/2$ at the $\pm 2Hz$ frequencies. Instead,...
1
vote
1answer
71 views

Real-time DAQ (Data AcQuisition) device and filtering of voltage signals in audio frequencies

I'm working on a frequency mixer project in which two analog voltage signals at two different frequencies (each <5 kHz) are considered. I'd like to add the two fundamental frequencies and return an ...
28
votes
3answers
29k views

Picking the correct filter for accelerometer data

I am fairly new to DSP, and have done some research on possible filters for smoothing accelerometer data in python. An example of the type of data Ill be experiencing can be seen in the following ...
0
votes
1answer
172 views

Threshold for peak detection of noisy signal in frequency domain

I have a noisy signal (Gaussian Noise) with a known SNR and known Noise variance. This signal contains a number of Frequency components. My ultimate objective is to detect the components of the signal....
0
votes
1answer
62 views

Silence removal from the audio

Suppose i've a mp3 file. I performed FFT of that mp3 file. Then is it good to state the following: 1. Silence occurs by that particular DFT point whose magnitude is lesser than some threshold. 2. ...
0
votes
1answer
79 views

number of samples and Amplitude accuracy,what's the solution to this problem

I'm colleceting data samples from a device (temporal signal) in order to analyze it with FFT function in MATLAB R2015b,first i get N=4063 data points with (delta_t=0.000015s) so my frequency ...
0
votes
1answer
73 views

Recovering a signal after filtering

A signal $x[n]$ is to be transmitted over a communication channel. The communication channel is described by an FIR filter of length $M$ such that the received signal is given by $$r[n]=\sum_{k=0}^...
3
votes
1answer
54 views

Square wave FFT results show frequency that seems too low?

I have created an open source plotting package for a low cost oscilloscope - see link here: GitHub Plotting Software But during my testing I have one result that may be wrong: a noisy 7 kHz square ...
0
votes
1answer
17 views

Getting non smooth spectrum after performing fft on numerically obtained acceleration data

I am trying to calculate the spectrum of Bremmstrahlung, which involves calculating the Fourier transformed acceleration. I am solving a non-linear ODE to numerically calculate the acceleration in the ...
0
votes
1answer
451 views

Decimation and filtering in the frequency domain

I'm working on a Software Defined Radio project where I'd like to low-pass filter and decimate an analytical signal (IQ) sampled at 96ksps. Let's say the low-pass filter has a cutoff at 5kHz and I'd ...
0
votes
0answers
14 views

how to calculate power spectrum of Gaussian noise from the known variance of it?

can someone explain me the following paragraph, i tried to understand it but i am not getting it exactly, Thank you ! Since you know the variance, you can predict the energy of the noise image, ∑x∑y|...
2
votes
3answers
3k views

Calculating 1/3 Octave Spectrum from FFT / DFT

I am not often on this forum and I am not an expert on the subject. I struggle with the theory of FFT / DFT and the 1/3 octave spectrum. Assume I have a DFT analysis of a given signal. It (the DFT ...
1
vote
2answers
78 views

Evaluate performance of FFT Windows

lately i've been interested in FFT windowing, i've experimented various windows in Matlab, that made me more curious: There are normalized parameters (CG, Scalloping loss etc...) for every window ...