Solved Exercises on Integrating Using Long Division and Completing the Square in Integral Calculus

Master long division and completing the square: polynomial division, quadratic completion, and advanced techniques through these 5 detailed exercises.

Solution: Exercises 1 to 3
1 Long division of polynomials
Exercise 1
Evaluate \(\int \frac{x^3 + 2x^2 - x + 1}{x^2 + 1} dx\) using long division.
Definition:

Polynomial long division: A method to divide one polynomial by another, expressing \(\frac{P(x)}{D(x)} = Q(x) + \frac{R(x)}{D(x)}\) where \(\deg(R) < \deg(D)\)

Long division method:
  1. Divide the leading term of the numerator by the leading term of the denominator
  2. Multiply the entire divisor by this quotient
  3. Subtract from the original numerator
  4. Repeat until the remainder has degree less than the divisor
  5. Integrate the quotient and the remaining rational function separately
Original function
\(f(x) = \frac{x^3 + 2x^2 - x + 1}{x^2 + 1}\)
Long division
\(x + 2 + \frac{-2x - 1}{x^2 + 1}\)
Result
\(\frac{x^2}{2} + 2x - \ln(x^2 + 1) - \arctan(x) + C\)
Step 1: Set up long division

Divide \((x^3 + 2x^2 - x + 1) \div (x^2 + 1)\)

First term: \(\frac{x^3}{x^2} = x\)

Multiply: \(x(x^2 + 1) = x^3 + x\)

Subtract: \((x^3 + 2x^2 - x + 1) - (x^3 + x) = 2x^2 - 2x + 1\)

Step 2: Continue division

Next term: \(\frac{2x^2}{x^2} = 2\)

Multiply: \(2(x^2 + 1) = 2x^2 + 2\)

Subtract: \((2x^2 - 2x + 1) - (2x^2 + 2) = -2x - 1\)

Since \(\deg(-2x - 1) < \deg(x^2 + 1)\), we stop here.

Step 3: Write the result

\(\frac{x^3 + 2x^2 - x + 1}{x^2 + 1} = x + 2 + \frac{-2x - 1}{x^2 + 1}\)

Step 4: Integrate each term

\(\int \left(x + 2 + \frac{-2x - 1}{x^2 + 1}\right) dx = \int x dx + \int 2 dx + \int \frac{-2x}{x^2 + 1} dx + \int \frac{-1}{x^2 + 1} dx\)

\(= \frac{x^2}{2} + 2x - \ln(x^2 + 1) - \arctan(x) + C\)

\(\int \frac{x^3 + 2x^2 - x + 1}{x^2 + 1} dx = \frac{x^2}{2} + 2x - \ln(x^2 + 1) - \arctan(x) + C\)
Final answer:

\(\int \frac{x^3 + 2x^2 - x + 1}{x^2 + 1} dx = \frac{x^2}{2} + 2x - \ln(x^2 + 1) - \arctan(x) + C\)

Applied rules:

• Polynomial long division: \(\frac{P(x)}{D(x)} = Q(x) + \frac{R(x)}{D(x)}\)

• Power rule: \(\int x^n dx = \frac{x^{n+1}}{n+1}\)

• Arctangent rule: \(\int \frac{1}{x^2 + 1} dx = \arctan(x)\)

