Questions tagged [fftw]

FFTW, "The Fastest Fourier Transform in The West", is a C library which implements discrete Fourier Transforms. It is licensed under the GNU GPL.

FFTW homepage: http://www.fftw.org/
FAQ: http://www.fftw.org/faq/

883 questions
10
votes
1 answer

WAV-file analysis C (libsndfile, fftw3)

I'm trying to develop a simple C application that can give a value from 0-100 at a certain frequency range at a given timestamp in a WAV-file. Example: I have frequency range of 44.1kHz (typical MP3 file) and I want to split that range into n amount…
9
votes
6 answers

Implement Hann Window

I take blocks of incoming data and pass them through fftw to get some spectral information. Everything seems to be working, however I think I'm getting some aliasing issues. I've been trying to work out how to implement a hann window on my blocks of…
Tim
  • 7,746
  • 3
  • 49
  • 83
9
votes
1 answer

FFTW real-to-real transform strided array

I have a matrix stored in row-major order. I am trying to compute the DCT of a ub-matrix using FFTW, and I get nonsense. In the following paragraphs I will describe the problem and my solution, and I would like your help in understanding why it does…
Alex Shtoff
  • 2,520
  • 1
  • 25
  • 53
8
votes
3 answers

Forward FFT an image and backward FFT an image to get the same result

I am trying to FFT an image using the library from http://www.fftw.org/ so that I can do a convolution in the frequency domain. But I can't figure out how to make it work. To understand how to do this I am trying to forward FFT an image as an array…
Steffen
  • 155
  • 2
  • 6
8
votes
3 answers

Calling FFTW's in-place real-to-complex transform without violating strict aliasing rules

I wish to call fftw's in-place real-to-complex transform function, which has the following signature: fftw_plan fftw_plan_dft_r2c_1d( int n, // transform length double* in, // pointer to input array fftw_complex* out,…
SumDood
  • 294
  • 1
  • 7
8
votes
1 answer

How to visualize FFT of a signal in Julia?

I'm trying to visualize a signal and its frequency spectrum in Julia. I found the FFTW package that provides the FFT and DSP for the frequencies. Here is what I'm trying, with a sinusoidal signal: using Plots using FFTW using DSP # Number of…
Heitor
  • 339
  • 1
  • 3
  • 11
8
votes
2 answers

FFTW: signal consists of noise after IFFT

After doing FFT and IFFT I can hear only noise in my headphones... Here is the code: double* spectrum = new double[n]; fftw_plan plan; plan = fftw_plan_r2r_1d(n, data, spectrum, FFTW_REDFT10, FFTW_ESTIMATE); …
Kirill Dubovikov
  • 1,457
  • 2
  • 21
  • 41
8
votes
1 answer

configure: WARNING: FFTW3F library not found. The slower FFTPACK library will be used instead

I'm compiling octave on my LFS - Linux from scratch - system. While configuring octave, I receive a warning: configure: WARNING: FFTW3F library not found. The slower FFTPACK library will be used instead. I compiled and installed FFTW 3.3.4, and…
Megidd
  • 7,089
  • 6
  • 65
  • 142
8
votes
2 answers

unable to link to fftw3 library

I am compiling a test program to test the fftw3 (ver3.3.4). Since it is not installed with root previlidge the command I used is: gcc -lm -L/home/my_name/opt/fftw-3.3.4/lib/ -I/home/my_name/opt/fftw-3.3.4/include/ fftwtest.c where the library is…
robinchm
  • 109
  • 1
  • 1
  • 7
8
votes
2 answers

FFTW vs. OpenCV cvDFT

Can I expect a speedup when using FFTW (http://www.fftw.org/) instead of OpenCV's cvDFT (http://goo.gl/YCHj0)? My program's runtime is heavily determined by the application of inverse and forward DFT and I am thinking about using FFTW instead of…
7
votes
2 answers

Evaluating the fast Fourier transform of Gaussian function in FORTRAN using FFTW3 library

I am trying to write a FORTRAN code to evaluate the fast Fourier transform of the Gaussian function f(r)=exp(-(r^2)) using FFTW3 library. As everyone knows, the Fourier transform of the Gaussian function is another Gaussian function. I consider…
7
votes
3 answers

Accelerating FFTW pruning to avoid massive zero padding

Suppose that I have a sequence x(n) which is K * N long and that only the first N elements are different from zero. I'm assuming that N << K, say, for example, N = 10 and K = 100000. I want to calculate the FFT, by FFTW, of such a sequence. This is…
Vitality
  • 20,705
  • 4
  • 108
  • 146
7
votes
1 answer

FFTW plan creation using OpenMP

I am trying to perform several FFT's in parallel. I am using FFTW and OpenMP. Each FFT is different, so I'm not relying on FFTW's build-in multithreading (which I know uses OpenMP). int m; // assume: // int numberOfColumns = 100; // int…
tir38
  • 9,810
  • 10
  • 64
  • 107
7
votes
2 answers

Transforming Audio Samples From Time Domain to Frequency Domain

as a software engineer I am facing with some difficulties while working on a signal processing problem. I don't have much experience in this area. What I try to do is to sample the environmental sound with 44100 sampling rate and for fixed size…
vaha
  • 299
  • 5
  • 12
6
votes
1 answer

1D Heat Equation using DFT produces incorrect results (FFTW)

I am trying to solve the 1D heat equation using a complex to complex IDFT. The problem is that the output after a single timestep does not seem to be correct. I have included a simple example below to illustrate the problem. I initialize the…
Naemesis
  • 139
  • 5
1
2
3
58 59