dask 2021.10.0

ParametersReturnsBackRef
fftfreq(n, d=1.0, chunks='auto')

This docstring was copied from numpy.fft.fftfreq.

Some inconsistencies with the Dask version may exist.

The returned float array f contains the frequency bin centers in cycles per unit of the sample spacing (with zero at the start). For instance, if the sample spacing is in seconds, then the frequency unit is cycles/second.

Given a window length n and a sample spacing d:

f = [0, 1, ...,   n/2-1,     -n/2, ..., -1] / (d*n)   if n is even
f = [0, 1, ..., (n-1)/2, -(n-1)/2, ..., -1] / (d*n)   if n is odd

Parameters

n : int

Window length.

d : scalar, optional

Sample spacing (inverse of the sampling rate). Defaults to 1.

Returns

f : ndarray

Array of length n containing the sample frequencies.

Return the Discrete Fourier Transform sample frequencies.

Examples

This example is valid syntax, but we were not able to check execution
>>> signal = np.array([-2, 8, 6, 4, 1, 0, 3, 5], dtype=float)  # doctest: +SKIP
... fourier = np.fft.fft(signal) # doctest: +SKIP
... n = signal.size # doctest: +SKIP
... timestep = 0.1 # doctest: +SKIP
... freq = np.fft.fftfreq(n, d=timestep) # doctest: +SKIP
... freq # doctest: +SKIP array([ 0. , 1.25, 2.5 , ..., -3.75, -2.5 , -1.25])
See :

Back References

The following pages refer to to this document either explicitly or contain code examples using this.

dask.array.fft.rfftfreq

Local connectivity graph

Hover to see nodes names; edges to Self not shown, Caped at 50 nodes.

Using a canvas is more power efficient and can get hundred of nodes ; but does not allow hyperlinks; , arrows or text (beyond on hover)

SVG is more flexible but power hungry; and does not scale well to 50 + nodes.

All aboves nodes referred to, (or are referred from) current nodes; Edges from Self to other have been omitted (or all nodes would be connected to the central node "self" which is not useful). Nodes are colored by the library they belong to, and scaled with the number of references pointing them


File: /dask/array/fft.py#241
type: <class 'function'>
Commit: