pub fn ifftshift<F, D>(x: &Array<F, D>) -> FFTResult<Array<F, D>>
Expand description
Inverse of fftshift.
§Arguments
x
- Input array
§Returns
The inverse-shifted array with the zero-frequency component back to the beginning.
§Examples
use scirs2_fft::{fftshift, ifftshift};
use scirs2_core::ndarray::Array1;
let x = Array1::from_vec(vec![0.0, 1.0, 2.0, 3.0]);
let shifted = fftshift(&x).unwrap();
let unshifted = ifftshift(&shifted).unwrap();
assert_eq!(x, unshifted);