# Interpolation ## Linear interpolation Often we know the values of a function at a fixed set of points $f(x_i)$ and need to interpolate to find the value at a point $x$ where $x_i=xp[i+1])) f2[ind] = poly(x[ind]) # exclude the first and last intervals ind = np.where(np.logical_and(x>=xp[1],x