numpy.fft.irfftn(a, s=None, axes=None, norm=None)
[source]
Compute the inverse of the N-dimensional FFT of real input.
This function computes the inverse of the N-dimensional discrete Fourier Transform for real input over any number of axes in an M-dimensional array by means of the Fast Fourier Transform (FFT). In other words, irfftn(rfftn(a), a.shape) == a
to within numerical accuracy. (The a.shape
is necessary like len(a)
is for irfft
, and for the same reason.)
The input should be ordered in the same way as is returned by rfftn
, i.e. as for irfft
for the final transformation axis, and as for ifftn
along all the other axes.
Parameters: |
a : array_like Input array. s : sequence of ints, optional Shape (length of each transformed axis) of the output ( axes : sequence of ints, optional Axes over which to compute the inverse FFT. If not given, the last norm : {None, “ortho”}, optional New in version 1.10.0. Normalization mode (see |
---|---|
Returns: |
out : ndarray The truncated or zero-padded input, transformed along the axes indicated by |
Raises: |
ValueError If IndexError If an element of |
See also
See fft
for definitions and conventions used.
See rfft
for definitions and conventions used for real input.
>>> a = np.zeros((3, 2, 2)) >>> a[0, 0, 0] = 3 * 2 * 2 >>> np.fft.irfftn(a) array([[[ 1., 1.], [ 1., 1.]], [[ 1., 1.], [ 1., 1.]], [[ 1., 1.], [ 1., 1.]]])
© 2008–2017 NumPy Developers
Licensed under the NumPy License.
https://docs.scipy.org/doc/numpy-1.14.2/reference/generated/numpy.fft.irfftn.html