step function linear interpolation