Reconstructor

Trait Reconstructor 

Source
pub trait Reconstructor {
    // Required method
    fn reconstruct(&mut self, data: &mut [Complex<f64>]);

    // Provided methods
    fn reconstruct_from_reals(&mut self, data: &[f64], out: &mut [Complex<f64>]) { ... }
    fn quadrature_reconstruct(
        &mut self,
        cos: &[f64],
        sin: &[f64],
        out: &mut [Complex<f64>],
    ) { ... }
}
Expand description

Reconstructs signals from NMR data.

Required Methods§

Source

fn reconstruct(&mut self, data: &mut [Complex<f64>])

Reconstruct a complex signal in place.

This method should not be used for quadrature blindly. See Reconstructor::quadrature_reconstruct.

Provided Methods§

Source

fn reconstruct_from_reals(&mut self, data: &[f64], out: &mut [Complex<f64>])

Reconstruct data represented as a list of floating point values. Converts to complex numbers by setting the imaginary component to zero. Your data will have mirrored quadrature peaks.

§Panics

out must have the same length as data.

Source

fn quadrature_reconstruct( &mut self, cos: &[f64], sin: &[f64], out: &mut [Complex<f64>], )

Reconstruct a spectrum from cos and sin signals using quadrature.

This method adds cos and -i·sin componentwise, then calls reconstruct on the resulting list.

§Panics

cos, sin, and out must all have the same length.

Implementors§