Struct rgsl::types::interpolation::InterpType
source · [−]pub struct InterpType { /* private fields */ }
Implementations
sourceimpl InterpType
impl InterpType
sourcepub fn min_size(&self) -> u32
pub fn min_size(&self) -> u32
This function returns the minimum number of points required by the interpolation object interp or interpolation type T. For example, Akima spline interpolation requires a minimum of 5 points.
sourcepub fn linear() -> InterpType
pub fn linear() -> InterpType
Linear interpolation. This interpolation method does not require any additional memory.
sourcepub fn polynomial() -> InterpType
pub fn polynomial() -> InterpType
Polynomial interpolation. This method should only be used for interpolating small numbers of points because polynomial interpolation introduces large oscillations, even for well-behaved datasets. The number of terms in the interpolating polynomial is equal to the number of points.
sourcepub fn cspline() -> InterpType
pub fn cspline() -> InterpType
Cubic spline with natural boundary conditions. The resulting curve is piecewise cubic on each interval, with matching first and second derivatives at the supplied data-points. The second derivative is chosen to be zero at the first point and last point.
sourcepub fn cspline_periodic() -> InterpType
pub fn cspline_periodic() -> InterpType
Cubic spline with periodic boundary conditions. The resulting curve is piecewise cubic on each interval, with matching first and second derivatives at the supplied data-points. The derivatives at the first and last points are also matched. Note that the last point in the data must have the same y-value as the first point, otherwise the resulting periodic interpolation will have a discontinuity at the boundary.
sourcepub fn akima() -> InterpType
pub fn akima() -> InterpType
Non-rounded Akima spline with natural boundary conditions. This method uses the non-rounded corner algorithm of Wodicka.
sourcepub fn akima_periodic() -> InterpType
pub fn akima_periodic() -> InterpType
Non-rounded Akima spline with periodic boundary conditions. This method uses the non-rounded corner algorithm of Wodicka.
Trait Implementations
sourceimpl Clone for InterpType
impl Clone for InterpType
sourcefn clone(&self) -> InterpType
fn clone(&self) -> InterpType
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
impl Copy for InterpType
Auto Trait Implementations
impl RefUnwindSafe for InterpType
impl !Send for InterpType
impl !Sync for InterpType
impl Unpin for InterpType
impl UnwindSafe for InterpType
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcepub fn to_owned(&self) -> T
pub fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
sourcepub fn clone_into(&self, target: &mut T)
pub fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more