結果 : calculate linear function from two points