AP-CALCBC-6.10

U6.10 Integration Using Long Division and Completing the Square

Master AP Calc BC 6.10: use polynomial long division and completing the square to rewrite rational integrands into arctangent, arcsine, and log forms.

What you'll do in this lesson

A voice-first session with the Crimsora tutor on U6.10 Integration Using Long Division and Completing the Square, then targeted practice and FRQs — with the tutor adapting to where you get stuck.

What this lesson covers

When an integral has a rational function you can't tackle head-on, the trick is almost always to rewrite it first. Two pre-processing moves dominate this topic: polynomial long division (when the top is as big as or bigger than the bottom) and completing the square (when a quadratic denominator won't factor nicely). Both turn an intimidating integrand into pieces you already know how to antidifferentiate.

This lesson shows you exactly when each move is required, how to execute it cleanly, and how the resulting forms map onto the standard antiderivatives: natural logs, arctangent, and arcsine. Recognizing the setup fast is what the exam rewards.

When and How to Use Long Division

Polynomial long division is mandatory whenever the degree of the numerator is greater than or equal to the degree of the denominator. This creates an improper rational function, and you cannot substitute or complete the square productively until you fix it.

Dividing rewrites the integrand as a polynomial plus a proper remainder fraction:N(x)D(x)=Q(x)+R(x)D(x)\frac{N(x)}{D(x)} = Q(x) + \frac{R(x)}{D(x)}where degR<degD\deg R < \deg D. The quotient Q(x)Q(x) integrates term by term with the power rule, and the leftover proper fraction is handled by substitution, log, or arctangent forms.

Consider x2x2+1dx\int \frac{x^2}{x^2+1}\,dx. The degrees are equal, so divide: x2x2+1=11x2+1\frac{x^2}{x^2+1} = 1 - \frac{1}{x^2+1}. Now the integral becomes 1dx1x2+1dx=xarctanx+C\int 1\,dx - \int \frac{1}{x^2+1}\,dx = x - \arctan x + C.

A common misconception is to attempt substitution or partial fractions on an improper fraction directly. Always check degrees first. If the numerator degree is greater or equal, divide. Only after dividing is the remaining fraction "proper" enough for the tools in later topics.

Completing the Square in the Denominator

When a quadratic denominator does not factor over the rationals, completing the square converts it into a form matching an inverse-trig or log antiderivative. The goal is to turn ax2+bx+cax^2+bx+c into a[(x+h)2±k2]a\big[(x+h)^2 \pm k^2\big].

Recall the target antiderivatives:
Integrand formAntiderivative
1x2+a2\frac{1}{x^2+a^2}1aarctanxa+C\frac{1}{a}\arctan\frac{x}{a}+C
1a2x2\frac{1}{\sqrt{a^2-x^2}}arcsinxa+C\arcsin\frac{x}{a}+C
1udu\frac{1}{u}\,dulnu+C\ln|u|+C
To complete the square, take half the coefficient of xx, square it, add and subtract it. For x2+6x+13x^2+6x+13, half of 6 is 3, squared is 9: x2+6x+13=(x+3)2+4x^2+6x+13 = (x+3)^2+4. Then 1x2+6x+13dx=1(x+3)2+4dx=12arctanx+32+C\int \frac{1}{x^2+6x+13}\,dx = \int \frac{1}{(x+3)^2+4}\,dx = \frac{1}{2}\arctan\frac{x+3}{2}+C.

A plus sign inside, (x+h)2+k2(x+h)^2+k^2, signals arctangent. A minus under a square root, k2(x+h)2\sqrt{k^2-(x+h)^2}, signals arcsine. Watch signs carefully — misreading them sends you to the wrong form.

Splitting Numerators and Combining Both Tools

Many exam problems require both a linear numerator handled by substitution and a constant leftover handled by arctangent. When the numerator is linear over a completed-square quadratic, split it so part of the numerator becomes the derivative of the denominator.

