solvr 0.2.0

Advanced computing library for real-world problem solving - optimization, differential equations, interpolation, statistics, and more
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
use crate::interpolate::error::InterpolateResult;
use crate::interpolate::impl_generic::interp1d::interp1d_evaluate;
use crate::interpolate::traits::interp1d::{Interp1dAlgorithms, InterpMethod};
use numr::runtime::cpu::{CpuClient, CpuRuntime};
use numr::tensor::Tensor;

impl Interp1dAlgorithms<CpuRuntime> for CpuClient {
    fn interp1d(
        &self,
        x: &Tensor<CpuRuntime>,
        y: &Tensor<CpuRuntime>,
        x_new: &Tensor<CpuRuntime>,
        method: InterpMethod,
    ) -> InterpolateResult<Tensor<CpuRuntime>> {
        interp1d_evaluate(self, x, y, x_new, method)
    }
}