Integration using completing the square and the derivative of arctan(x)