Take x+4x2+2x+5dx\int \frac{x+4}{x^2+2x+5}\,dx. The denominator's derivative is 2x+22x+2. Rewrite the numerator: x+4=12(2x+2)+3x+4 = \tfrac{1}{2}(2x+2) + 3. So the integral splits into122x+2x2+2x+5dx+31x2+2x+5dx.\frac{1}{2}\int \frac{2x+2}{x^2+2x+5}\,dx + 3\int \frac{1}{x^2+2x+5}\,dx.The first piece is a lnu\ln|u| form giving 12ln(x2+2x+5)\frac{1}{2}\ln(x^2+2x+5). For the second, complete the square: x2+2x+5=(x+1)2+4x^2+2x+5=(x+1)^2+4, giving 312arctanx+123\cdot\frac{1}{2}\arctan\frac{x+1}{2}.

The combined answer is 12ln(x2+2x+5)+32arctanx+12+C\frac{1}{2}\ln(x^2+2x+5)+\frac{3}{2}\arctan\frac{x+1}{2}+C.

This "split the numerator" strategy is a signature BC move. The logic: force the top to contain a copy of the bottom's derivative, then whatever constant remains rides the arctangent form. Master the split and these problems become routine.

How the Exam Tests This Topic

On both multiple-choice and free-response, 6.10 rarely appears as a standalone label. Instead you're handed a rational integrand and expected to recognize the pre-processing step yourself. The exam is testing whether you can diagnose form before computing.

Typical triggers: a numerator degree at least as big as the denominator (divide first), an unfactorable quadratic denominator (complete the square), or a quadratic under a radical (complete the square toward arcsine). Calculator-inactive sections favor these because the answers are clean logs and inverse trig.

A frequent trap is forgetting the coefficient 1a\frac{1}{a} in the arctangent result, or dropping the chain-rule constant when the inside is (x+h)(x+h) rather than xx. Another trap: canceling or substituting on an improper fraction without dividing. Always ask two questions before integrating a rational function: Is it proper? Does the denominator factor? If improper, divide. If it doesn't factor, complete the square. These two reflexes convert most 6.10 problems into standard antiderivatives you already know from topic 6.8.

Key terms

Proper rational function.
A fraction where the numerator degree is strictly less than the denominator degree; required before completing the square or partial fractions.
Improper rational function.
A fraction where the numerator degree is greater than or equal to the denominator degree; must be reduced by polynomial long division first.
Polynomial long division.
Process of dividing N(x)N(x) by D(x)D(x) to write the integrand as a quotient polynomial plus a proper remainder fraction.
Completing the square.
Rewriting ax2+bx+cax^2+bx+c as a[(x+h)2±k2]a[(x+h)^2\pm k^2] to match arctangent or arcsine antiderivative forms.
Arctangent form.
1x2+a2dx=1aarctanxa+C\int \frac{1}{x^2+a^2}\,dx=\frac{1}{a}\arctan\frac{x}{a}+C, produced by a completed square with a plus sign.
Arcsine form.
1a2x2dx=arcsinxa+C\int \frac{1}{\sqrt{a^2-x^2}}\,dx=\arcsin\frac{x}{a}+C, produced by a completed square under a radical with a minus sign.
Numerator splitting.
Rewriting a linear numerator so part equals the derivative of the denominator (a log term) and the rest becomes a constant (an arctangent term).

Worked example

Evaluate 2x2+3x2+1dx\int \frac{2x^2+3}{x^2+1}\,dx.
First check degrees: the numerator degree (2) equals the denominator degree (2), so the fraction is improper and long division is required.

Divide 2x2+32x^2+3 by x2+1x^2+1. Since 2(x2+1)=2x2+22\cdot(x^2+1)=2x^2+2, subtracting gives a remainder of 32=13-2=1. Thus2x2+3x2+1=2+1x2+1.\frac{2x^2+3}{x^2+1} = 2 + \frac{1}{x^2+1}.Now integrate term by term. The constant integrates to 2x2x. The remaining fraction is the standard arctangent form with a=1a=1:1x2+1dx=arctanx.\int \frac{1}{x^2+1}\,dx = \arctan x.Combine the pieces:2x2+3x2+1dx=2x+arctanx+C.\int \frac{2x^2+3}{x^2+1}\,dx = 2x + \arctan x + C.The key decision was recognizing the improper fraction up front. Attempting substitution before dividing would have gone nowhere.

