Why These Partial Fractions Need Two Kinds of Terms
A rational function can have a denominator that factors into irreducible quadratic polynomials. After partial-fraction decomposition, each such factor generally has a linear numerator. Integrating one term then requires two contributions: a logarithm from the part related to the denominator’s derivative, and an inverse tangent from the remaining constant part.
The key is to complete the square in each quadratic denominator. This puts the inverse-tangent contribution into a recognizable form. The sign of the quadratic’s leading coefficient matters: an irreducible quadratic with a negative leading coefficient is negative everywhere, not a positive square plus a positive constant. The formulas below handle either sign.
The Partial-Fraction Form
Suppose a proper rational function has a denominator that is a product of distinct irreducible real quadratics and has no linear factors. Its partial-fraction decomposition has the form
Here each \(q_i\) is irreducible, each \(a_i\ne 0\), and the numerator over each quadratic has degree less than two. The constants \(A_i\) and \(B_i\) are determined by multiplying through by the common denominator and matching coefficients. If the original rational function is improper, polynomial division is needed before applying this proper-fraction form.
Once the decomposition is found, integrate term by term. The same calculation applies to each term, so first consider a single irreducible quadratic \(q(x)=ax^2+bx+c\) and a linear numerator \(Ax+B\).
Completing the Square and Splitting the Numerator
Completing the square gives
Since \(b^2-4ac<0\), the quantity \(4ac-b^2\) is positive. Define
Then \(q(x)=a((x-h)^2+d)\). The bracket is positive for every real \(x\), so \(q\) has the same sign everywhere as \(a\). In particular, if \(a<0\), the completed-square expression is negative everywhere.
The derivative of \(q\) is \(q'(x)=2ax+b\). Write the numerator as a multiple of this derivative plus a constant:
This split is useful because the first part integrates to a logarithm. The constant part is integrated using the completed square.
The absolute value in the logarithm is necessary when \(q(x)<0\). There are no real zeros of \(q\), so this antiderivative is defined throughout the real line.
Why the Formula Works
The numerator split and the completed square give a direct derivation. Let \(\mu=B-\frac{Ab}{2a}\). Then
The first quotient has antiderivative \(\frac{A}{2a}\ln|q(x)|\), because the derivative of \(\ln|q(x)|\) is \(q'(x)/q(x)\) wherever \(q(x)\ne0\). For the second quotient, the substitution \(u=(x-h)/\sqrt d\) gives \(dx=\sqrt d\,du\), and therefore
Substituting back gives the stated formula. This derivation also explains why the sign of \(a\) must be retained in the inverse-tangent coefficient.
Worked Examples
Worked Example: Decompose and Integrate Two Quadratic Terms
Evaluate
Both denominator factors are irreducible over the reals. Set up the partial fractions with linear numerators:
Multiplying by \((x^2+1)(x^2+4)\) gives
Expanding the right side and matching coefficients yields \(A+C=1\), \(B+D=4\), \(4A+C=7\), and \(4B+D=13\). Subtracting the first equation from the third gives \(3A=6\), so \(A=2\) and \(C=-1\). Subtracting the second equation from the fourth gives \(3B=9\), so \(B=3\) and \(D=1\). Thus
Integrate the first term by separating \(2x\), the derivative of \(x^2+1\), from the constant \(3\):
For the second term, \(-x\) is \(-\frac12\) times the derivative of \(x^2+4\). Also, \(\int dx/(x^2+4)=\frac12\arctan(x/2)\). Therefore
Combining the results gives
Check by differentiation: the derivative is \(\frac{2x+3}{x^2+1}+\frac{-x+1}{x^2+4}\). Combining those fractions gives numerator \((2x+3)(x^2+4)+(-x+1)(x^2+1)=x^3+4x^2+7x+13\) over the original denominator, as required.
Worked Example: Complete the Square in a Shifted Quadratic
Evaluate
Complete the square, keeping the leading coefficient outside the bracket:
The denominator’s derivative is \(4x-4\), and the numerator splits as \(5x+1=\frac54(4x-4)+6\). Thus
For the remaining integral, the completed-square formula gives
Therefore an antiderivative is
To check, differentiate the logarithmic term to obtain \((5x-5)/(2x^2-4x+5)\). Differentiating the inverse-tangent term gives \(6/(2x^2-4x+5)\). Their sum is \((5x+1)/(2x^2-4x+5)\), the original integrand.
Worked Example: Integrate an Irreducible Quadratic with Negative Leading Coefficient
Evaluate
The discriminant is \(4^2-4(-2)(-5)=16-40=-24<0\), so the quadratic is irreducible. Completing the square gives
The denominator is negative for every real \(x\). Its derivative is \(-4x+4\), and \(3x+1=-\frac34(-4x+4)+4\). Hence
The remaining integral equals \(-\frac{1}{\sqrt6}\arctan(\sqrt{2/3}(x-1))\). Thus the antiderivative is
For the check, the derivative of the logarithmic term is \((3x-3)/(-2x^2+4x-5)\). The derivative of the inverse-tangent term is \(4/(-2x^2+4x-5)\). Their sum is the original integrand. The absolute value in the logarithm is valid and necessary because its argument is always negative.
A Common Sign Mistake
A common error is to assume that every irreducible quadratic can be written as a positive constant times a square plus a positive constant. For example, \(-x^2-1\) is irreducible, but it is \(-(x^2+1)\), not a positive square plus a positive constant. Dropping the negative factor changes the sign of the integrand and gives the wrong inverse-tangent contribution.
Using the Method Reliably
For a rational function with distinct irreducible quadratic factors, first obtain the partial-fraction decomposition, then integrate each term on its own. In each term, identify the derivative of the denominator, subtract the matching multiple from the numerator, and complete the square in the denominator. This separates the logarithmic and inverse-tangent parts without guessing.
Keep the logarithmic absolute value when the quadratic can be negative, and retain the sign of the leading coefficient in the inverse-tangent coefficient. Finally, differentiate the proposed antiderivative or recombine the partial fractions to check it. These checks catch both coefficient errors in the decomposition and sign errors in the integration.
Check Your Understanding
Use the completed-square form and numerator split to answer the following.
- For \(x^2+6x+13\), find \(h\) and \(d\) in the form \((x-h)^2+d\).
- For \(q(x)=3x^2+6x+5\), write \(1/q(x)\) in completed-square form and state whether \(q\) is positive or negative.
- In \((4x+7)/(2x^2+4x+5)\), express the numerator as a multiple of the denominator’s derivative plus a constant.
- Why is an absolute value used in \(\ln|q(x)|\) when integrating \(q'(x)/q(x)\)?
- Explain why replacing a negative-leading irreducible quadratic by its positive version without adjusting the numerator changes the integral.