Integral (3x^2-x+2)/(x-1)(x^2+1) dx

To integrate the given rational function, we need to decompose it into partial fractions.

Step 1: Factorize the denominator.
The denominator can be factored as (x-1)(x^2+1).

Step 2: Decompose into partial fractions.
We write the rational function as A/(x-1) + (Bx+C)/(x^2+1).

Step 3: Determine the values of A, B, and C.
To find the values of A, B, and C, we need to clear the denominators. Multiplying both sides of the equation by (x-1)(x^2+1), we get:
3x^2 - x + 2 = A(x^2+1) + (Bx+C)(x-1).

Now, we can expand and equate the coefficients of like terms:
3x^2 - x + 2 = Ax^2 + A + Bx^2 - Bx + Cx - C.

Comparing the coefficients for x^2: 3 = A + B.
Comparing the coefficients for x: -1 = -B + C.
Comparing the constant terms: 2 = A - C.

Solving these equations simultaneously, we can find A, B, and C.

Step 4: Integrate the partial fractions.
Once the partial fractions decomposition is obtained, we can integrate each term separately.

∫ [(3x^2-x+2)/((x-1)(x^2+1))] dx = ∫ A/(x-1) dx + ∫ [(Bx+C)/(x^2+1)] dx

The integral of A/(x-1) is simply A * ln|x-1| + C1, where C1 is the constant of integration.

For the integral of (Bx+C)/(x^2+1), we can use a substitution. Let u = x^2+1, then du = 2x dx.
The integral becomes:
∫ (Bx+C)/(x^2+1) dx = (B/2) ∫ du/u = (B/2) ln|u| + C2 = (B/2) ln|x^2+1| + C2, where C2 is the constant of integration.

Therefore, the complete integral is:
∫ [(3x^2-x+2)/((x-1)(x^2+1))] dx = A * ln|x-1| + (B/2) ln|x^2+1| + C, where C is the constant of integration obtained by combining C1 and C2.