Practice questions

Which is the correct first step for evaluating x3+xx2+4dx\int \frac{x^3+x}{x^2+4}\,dx?
  1. Complete the square in the denominator
  2. Perform polynomial long division
  3. Use the arcsine antiderivative form
  4. Substitute u=x2+4u=x^2+4 immediately

Answer: Perform polynomial long division

The numerator has degree 3 and the denominator has degree 2, so the fraction is improper. Long division must come first to produce a polynomial plus a proper remainder. Only after dividing can you consider substitution or arctangent forms on the leftover fraction.
Evaluate 1x24x+13dx\int \frac{1}{x^2-4x+13}\,dx.

Answer: 13arctanx23+C\frac{1}{3}\arctan\frac{x-2}{3}+C

The denominator does not factor over the rationals, so complete the square: half of 4-4 is 2-2, squared is 44, giving x24x+13=(x2)2+9x^2-4x+13=(x-2)^2+9. This matches 1u2+a2\frac{1}{u^2+a^2} with a=3a=3, so the integral is 13arctanx23+C\frac{1}{3}\arctan\frac{x-2}{3}+C. Don't forget the 1a=13\frac{1}{a}=\frac{1}{3} factor.
Evaluate 2x+1x2+2x+2dx\int \frac{2x+1}{x^2+2x+2}\,dx.

Answer: ln(x2+2x+2)arctan(x+1)+C\ln(x^2+2x+2)-\arctan(x+1)+C

The denominator's derivative is 2x+22x+2. Write the numerator as 2x+1=(2x+2)12x+1=(2x+2)-1. The first part gives 2x+2x2+2x+2dx=ln(x2+2x+2)\int\frac{2x+2}{x^2+2x+2}\,dx=\ln(x^2+2x+2). For the remaining 1x2+2x+2dx-\int\frac{1}{x^2+2x+2}\,dx, complete the square: x2+2x+2=(x+1)2+1x^2+2x+2=(x+1)^2+1, giving arctan(x+1)-\arctan(x+1). Combine for the final answer.

FAQ

How do I know whether to use long division or completing the square?
Check the numerator and denominator degrees first. If the numerator degree is greater than or equal to the denominator degree, use long division. If the denominator is a quadratic that won't factor nicely and you need an arctangent or arcsine result, complete the square. Some problems need both, in that order.
How do I tell whether completing the square leads to arctangent or arcsine?
Look at the structure. A completed square in the denominator with a plus sign, (x+h)2+k2(x+h)^2+k^2, gives arctangent. A completed square under a square root with subtraction, k2(x+h)2\sqrt{k^2-(x+h)^2}, gives arcsine. The presence of a radical and a minus sign is the arcsine signal.
Why do I keep losing the constant factor in my arctangent answers?
The formula is 1x2+a2dx=1aarctanxa+C\int\frac{1}{x^2+a^2}\,dx=\frac{1}{a}\arctan\frac{x}{a}+C, not just arctanxa\arctan\frac{x}{a}. After completing the square you must identify aa (the square root of the constant) and multiply by 1a\frac{1}{a}. Forgetting this factor is one of the most common errors on this topic.
Do I still complete the square if the quadratic factors?
No. If the quadratic factors over the rationals, you should use partial fractions (topic 6.12) instead, which produces log terms. Completing the square is reserved for irreducible quadratics that cannot be factored, where the result is an arctangent or arcsine.

Learn this with a teacher, not a page

The Crimsora tutor teaches U6.10 Integration Using Long Division and Completing the Square live — explaining on a whiteboard, asking you questions, and adapting to where you get stuck.