slope calculator fix2