1. Limited time only! Sign up for a free 30min personal tutor trial with Chegg Tutors
    Dismiss Notice
Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Integral of (x-1)/(x^2-4x+5)

  1. Mar 24, 2015 #1
    1. The problem statement, all variables and given/known data
    Find the integral of (x-1)/(x^2-4x+5)

    2. Relevant equations

    3. The attempt at a solution

    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.
     
  2. jcsd
  3. Mar 24, 2015 #2

    phyzguy

    User Avatar
    Science Advisor

    I think if you do the substitution properly, you will see that x^2-4x+5 = sec^2(θ), not sec(θ).
     
  4. Mar 24, 2015 #3
    I'm confused because with my substitution x^2-4x+5 turns into sec^2(θ) after using the identity tan^2(θ)+1=sec^2(θ)
     
  5. Mar 24, 2015 #4

    Mark44

    Staff: Mentor

    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.
     
  6. Mar 24, 2015 #5
    Whoops, yea I completely misunderstood and I will definitely try doing these with a u substitution for the x-a portion. Thanks!
     
  7. Mar 25, 2015 #6

    PeroK

    User Avatar
    Science Advisor
    Homework Helper
    Gold Member

    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.
     
  8. Mar 25, 2015 #7
    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
     
  9. Mar 25, 2015 #8

    HallsofIvy

    User Avatar
    Staff Emeritus
    Science Advisor

    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]
     
  10. Mar 26, 2015 #9
    Is it unusual that this integral can be solved in so many different ways?
     
  11. Mar 26, 2015 #10

    Mark44

    Staff: Mentor

    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.
     
  12. Mar 26, 2015 #11
    Okay thanks that makes sense.
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Have something to add?
Draft saved Draft deleted



Similar Discussions: Integral of (x-1)/(x^2-4x+5)
Loading...