How do you find the integral of (x-1)/(x^2-4x+5)?

  • Thread starter Potatochip911
  • Start date
  • Tags
    Integral
In summary: I guess I just wasn't expecting there to be such a drastic difference in the different methods of solving itOkay thanks that makes sense. I guess I just wasn't expecting there to be such a drastic difference in the different methods of solving it.
  • #1
Potatochip911
318
3

Homework Statement


Find the integral of (x-1)/(x^2-4x+5)

Homework Equations



3. The Attempt at a Solution [/B]
After completing the square I get
∫(x-1)/((x-2)^2+1)*dx
Using substitutions x-2=tanθ; x-1=tanθ+1; dx=sec^2θ*dθ
∫[(tanθ+1)*(sec^2θ*dθ)]/(tan^2θ+1)
After cancelling
∫(tanθ+1)*dθ
integrating this I get
-ln(cosθ)+θ+C
ln(secθ)+θ+C
After substituting x back in
ln(x^2-4x+5)+arctan(x-2)+C
My answer key has a 1/2 infront of the natural log and I'm at a loss as to how they get it.
 
Physics news on Phys.org
  • #2
I think if you do the substitution properly, you will see that x^2-4x+5 = sec^2(θ), not sec(θ).
 
  • #3
phyzguy said:
I think if you do the substitution properly, you will see that x^2-4x+5 = sec^2(θ), not sec(θ).
I'm confused because with my substitution x^2-4x+5 turns into sec^2(θ) after using the identity tan^2(θ)+1=sec^2(θ)
 
  • #4
I think you misunderstood what phyzguy was saying. Here's what you wrote.
Potatochip911 said:
ln(secθ)+θ+C
After substituting x back in
ln(x^2-4x+5)+arctan(x-2)+C
My answer key has a 1/2 infront of the natural log and I'm at a loss as to how they get it.
Your substitution in the 3rd line above is wrong. sec(θ) = ##\sqrt{x^2-4x+5}##, not the ##x^2-4x+5## that you have. The 1/2 that you should be seeing comes from this square root.

Also, I would have done a substitution with u = x - 2 before doing the trig substitution. Doing that makes life simpler, IMO.
 
  • #5
Mark44 said:
I think you misunderstood what phyzguy was saying. Here's what you wrote.

Your substitution in the 3rd line above is wrong. sec(θ) = ##\sqrt{x^2-4x+5}##, not the ##x^2-4x+5## that you have. The 1/2 that you should be seeing comes from this square root.

Also, I would have done a substitution with u = x - 2 before doing the trig substitution. Doing that makes life simpler, IMO.
Whoops, yea I completely misunderstood and I will definitely try doing these with a u substitution for the x-a portion. Thanks!
 
  • #6
Potatochip911 said:
Whoops, yea I completely misunderstood and I will definitely try doing these with a u substitution for the x-a portion. Thanks!

Another approach is to split the integral up:

##\frac{x-1}{x^2-4x+5} = \frac{1}{2}\cdot \frac{2x - 4}{x^2-4x+5} + \frac{1}{x^2-4x+5}##

Then ##\frac{1}{2}ln(x^2-4x+5)## comes easily out of the first term as you have an exact derivative in the numerator.
 
  • #7
PeroK said:
Another approach is to split the integral up:

##\frac{x-1}{x^2-4x+5} = \frac{1}{2}\cdot \frac{2x - 4}{x^2-4x+5} + \frac{1}{x^2-4x+5}##

Then ##\frac{1}{2}ln(x^2-4x+5)## comes easily out of the first term as you have an exact derivative in the numerator.
Yea this is how wolfram alpha solved it but I figured it would be a good idea to understand both methods incase it's useful later on
 
  • #8
Equivalently, completing the square, [tex]x^2- 4x+ 5= x^2- 4x+ 4+ 1= (x- 2)^2+ 1[/tex]. Let y= x- 2 so that dy= dx and y+ 1= x- 1.
So [tex]\int \frac{x- 1}{x^2- 4x+ 5} dx= \int \frac{y+ 1}{y^2+ 1} dy= \int \frac{y}{y^2+ 1} dy+ \int\frac{1}{y^2+ 1} dy[/tex]
 
  • #9
