Rewrite as .

Apply the distributive property.

Apply the distributive property.

Apply the distributive property.

Reorder and .

Raise to the power of .

Raise to the power of .

Use the power rule to combine exponents.

Add and .

Multiply by .

Subtract from .

Divide by .

Split the single integral into multiple integrals.

By the Power Rule, the integral of with respect to is .

Since is constant with respect to , move out of the integral.

The integral of with respect to is .

Simplify.

Evaluate integral of ((x-1)^2)/x with respect to x