• Logarithmic rule: \(\int \frac{f'(x)}{f(x)} dx = \ln|f(x)|\)

2 Completing the square
Exercise 2
Evaluate \(\int \frac{1}{x^2 + 4x + 5} dx\) using completing the square.
Definition:

Completing the square: A technique to rewrite a quadratic expression in the form \((x + h)^2 + k\) to facilitate integration

Original function
\(f(x) = \frac{1}{x^2 + 4x + 5}\)
Complete the square
\(x^2 + 4x + 5 = (x+2)^2 + 1\)
Result
\(\arctan(x+2) + C\)
Step 1: Complete the square in the denominator

To complete the square for \(x^2 + 4x + 5\):

Take the coefficient of \(x\): \(4\), divide by 2: \(\frac{4}{2} = 2\), square it: \(2^2 = 4\)

\(x^2 + 4x + 5 = x^2 + 4x + 4 - 4 + 5 = (x + 2)^2 + 1\)

Step 2: Rewrite the integral

\(\int \frac{1}{x^2 + 4x + 5} dx = \int \frac{1}{(x + 2)^2 + 1} dx\)

Step 3: Apply the arctangent formula

The integral \(\int \frac{1}{u^2 + 1} du = \arctan(u) + C\)

Here, let \(u = x + 2\), so \(du = dx\)

\(\int \frac{1}{(x + 2)^2 + 1} dx = \arctan(x + 2) + C\)

Step 4: Verification

Take the derivative: \(\frac{d}{dx}[\arctan(x + 2)] = \frac{1}{(x + 2)^2 + 1} = \frac{1}{x^2 + 4x + 5}\) ✓

\(\int \frac{1}{x^2 + 4x + 5} dx = \arctan(x + 2) + C\)
Final answer:

\(\int \frac{1}{x^2 + 4x + 5} dx = \arctan(x + 2) + C\)

Applied rules:

• Completing the square: \(x^2 + bx + c = (x + \frac{b}{2})^2 + (c - \frac{b^2}{4})\)

• Arctangent formula: \(\int \frac{1}{u^2 + 1} du = \arctan(u)\)

• Substitution: Let \(u = x + h\) when denominator is \((x + h)^2 + k\)

3 Combined techniques
Exercise 3
Evaluate \(\int \frac{x^2 + 3x + 2}{x^2 + 2x + 2} dx\) using both long division and completing the square.
Definition:

Combined techniques: When both the numerator and denominator have the same degree, use long division first, then apply completing the square to the remaining rational function

Original function
\(f(x) = \frac{x^2 + 3x + 2}{x^2 + 2x + 2}\)
Long division
\(1 + \frac{x}{x^2 + 2x + 2}\)
Complete the square
\(x^2 + 2x + 2 = (x+1)^2 + 1\)
Step 1: Apply long division

Since both numerator and denominator have degree 2, divide \((x^2 + 3x + 2) \div (x^2 + 2x + 2)\)

First term: \(\frac{x^2}{x^2} = 1\)

Multiply: \(1(x^2 + 2x + 2) = x^2 + 2x + 2\)

Subtract: \((x^2 + 3x + 2) - (x^2 + 2x + 2) = x\)

So: \(\frac{x^2 + 3x + 2}{x^2 + 2x + 2} = 1 + \frac{x}{x^2 + 2x + 2}\)

Step 2: Complete the square in the denominator

For \(x^2 + 2x + 2\): Take coefficient of \(x\): \(2\), divide by 2: \(1\), square: \(1\)

\(x^2 + 2x + 2 = x^2 + 2x + 1 - 1 + 2 = (x + 1)^2 + 1\)

Step 3: Rewrite the remaining integral

\(\int \frac{x}{x^2 + 2x + 2} dx = \int \frac{x}{(x + 1)^2 + 1} dx\)

Let \(u = x + 1\), so \(x = u - 1\) and \(dx = du\)

\(\int \frac{u - 1}{u^2 + 1} du = \int \frac{u}{u^2 + 1} du - \int \frac{1}{u^2 + 1} du\)

Step 4: Integrate each term

\(\int \frac{u}{u^2 + 1} du = \frac{1}{2}\ln(u^2 + 1) = \frac{1}{2}\ln((x + 1)^2 + 1)\)

\(\int \frac{1}{u^2 + 1} du = \arctan(u) = \arctan(x + 1)\)

Step 5: Combine all results

\(\int \frac{x^2 + 3x + 2}{x^2 + 2x + 2} dx = \int 1 dx + \int \frac{x}{x^2 + 2x + 2} dx\)

\(= x + \frac{1}{2}\ln((x + 1)^2 + 1) - \arctan(x + 1) + C\)

\(\int \frac{x^2 + 3x + 2}{x^2 + 2x + 2} dx = x + \frac{1}{2}\ln(x^2 + 2x + 2) - \arctan(x + 1) + C\)
Final answer:

\(\int \frac{x^2 + 3x + 2}{x^2 + 2x + 2} dx = x + \frac{1}{2}\ln(x^2 + 2x + 2) - \arctan(x + 1) + C\)

Applied rules:

• Polynomial long division: When degrees are equal

• Completing the square: For quadratic denominators

• Substitution: Let \(u = x + h\) for \((x + h)^2 + k\)

• Logarithmic rule: \(\int \frac{f'(x)}{f(x)} dx = \ln|f(x)|\)

Key Concepts: Long Division & Completing the Square
\(\frac{P(x)}{D(x)} = Q(x) + \frac{R(x)}{D(x)}\)
Long Division Formula
Long Division
\(\frac{P(x)}{D(x)} = Q(x) + \frac{R(x)}{D(x)}\)
Where \(\deg(R) < \deg(D)\)
Completing Square
\(x^2 + bx + c = (x + \frac{b}{2})^2 + (c - \frac{b^2}{4})\)
Quadratic completion
Arctangent Form
\(\int \frac{1}{u^2 + 1} du = \arctan(u) + C\)
After completing square
Logarithmic Form
\(\int \frac{f'(x)}{f(x)} dx = \ln|f(x)| + C\)
After long division
Linear Term
\(\int \frac{ax + b}{x^2 + px + q} dx\)
Requires substitution
Trigonometric Substitution
\(\int \frac{1}{(x-h)^2 + k^2} dx = \frac{1}{k}\arctan(\frac{x-h}{k}) + C\)
General form
Key definitions:

Polynomial Long Division: A method to divide one polynomial by another, expressing the result as a quotient plus a remainder over the original divisor

Completing the Square: A technique to rewrite a quadratic expression in vertex form, making it easier to integrate

Rational Functions: Functions that can be expressed as the ratio of two polynomials

Integration methods:
  1. Check degrees: If \(\deg(\text{numerator}) \geq \deg(\text{denominator})\), use long division first
  2. Apply long division: Divide polynomials to get a polynomial plus a proper rational function
  3. Complete the square: Rewrite quadratic denominators in vertex form
  4. Integrate: Apply appropriate formulas to each term
Tip 1: Always check if the numerator's degree is greater than or equal to the denominator's degree.
Tip 2: After completing the square, look for arctangent or logarithmic patterns.
Tip 3: For linear terms in the numerator after completing the square, use substitution.
Tip 4: Always verify your answer by differentiating the result.
Common applications: Integration of rational functions, solving differential equations, calculating areas and volumes, probability distributions.
Visualization: These techniques transform complex rational integrals into simpler forms.
Essential formulas to know:

• Long Division: \(\frac{P(x)}{D(x)} = Q(x) + \frac{R(x)}{D(x)}\) where \(\deg(R) < \deg(D)\)

• Completing the Square: \(x^2 + bx + c = (x + \frac{b}{2})^2 + (c - \frac{b^2}{4})\)

• Arctangent: \(\int \frac{1}{u^2 + 1} du = \arctan(u) + C\)

• Logarithmic: \(\int \frac{f'(x)}{f(x)} dx = \ln|f(x)| + C\)

• General form: \(\int \frac{1}{(x-h)^2 + k^2} dx = \frac{1}{k}\arctan(\frac{x-h}{k}) + C\)

Visual Analysis: Integration Patterns
Exercise 6: Pattern Recognition
Explore integration patterns:
\(\int \frac{x}{x^2+1} dx\)
\(\int \frac{1}{x^2+2x+2} dx\)
\(\int \frac{x^2}{x^2+1} dx\)

Analysis: Identifying common integration patterns.

  • \(\int \frac{x}{x^2+1} dx = \frac{1}{2}\ln(x^2+1) + C\) (logarithmic pattern)
  • \(\int \frac{1}{x^2+2x+2} dx = \int \frac{1}{(x+1)^2+1} dx = \arctan(x+1) + C\) (completing the square)
  • \(\int \frac{x^2}{x^2+1} dx = \int (1 - \frac{1}{x^2+1}) dx = x - \arctan(x) + C\) (long division)
Solution: Exercises 4 to 5
4 Advanced long division
Exercise 4
Evaluate \(\int \frac{x^4 - 2x^3 + 3x^2 - x + 1}{x^2 - x + 1} dx\) using long division.
Definition:

Advanced polynomial long division: When the degree of the numerator is significantly higher than the denominator, the division may yield a more complex quotient

Original function
\(f(x) = \frac{x^4 - 2x^3 + 3x^2 - x + 1}{x^2 - x + 1}\)
Long division
\(x^2 - x + 1 + \frac{x}{x^2 - x + 1}\)
Result
\(\frac{x^3}{3} - \frac{x^2}{2} + x + \frac{1}{\sqrt{3}}\arctan(\frac{2x-1}{\sqrt{3}}) + C\)
Step 1: Set up long division

Divide \((x^4 - 2x^3 + 3x^2 - x + 1) \div (x^2 - x + 1)\)

First term: \(\frac{x^4}{x^2} = x^2\)

Multiply: \(x^2(x^2 - x + 1) = x^4 - x^3 + x^2\)

Subtract: \((x^4 - 2x^3 + 3x^2 - x + 1) - (x^4 - x^3 + x^2) = -x^3 + 2x^2 - x + 1\)

Step 2: Continue division

Next term: \(\frac{-x^3}{x^2} = -x\)

Multiply: \(-x(x^2 - x + 1) = -x^3 + x^2 - x\)

Subtract: \((-x^3 + 2x^2 - x + 1) - (-x^3 + x^2 - x) = x^2 + 1\)

Step 3: Continue division

Next term: \(\frac{x^2}{x^2} = 1\)

Multiply: \(1(x^2 - x + 1) = x^2 - x + 1\)

Subtract: \((x^2 + 1) - (x^2 - x + 1) = x\)

Since \(\deg(x) < \deg(x^2 - x + 1)\), we stop here.

Step 4: Write the result

\(\frac{x^4 - 2x^3 + 3x^2 - x + 1}{x^2 - x + 1} = x^2 - x + 1 + \frac{x}{x^2 - x + 1}\)

Step 5: Complete the square in the remainder

For \(x^2 - x + 1\): Take coefficient of \(x\): \(-1\), divide by 2: \(-\frac{1}{2}\), square: \(\frac{1}{4}\)

\(x^2 - x + 1 = x^2 - x + \frac{1}{4} - \frac{1}{4} + 1 = (x - \frac{1}{2})^2 + \frac{3}{4}\)

Step 6: Integrate each term

\(\int (x^2 - x + 1) dx = \frac{x^3}{3} - \frac{x^2}{2} + x\)

\(\int \frac{x}{x^2 - x + 1} dx = \int \frac{x}{(x - \frac{1}{2})^2 + \frac{3}{4}} dx\)

Let \(u = x - \frac{1}{2}\), so \(x = u + \frac{1}{2}\) and \(dx = du\)

\(\int \frac{u + \frac{1}{2}}{u^2 + \frac{3}{4}} du = \int \frac{u}{u^2 + \frac{3}{4}} du + \int \frac{\frac{1}{2}}{u^2 + \frac{3}{4}} du\)

\(= \frac{1}{2}\ln(u^2 + \frac{3}{4}) + \frac{1}{2} \cdot \frac{2}{\sqrt{3}}\arctan(\frac{2u}{\sqrt{3}}) = \frac{1}{2}\ln((x-\frac{1}{2})^2 + \frac{3}{4}) + \frac{1}{\sqrt{3}}\arctan(\frac{2x-1}{\sqrt{3}})\)

\(\int \frac{x^4 - 2x^3 + 3x^2 - x + 1}{x^2 - x + 1} dx = \frac{x^3}{3} - \frac{x^2}{2} + x + \frac{1}{2}\ln(x^2 - x + 1) + \frac{1}{\sqrt{3}}\arctan(\frac{2x-1}{\sqrt{3}}) + C\)
Final answer:

\(\int \frac{x^4 - 2x^3 + 3x^2 - x + 1}{x^2 - x + 1} dx = \frac{x^3}{3} - \frac{x^2}{2} + x + \frac{1}{2}\ln(x^2 - x + 1) + \frac{1}{\sqrt{3}}\arctan(\frac{2x-1}{\sqrt{3}}) + C\)

Applied rules:

• Polynomial long division: \(\frac{P(x)}{D(x)} = Q(x) + \frac{R(x)}{D(x)}\)

• Completing the square: For quadratic denominators

• Arctangent formula: \(\int \frac{1}{u^2 + a^2} du = \frac{1}{a}\arctan(\frac{u}{a})\)

• Logarithmic rule: \(\int \frac{f'(x)}{f(x)} dx = \ln|f(x)|\)

5 Complex completing the square
Exercise 5
Evaluate \(\int \frac{2x + 3}{x^2 + 6x + 10} dx\) using completing the square and substitution.
Definition:

Linear numerator with quadratic denominator: When the numerator is linear and the denominator is quadratic, complete the square and split into logarithmic and arctangent parts

Original function
\(f(x) = \frac{2x + 3}{x^2 + 6x + 10}\)
Complete the square
\(x^2 + 6x + 10 = (x+3)^2 + 1\)
Split numerator
\(\frac{2(x+3) - 3}{(x+3)^2 + 1}\)
Step 1: Complete the square in the denominator

For \(x^2 + 6x + 10\): Take coefficient of \(x\): \(6\), divide by 2: \(3\), square: \(9\)

\(x^2 + 6x + 10 = x^2 + 6x + 9 - 9 + 10 = (x + 3)^2 + 1\)

Step 2: Adjust the numerator

We want to express \(2x + 3\) in terms of \((x + 3)\):

\(2x + 3 = 2(x + 3) - 6 + 3 = 2(x + 3) - 3\)

Step 3: Split the integral

\(\int \frac{2x + 3}{x^2 + 6x + 10} dx = \int \frac{2(x + 3) - 3}{(x + 3)^2 + 1} dx\)

\(= \int \frac{2(x + 3)}{(x + 3)^2 + 1} dx - \int \frac{3}{(x + 3)^2 + 1} dx\)

Step 4: Integrate the first term

For \(\int \frac{2(x + 3)}{(x + 3)^2 + 1} dx\), let \(u = (x + 3)^2 + 1\), then \(du = 2(x + 3)dx\)

\(\int \frac{2(x + 3)}{(x + 3)^2 + 1} dx = \int \frac{1}{u} du = \ln|u| = \ln((x + 3)^2 + 1) = \ln(x^2 + 6x + 10)\)

Step 5: Integrate the second term

\(\int \frac{3}{(x + 3)^2 + 1} dx = 3\int \frac{1}{(x + 3)^2 + 1} dx = 3\arctan(x + 3)\)

Step 6: Combine results

\(\int \frac{2x + 3}{x^2 + 6x + 10} dx = \ln(x^2 + 6x + 10) - 3\arctan(x + 3) + C\)

\(\int \frac{2x + 3}{x^2 + 6x + 10} dx = \ln(x^2 + 6x + 10) - 3\arctan(x + 3) + C\)
Final answer:

\(\int \frac{2x + 3}{x^2 + 6x + 10} dx = \ln(x^2 + 6x + 10) - 3\arctan(x + 3) + C\)

Applied rules:

• Completing the square: \(x^2 + bx + c = (x + \frac{b}{2})^2 + (c - \frac{b^2}{4})\)

• Logarithmic rule: \(\int \frac{f'(x)}{f(x)} dx = \ln|f(x)|\)

• Arctangent rule: \(\int \frac{1}{u^2 + 1} du = \arctan(u)\)

• Substitution: Let \(u = x + h\) when denominator is \((x + h)^2 + k\)

Comprehensive Summary: Long Division & Completing the Square
\(\frac{P(x)}{D(x)} = Q(x) + \frac{R(x)}{D(x)}\)
Long Division Method
Key definitions:

Polynomial Long Division: A method to divide one polynomial by another, expressing the result as a quotient plus a remainder over the original divisor

Completing the Square: A technique to rewrite a quadratic expression in vertex form, making it easier to integrate

Rational Functions: Functions that can be expressed as the ratio of two polynomials

Complete methodology:
  1. Check degrees: If \(\deg(\text{numerator}) \geq \deg(\text{denominator})\), use long division first
  2. Apply long division: Divide polynomials to get a polynomial plus a proper rational function
  3. Factor denominators: Look for common factors or complete the square for quadratics
  4. Complete the square: Rewrite quadratic denominators in vertex form
  5. Split numerators: If needed, express the numerator in terms of the completed square
  6. Integrate: Apply appropriate formulas to each term
Tip 1: Always check if the numerator's degree is greater than or equal to the denominator's degree.
Tip 2: After completing the square, look for arctangent or logarithmic patterns.
Tip 3: For linear terms in the numerator after completing the square, use substitution.
Tip 4: Always verify your answer by differentiating the result.
Common applications: Integration of rational functions, solving differential equations, calculating areas and volumes, probability distributions.
Visualization: These techniques transform complex rational integrals into simpler forms.
Essential formulas to know by heart:

• Long Division: \(\frac{P(x)}{D(x)} = Q(x) + \frac{R(x)}{D(x)}\) where \(\deg(R) < \deg(D)\)

• Completing the Square: \(x^2 + bx + c = (x + \frac{b}{2})^2 + (c - \frac{b^2}{4})\)

• Arctangent: \(\int \frac{1}{u^2 + 1} du = \arctan(u) + C\)

• Logarithmic: \(\int \frac{f'(x)}{f(x)} dx = \ln|f(x)| + C\)

• General form: \(\int \frac{1}{(x-h)^2 + k^2} dx = \frac{1}{k}\arctan(\frac{x-h}{k}) + C\)

• Linear numerator: \(\int \frac{ax + b}{x^2 + px + q} dx\) requires splitting the numerator

Advanced Integration Techniques
Exercise 7: Complex Integrals
Evaluate using advanced techniques:
\(\int \frac{x^3}{x^2+1} dx\)
\(\int \frac{1}{x^2-4x+8} dx\)
\(\int \frac{3x-1}{x^2-2x+5} dx\)

Analysis: Advanced integration applications.

  • \(\int \frac{x^3}{x^2+1} dx = \int (x - \frac{x}{x^2+1}) dx = \frac{x^2}{2} - \frac{1}{2}\ln(x^2+1) + C\) (long division)
  • \(\int \frac{1}{x^2-4x+8} dx = \int \frac{1}{(x-2)^2+4} dx = \frac{1}{2}\arctan(\frac{x-2}{2}) + C\) (completing the square)
  • \(\int \frac{3x-1}{x^2-2x+5} dx = \int \frac{3(x-1) + 2}{(x-1)^2+4} dx = \frac{3}{2}\ln((x-1)^2+4) + \arctan(\frac{x-1}{2}) + C\) (split and complete)

Questions & Answers

Question: How do I know when to use long division vs completing the square?

Answer: Here's how to decide:

Use long division when:

  • The degree of the numerator is greater than or equal to the degree of the denominator

Use completing the square when:

Often, you'll use both: long division first to get a proper rational function, then completing the square for the remaining quadratic denominator.

Question: Why does completing the square work for integration?

Answer: Completing the square works because it transforms any quadratic expression into a standard form that we can integrate using known formulas:

Starting with \(ax^2 + bx + c\), completing the square gives us \(a(x + \frac{b}{2a})^2 + (c - \frac{b^2}{4a})\).

This form reveals whether the quadratic has real roots or complex roots:

  • If the constant term is positive, we get \((x+h)^2 + k^2\) which integrates to arctangent

The technique essentially converts the integral into a standard form that matches our known integration formulas.

Question: I often make mistakes with long division. How can I check my work?

Answer: Here are effective ways to check your long division:

Method 1: Verification by multiplication

Multiply your quotient by the divisor and add the remainder. You should get back the original numerator.

If \(\frac{P(x)}{D(x)} = Q(x) + \frac{R(x)}{D(x)}\), then \(P(x) = Q(x) \cdot D(x) + R(x)\).

Method 2: Degree check

The remainder must have a degree strictly less than the divisor.

Method 3: Substitution check

Pick a few values of \(x\) and verify that both sides of your equation give the same result.

Always verify your result by multiplying back!

Question: How are these techniques used in business applications?

Answer: These techniques are essential in business applications:

Continuous models: Integrating rational functions that model supply/demand relationships.

Probability distributions: Many continuous distributions involve rational functions requiring these techniques.

Optimization: When finding critical points of functions that involve ratios of polynomials.

Growth models: Integrating functions that model market saturation or adoption curves.

Finance: Calculating present values of cash flows with complex discounting functions.

These techniques are fundamental for any business model involving complex rational functions.

Question: How do these techniques apply to physics problems?

Answer: These techniques are fundamental in physics:

Field theory: Integrating rational functions that describe electric/magnetic fields.

Mechanics: Solving differential equations with rational function coefficients.

Quantum mechanics: Normalizing wave functions that involve rational expressions.

Thermodynamics: Integrating equations of state that involve rational functions.

Electronics: Analyzing circuits with complex impedance relationships.

These techniques are essential for solving any physics problem involving rational functions.