HallsofIvy said:
Equivalently, completing the square, [tex]x^2- 4x+ 5= x^2- 4x+ 4+ 1= (x- 2)^2+ 1[/tex]. Let y= x- 2 so that dy= dx and y+ 1= x- 1.
So [tex]\int \frac{x- 1}{x^2- 4x+ 5} dx= \int \frac{y+ 1}{y^2+ 1} dy= \int \frac{y}{y^2+ 1} dy+ \int\frac{1}{y^2+ 1} dy[/tex]
Is it unusual that this integral can be solved in so many different ways?
 
  • #10
Potatochip911 said:
Is it unusual that this integral can be solved in so many different ways?
No, it happens fairly often. It's always true, though, that when you have two or more ways to evaluate an indefinite integral, the answers will differ by at most a constant. An example is ##\int sin(x)cos(x)dx##. One person can use a substitution u = sin(x), du = cos(x)dx. Another person can use a different substitution, u = cos(x), du = -sin(x)dx. When they integrate, they get what appear to be different answers, namely (1/2) sin2(x) + C and (-1/2)cos2(x) + C. However, since sin2(x) = 1 - cos2(x), it turns out that the two answers are different only by a constant.
 
  • #11
Mark44 said:
No, it happens fairly often. It's always true, though, that when you have two or more ways to evaluate an indefinite integral, the answers will differ by at most a constant. An example is ##\int sin(x)cos(x)dx##. One person can use a substitution u = sin(x), du = cos(x)dx. Another person can use a different substitution, u = cos(x), du = -sin(x)dx. When they integrate, they get what appear to be different answers, namely (1/2) sin2(x) + C and (-1/2)cos2(x) + C. However, since sin2(x) = 1 - cos2(x), it turns out that the two answers are different only by a constant.
Okay thanks that makes sense.
 

1. What is the general formula for the integral of (x-1)/(x^2-4x+5)?

The general formula for the integral of (x-1)/(x^2-4x+5) is ∫(x-1)/(x^2-4x+5) dx = (1/2)ln|x^2-4x+5| + C.

2. How do you solve the integral of (x-1)/(x^2-4x+5)?

To solve the integral of (x-1)/(x^2-4x+5), you can use the substitution method or partial fractions. Using substitution, let u = x^2-4x+5, then du = (2x-4)dx. Substituting these values into the integral, we get ∫(x-1)/(x^2-4x+5) dx = (1/2)∫du/u + C = (1/2)ln|u| + C = (1/2)ln|x^2-4x+5| + C.

3. Is there a shortcut for solving the integral of (x-1)/(x^2-4x+5)?

Yes, there is a shortcut for solving the integral of (x-1)/(x^2-4x+5) using partial fractions. First, factor the denominator into (x-1)(x-5). Then, set up the equation (x-1)/(x^2-4x+5) = A/(x-1) + B/(x-5). Solving for A and B, we get A = 1 and B = -1. Substituting these values back into the equation, we get ∫(x-1)/(x^2-4x+5) dx = ∫(1/(x-1) - 1/(x-5)) dx = ln|x-1| - ln|x-5| + C = ln|(x-1)/(x-5)| + C.

4. Are there any restrictions when solving the integral of (x-1)/(x^2-4x+5)?

Yes, there are restrictions when solving the integral of (x-1)/(x^2-4x+5). The denominator, x^2-4x+5, cannot have any real roots. In other words, the quadratic equation x^2-4x+5 = 0 should have no real solutions. If the equation does have real solutions, then the integral cannot be solved using the given formula and another method, such as partial fractions, must be used.

5. Can the integral of (x-1)/(x^2-4x+5) be solved using integration by parts?

No, the integral of (x-1)/(x^2-4x+5) cannot be solved using integration by parts. Integration by parts is applicable for integrals where one term can be differentiated and the other can be integrated. However, in this case, both terms (x-1) and (x^2-4x+5) cannot be differentiated or integrated separately, making integration by parts not applicable.

Similar threads

  • Calculus and Beyond Homework Help
Replies
6
Views
912
  • Calculus and Beyond Homework Help
Replies
2
Views
880
  • Calculus and Beyond Homework Help
Replies
3
Views
350
  • Calculus and Beyond Homework Help
Replies
12
Views
2K
  • Calculus and Beyond Homework Help
Replies
10
Views
458
  • Calculus and Beyond Homework Help
Replies
5
Views
1K
  • Calculus and Beyond Homework Help
Replies
3
Views
957
  • Calculus and Beyond Homework Help
2
Replies
54
Views
8K
Replies
3
Views
1K
  • Calculus and Beyond Homework Help
Replies
4
Views
1K
Back
Top