fn i_of(&self, x : f32) -> usize {
        let i = ((x - self.first_x) / self.delta_x).round() as usize;
        if i > self.npoints as usize{
            return self.npoints as usize
        }
        i
    }
// Get the nearest index of any x
Get the nearest index of any x
Get the nearest index of any x
fn i_of(&self, x : f32) -> usize {
        let i = ((x - self.first_x) / self.delta_x).round() as usize;
        if i > self.npoints as usize{
            return self.npoints as usize
        }
        i
    }
fn i_of ( & self , x : f32 ) -> usize { let i = ( ( x - self . first_x ) / self . delta_x ) . round ( ) as usize ; if i > self . npoints as usize { return self . npoints as usize } i }
Get the nearest index of any x
Get the nearest index of any x
&self
x
f32
&self
x
f32