Add linear interpolation algorithm