Univariate linear regression with gradient descent