DFTI_UNIMPLEMENTED for 3D real-to-complex transform

DFTI_UNIMPLEMENTED for 3D real-to-complex transform

I'm trying to do a 3D real-to-complex DFT using the following code:

USE prec

INTEGER :: status, N(3), ISN
COMPLEX(q) :: C(*)
LOGICAL ::class_error

status = DftiCreateDescriptor &
(dfti_handle, &

if (status .ne. 0) then
error_message = DftiErrorMessage (status)
print*, 'DftiCreateDesriptor ', error_message

status = DftiCommitDescriptor (dfti_handle)
status = DftiComputeForward (dfti_handle, C)
status = DftiFreeDescriptor (dfti_handle)


The error message returned after the call to DftiCreateDescriptor is DFTI_UNIMPLEMENTED. In case it matters, the input grid is 4 x 4 x 4. I'm using MKL 7.0 beta (l_mkl_b1_7.0.007), the Intel 8.0 Fortran compiler, and Red Hat Linux 7.3.

Can you give an estimate of when the MKL DFTI will be able to do 3D real-to-complex transforms?


10 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.


1D real-to-complex transforms are currently supported and the plan is to implement 2D real-to-complex transforms for the MKL 7.0 gold release. I don't know whatcurrent plans there are to implement the 3D case.

Doesanyone else on the forum have need of a 3D real-to-complex DFT? What sort of applications are making use of these transforms?



Bad luck for me. Obviously, I think 3D real-to-complex DFT's are useful. The computational chemistry application that I'm tuning performs 3D real-to-complex transforms. I've also worked on molecular docking applications that perform Fourier correlation using real coordinates. Most of the scientific libraries that I've used have 3D real-to-complex DFT routines.


Perhaps bad luck and perhaps not. The development team is considering this request for support of 3D real-to-complex implementation.

And thanks for the further detail. Anyone else out there looking for 3D real-to-complex DFT routines?


I also need 3D real-to-complex FFT.
Am I correct that 3D real-to-complex FFT is not implemented
on MKL 6.1? I can create a descriptor and commit the descriptor, but the results are just garbage.

3D r2c is not implemented in 6.1. Unfortunately the software did not return the correct information.

This will be one of the next areas we give attention to.


Ooops, my bad. My MKL version is The descriptor is committed
alright without error messages, but I cannot make sense of the fft numbers.
I am just curious if there are known problems with 3D r2c DFT in mkl



I'm surprised that the call to DftiCreateDescriptor doesn't return DFTI_UNIMPLEMENTED for your 3D r2c.

Can you tell us something about your application? I'm just curious about other algorithms that do 3D r2c transforms.



Hi. I do micromagnetic simulations. A quick and easy way to calculate magnetostatic interactions involves using FFT (the equations for the magnetostatic fields are convolutions in real space). Since the quantities are all real it can potentially cut down on memory usage and CPU time by using real2complex FFT. I have implemented the fftw library - the 3D r2c fftw works fine in terms of memory reduction, but the best performance in speed I have obtained is many times slower (!) than using the c2c fft from mkl 6.1.1. This involved various trials using the threaded fftw library (very slow!) or the non-threaded fftw library. My final(?) fix in lieu of intel fixing the multi-dimensional r2c invloved a workaround with temporary storage in complex form to use the mkl c2c fft, then repacking only the independent elements in a real matrix, do the matrix multiplication and then carefully repack the result in a temporary complex array to do the back-transform. The performance in the end is about the same as using the c2c fft but memory usage is reduced (not by 50% but but about 30 - 40%).


Thanks for the explanation on your usage of the 3D real transform. Unfortunately we cannot in the short term be helpful to you. However, we have demand for this feature from several customers and realize the importance of completing this feature.


Leave a Comment

Please sign in to add a comment. Not a member? Join today