Struct Autosort

Source
pub struct Autosort<T, Twiddles, Work> { /* private fields */ }
Expand description

Implements a mixed-radix Stockham autosort algorithm for multiples of 2 and 3.

Implementations§

Source§

impl<T, Twiddles, Work> Autosort<T, Twiddles, Work>

Source

pub fn counts(&self) -> [usize; 5]

Return the radix counts.

Source

pub unsafe fn new_from_parts( size: usize, counts: [usize; 5], forward_twiddles: Twiddles, inverse_twiddles: Twiddles, work: Work, ) -> Self

Create a new transform generator from parts. Twiddles factors and work must be the correct size.

Source§

impl<T, Twiddles: AsRef<[Complex<T>]>, Work: AsRef<[Complex<T>]>> Autosort<T, Twiddles, Work>

Source

pub fn twiddles(&self) -> (&[Complex<T>], &[Complex<T>])

Return the forward and inverse twiddle factors.

Source

pub fn work_size(&self) -> usize

Return the work buffer size.

Source§

impl<T: FftFloat, Twiddles: Default + Extend<Complex<T>>, Work: Default + Extend<Complex<T>>> Autosort<T, Twiddles, Work>

Source

pub fn new(size: usize) -> Option<Self>

Create a new Stockham autosort generator. Returns None if the transform size cannot be performed.

Trait Implementations§

Source§

impl<Twiddles: AsRef<[Complex<f32>]>, Work: AsMut<[Complex<f32>]>> Fft for Autosort<f32, Twiddles, Work>

Source§

type Real = f32

The real type used by the FFT.
Source§

fn size(&self) -> usize

The size of the FFT.
Source§

fn transform_in_place(&self, input: &mut [Complex<f32>], transform: Transform)

Apply an FFT or IFFT in-place.
Source§

fn transform( &self, input: &[Complex<Self::Real>], output: &mut [Complex<Self::Real>], transform: Transform, )

Apply an FFT or IFFT out-of-place.
Source§

fn fft_in_place(&self, input: &mut [Complex<Self::Real>])

Apply an FFT in-place.
Source§

fn ifft_in_place(&self, input: &mut [Complex<Self::Real>])

Apply an IFFT in-place.
Source§

fn fft(&self, input: &[Complex<Self::Real>], output: &mut [Complex<Self::Real>])

Apply an FFT out-of-place.
Source§

fn ifft( &self, input: &[Complex<Self::Real>], output: &mut [Complex<Self::Real>], )

Apply an IFFT out-of-place.
Source§

impl<Twiddles: AsRef<[Complex<f64>]>, Work: AsMut<[Complex<f64>]>> Fft for Autosort<f64, Twiddles, Work>

Source§

type Real = f64

The real type used by the FFT.
Source§

fn size(&self) -> usize

The size of the FFT.
Source§

fn transform_in_place(&self, input: &mut [Complex<f64>], transform: Transform)

Apply an FFT or IFFT in-place.
Source§

fn transform( &self, input: &[Complex<Self::Real>], output: &mut [Complex<Self::Real>], transform: Transform, )

Apply an FFT or IFFT out-of-place.
Source§

fn fft_in_place(&self, input: &mut [Complex<Self::Real>])

Apply an FFT in-place.
Source§

fn ifft_in_place(&self, input: &mut [Complex<Self::Real>])

Apply an IFFT in-place.
Source§

fn fft(&self, input: &[Complex<Self::Real>], output: &mut [Complex<Self::Real>])

Apply an FFT out-of-place.
Source§

fn ifft( &self, input: &[Complex<Self::Real>], output: &mut [Complex<Self::Real>], )

Apply an IFFT out-of-place.

Auto Trait Implementations§

§

impl<T, Twiddles, Work> !Freeze for Autosort<T, Twiddles, Work>

§

impl<T, Twiddles, Work> !RefUnwindSafe for Autosort<T, Twiddles, Work>

§

impl<T, Twiddles, Work> Send for Autosort<T, Twiddles, Work>
where Twiddles: Send, Work: Send, T: Send,

§

impl<T, Twiddles, Work> !Sync for Autosort<T, Twiddles, Work>

§

impl<T, Twiddles, Work> Unpin for Autosort<T, Twiddles, Work>
where Twiddles: Unpin, T: Unpin, Work: Unpin,

§

impl<T, Twiddles, Work> UnwindSafe for Autosort<T, Twiddles, Work>
where Twiddles: UnwindSafe, T: UnwindSafe, Work: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.