You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- ``s[i]`` is greater than the size of the input array along a corresponding axis (dimension) ``j``, the corresponding axis of the input array must be zero-padded such that the axis has size ``s[i]``.
92
-
- ``s[i]`` is less than the size of the input array along a corresponding axis (dimension) ``j``, the corresponding axis of the input array must be trimmed such that the axis has size``s[i]``.
91
+
- ``s[i]`` is greater than the size of the input array along a corresponding axis (dimension) ``i``, the corresponding axis of the input array must be zero-padded such that the axis has size ``s[i]``.
92
+
- ``s[i]`` is less than the size of the input array along a corresponding axis (dimension) ``i``, the corresponding axis of the input array must be trimmed such that the axis has size``s[i]``.
93
93
94
-
If ``axes`` is ``None``, the last ``len(s)`` axes must be transformed, and, thus, ``j`` represents an axis index computed according to ``N - len(s) + i``, where ``N`` is the number of axes (e.g., if ``N = 4`` and ``s = (256, 256)``, then ``i = 0`` corresponds to axis ``2`` and ``i = 1`` corresponds to axis ``3``, the last axis).
95
94
96
95
If ``axes`` is not ``None``, size ``s[i]`` corresponds to the size of axis ``axes[j]`` where ``i == j``.
97
96
98
97
If not provided, the size of each transformed axis (dimension) in the output array must equal the size of the corresponding axis in the input array.
99
98
100
99
Default: ``None``.
101
100
axes: Sequence[int]
102
-
axes (dimension) over which to compute the Fourier transform. If ``None`` and ``s`` is not specified, all axes must be transformed. If ``None`` and ``s`` is specified, the last ``len(s)`` axes must be transformed. Default: ``None``.
101
+
axes (dimension) over which to compute the Fourier transform. If ``None`` and ``s`` is not specified, all axes must be transformed. If ``s`` is specified, the corresponding ``axes`` to be transformed must be explicitly specified too. Default: ``None``.
103
102
norm: Literal['backward', 'ortho', 'forward']
104
103
normalization mode. Should be one of the following modes:
length of the transformed axis of the **output**. If
205
204
206
-
- ``n`` is greater than the length of the input array, the input array must be zero-padded such that the input array has length ``n``.
207
-
- ``n`` is less than the length of the input array, the input array must be trimmed to length ``n//2+1``.
205
+
- ``n//2+1`` is greater than the length of the input array, the input array must be zero-padded.
206
+
- ``n//2+1`` is less than the length of the input array, the input array must be trimmed.
208
207
209
208
If not provided, the length of the transformed axis of the output must equal the length ``2 * (m - 1)`` where ``m`` is the length of the input along the axis specified by ``axis``. Default: ``None``.
an array transformed along the axis (dimension) indicated by ``axis``. The returned array must have a real-valued floating-point data type determined by :ref:`type-promotion`.
367
+
an array transformed along the axis (dimension) indicated by ``axis``. The returned array must have a complex-valued floating-point data type determined by :ref:`type-promotion`.
Returns the discrete Fourier transform sample frequencies. For a Fourier transform of length ``n`` and length unit of ``d`` the frequencies are described as:
401
-
398
+
Returns the discrete Fourier transform sample frequencies (for ``rfft`` and ``irfft``).
399
+
400
+
For a Fourier transform of length ``n`` and length unit of ``d`` the frequencies are described as:
402
401
403
402
.. code-block::
404
403
405
-
f = [0, 1, ..., n/2-1, -n/2, ..., -1] / (d*n) if n is even
406
-
f = [0, 1, ..., (n-1)/2, -(n-1)/2, ..., -1] / (d*n) if n is odd
404
+
f = [0, 1, ..., n/2-1, n/2] / (d*n) # if n is even
405
+
f = [0, 1, ..., (n-1)/2-1, (n-1)/2] / (d*n) # if n is odd
407
406
408
407
The Nyquist frequency component is considered to be positive.
an array of length ``n`` containing the sample frequencies. The returned array must have a floating-point data type determined by :ref:`type-promotion`.
419
+
an array of length ``n//2+1`` containing the sample frequencies. The returned array must have a floating-point data type determined by :ref:`type-promotion`.
0 commit comments