1. Not finding help here? Sign up for a free 30min 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!

Integration by parts problem

  1. Jul 18, 2017 #1
    1. The problem statement, all variables and given/known data
    ##\displaystyle \int \frac{\log (x)}{x}~ dx##

    2. Relevant equations


    3. The attempt at a solution
    I am a little confused about the first part. We know that the ##\displaystyle \int \frac{1}{x}~ dx = \log |x|##. So how can we proceed with integration by parts if one of the logs has an absolute value and the other doesn't? Wouldn't we just end up with ##\log |x| \log (x) - \int \frac{\log |x|}{x} ~ dx##?
     
  2. jcsd
  3. Jul 18, 2017 #2

    scottdave

    User Avatar
    Homework Helper
    Gold Member

    The argument of log(x) must be greater than zero, for real results. Since log(x) is in the integral, then we must have x > 0, so log(x) and log|x| will be the same thing.
     
  4. Jul 18, 2017 #3

    andrewkirk

    User Avatar
    Science Advisor
    Homework Helper
    Gold Member

    Unless you are operating in the context of complex numbers you can forget about the absolute value because ##\log x## is only defined for positive ##x##.

    So, restricting the domain to ##\mathbb R_+## your last formula becomes
    $$\int\frac{\log x}xdx=(\log x)^2 - \int\frac{\log x}xdx$$
    which you can then solve.

    EDIT: Jinxed again!
     
  5. Jul 18, 2017 #4
    That makes sense. What about in the case when we start out with something like ##\displaystyle \int \frac{\sin x}{\cos x} \log (\cos x)##? Do we just assume that x is in the domain such that ##\cos x## is greater than 0?
     
  6. Jul 18, 2017 #5

    andrewkirk

    User Avatar
    Science Advisor
    Homework Helper
    Gold Member

    Yes. But more care is needed in that case, because, unlike the previous example, the domain is not topologically connected, being a series of open sets of the form ##\left(\frac{4k-1}2\pi,\frac{4k+1}2\pi\right)## for ##k\in\mathbb Z##.

    Many of the uses to which one might put an indefinite integral would be invalidated if one were to use it for values of ##x## that are in different (separated) components of that domain.

    So it would be safest to specify a particular component, eg restricting the solution to the interval ##(-\pi/2,\pi/2)##.
     
  7. Jul 18, 2017 #6

    LCKurtz

    User Avatar
    Science Advisor
    Homework Helper
    Gold Member

    @Mr Davis 97 I assume you are aware that, even though integration by parts works pretty easily, the more "obvious" method would be the substitution ##u = \log x,~du = \frac 1 x dx##.
     
  8. Jul 19, 2017 #7
    Huh, in all my years of taking Calculus, it never occurred to me that ##ln(x)## and ##log(x)## share the same derivative...
     
  9. Jul 19, 2017 #8

    andrewkirk

    User Avatar
    Science Advisor
    Homework Helper
    Gold Member

    I think you might be interpreting the references above to ##\log x## as being log base 10. They are not, they are references to the log base ##e## or natural logarithm. My impression is that the practice of interpreting ##\log x## to mean log base 10 and using ln for the natural log started to fade out when pocket calculators started to replace logarithm tables and slide rules so that there was no common reason to refer to a log base 10. Perhaps it is still used in engineering.
     
  10. Jul 19, 2017 #9

    Mark44

    Staff: Mentor

    Both of my calculators (small Casio scientific and an aged HP 48G) and the Windows calculator I use a lot have separate log and ln buttons. The meaning of "log" depends on the surrounding context -- in post-calculus textbooks, "log" is often taken to mean ##\log_e## or ##\ln##. In computer science texts, "log" usually means ##\log_2##.
     
  11. Jul 19, 2017 #10

    scottdave

    User Avatar
    Homework Helper
    Gold Member

    WolframAlpha assumes log(x) refers to natural log. You can type in ln or LN, if you want. It will change it to log, though.
    I loved my HP 48G. The display on mine is going out. A few years ago I got an HP 50G. Not quite an upgrade, in my opinion, though.
    The way I was taught in school was to put the subscript log2(x) where 2 is the base. But if nothing then base 10 was implied, then ln means log base e (natural log).
     
  12. Jul 19, 2017 #11

    scottdave

    User Avatar
    Homework Helper
    Gold Member

    I have yet to see a calculator put LOG on a button to calculate the natural log. Sure, the days of using log tables are pretty much gone, but base 10 logarithms are still used, like in pH scale and dB, for example.
    Any time you need to display a chart of graph spanning a large range of values (like the electromagnetic spectrum), often the logarithmic scale (base 10) is used to display the wide range.
     
  13. Jul 19, 2017 #12

    Mark44

    Staff: Mentor

    Same here.

    Ditto for this, as well.
     
  14. Jul 19, 2017 #13

    andrewkirk

    User Avatar
    Science Advisor
    Homework Helper
    Gold Member

    I haven't had a calculator since my beloved HP 12C died a long while back. If I need to calculate some numbers I can't do in my head I typically use R, which is usually open on my computer, or Wolfram Alpha - both of which interpret 'log' to mean log base e.

    I rarely use Excel but I just checked with that and found that it interprets log as log base 10.

    So I suppose it all depends on what one is used to.
     
  15. Jul 20, 2017 #14

    LCKurtz

    User Avatar
    Science Advisor
    Homework Helper
    Gold Member

    And, of course, as far as this thread is concerned, the only thing that matters is that the OP, who hasn't returned since we got on this track, understands that answer needs an appropriate fudge factor if we aren't talking about natural logarithms.
     
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: Integration by parts problem
Loading...