Function lineInterpolate