10
$\begingroup$

The inconsistency I see between mathematical subjects is really confusing me. I understand that it isn't possible for $e^x$ to be less than zero for real $x$, which is probably why they say that the integral is $\ln(|x|)$.

Before I ramble on too much, I just want to ask: Is there a set of guidelines to follow to help me choose whether to let the integral of $\frac{1}{x}$ equal to $\ln(x)$ or $\ln(|x|)$?

Thanks, Aralox

  • 0
    $\,\ln|x|+C\,$ , with $\,C\,$ a constant2012-11-11
  • 3
    And no: it is true that $\,e^x>0\,$ for *all* reals.2012-11-11
  • 0
    Yes I forgot to mention the constant, and yes it can't equal zero either - thanks. I am concerned about whether the argument of the natural log has to be within absolute value brackets. EDIT: More specifically, is there ever a time when it can be written without abs brackets?2012-11-11
  • 2
    Well @Aralox: you can write the argument of the logarithm (to any base) without the absolute value if you make clear, of if you're given, that the argument is positive, otherwise you *must* use the abs. value. You can drop this requirement if you work with the complex logarithm function, which perhaps you haven't yet studied.2012-11-11
  • 1
    Yes! That's the answer I am looking for! I already understand that the abs brackets can be dropped if x is positive, but I was looking for more. I remember studying the principal logarithm a few months back, and understand that Ln(z) = ln|z| + iArg(z). Could you show me how to integrate 1/x using it?2012-11-11
  • 0
    @DonAntonio: I'd say that $\ln x+C$ makes little sense. Why choose the same constant for $x<0$ and $x>0$? (See Rahul's and countinghaus' answer.)2012-11-11
  • 0
    Who said it "has" to be the same constant? It is a generaic letter for a constant. If one wants to take x > 0 on one hand and on the other x < 0 then use different letters..or not. I don't think this is important.2012-11-11
  • 0
    @DonAntonio: When you write that the integral is $\ln\lvert x\rvert + C$ for all $x$, you are implicitly asserting that $C$ is the same for all $x$. Otherwise, how would I know that I can't take a different $C$ for, say, $x\le 1$ and $x>1$?2012-11-11
  • 1
    Hmm if I integrate 1, and get x + C, wouldnt f(x) = x + 5 for 1 < x < 4 and x + 15 elsewhere be perfectly valid too? i.e. just saying 'x + C' already implies that you can let C equal to whatever wherever you like?2012-11-11
  • 0
    @RahulNarain , you can ask *exactly* the same question about the integration constant for *any* integrable function.2012-11-12
  • 0
    @DonAntonio: I don't understand. Can you address Aralox's latest comment? Is $f(x) = x + C$, where $C=5$ when $1 and $C=15$ elsewhere, an antiderivative of $x\mapsto1$?2012-11-12
  • 1
    Once again, @RahulNarain: the moment you determine some conditions on the function you *already* determine the integration constant! I really can't understand what the problem here is...though perhaps I'm missing something, of course.2012-11-12
  • 0
    @DonAntonio: I can't continue this discussion with you if you won't answer the simple question Aralox and I have asked.2012-11-12
  • 1
    Too bad you didn't understand I did answer, in particular in my very last post. Have a good day, @RahulNarain2012-11-12
  • 0
    Oh well. You have a great day too, @Don! :)2012-11-12

7 Answers 7

18

Strictly speaking, any function of the form $$F(x) = \begin{cases} \ln x + c_1 & \text{if } x > 0, \\ \ln (-x) + c_2 & \text{if } x <0 \end{cases}$$ defined over $\mathbb R \setminus \{0\}$ is a valid antiderivative. Verify this by differentiating $F(x)$ and getting $F'(x) = 1/x$ back for any $x \ne 0$.

The usual formula, $\ln\lvert x\rvert + c$, is what you get when you pick $c_1 = c_2 = c$. Alternatively, as @Joe says, when you're only considering positive $x$, you can just write $\ln x + c$.

  • 0
    Bravo. Because the domain of $1/x$ consists of two connected components, the constant of integration *must* be allowed to be different on the two. Not to do so ignores the message and content of the theorem that tells us what the antiderivatives of a continuous function defined on an interval may be.2012-11-13
  • 0
    and if you pick $c_2= c_1 + i \pi$ then you get the answer $\log z$ with the conventional branch choice of the complex logarithm.2014-07-07
  • 0
    Also, if someone can explain what DonAntonio was trying to tell me in the comments on the question, I'd much appreciate it... It's hard to communicate on the internet.2015-01-11
5

In general, it is safe to always write:

$$\int \frac{1}{u} \ du = \ln \left| u \right| +C $$ where $C$ is some constant.

However, if the function is always positive $\forall x \in \Bbb R\setminus \{0\}$ (assuming that's what you're integrating over), you can drop the absolute value.

Addendum of Complex Logarithm

I think this will be helpful since you wanted to know how to integrate with the complex log. Also, this should be a good read. I'd start around page 74 for what you're looking for.

I feel it might help to note that if we say $\log z$ is any logarithm along some branch $B$, then $(\log z)' = \dfrac{1}{z} \forall z$ not on $B.$ However, no matter how we define the complex logarithm, there will always be some branch that is not holomorphic.

  • 0
    Thanks Joe! that almost immediately answered my question about how it its multivalued, and what exactly the 'principal value' means. Also, I had a read of the wikipedia article a few times, but I don't have a good grasp of what a branch is. Could you give it to me in simple terms?2012-11-11
  • 0
    A branch is some portion of the range of a mutlivalued function in which the function is single-valued. A branch cut is a curve in $\Bbb C$ where a multifunction (a multivalued function) is discontinuous. For learning more about branch cuts, take a look at this question: http://math.stackexchange.com/questions/37764/references-for-learning-about-branch-cuts-branch-points-in-complex-analysis2012-11-11
  • 0
    Thanks again. Would I be right in saying that by limiting the Arg(z) in "Ln(z) = ln|z| + Arg(z)i" to (-pi, pi], that would be a branch?2012-11-11
3

Equal to $\ln(|x|)$+c, in which $c$ is constant.

  • 1
    @DonAntonio: I'd say that $\ln x+C$ makes little sense. Why choose the same constant for $x<0$ and $x>0$? (See Rahul's and countinghaus' answer.)2012-11-11
  • 2
    I've already addressed this question...and I find very weird that you keep on asking me the same under other people's answers.2012-11-12
  • 0
    This is incomplete, if not incorrect. See Rahul's answer.2015-01-11
3

The correct answer is$\int \frac1x dx= \ln |x| +C$

The absolute value is sometimes omitted in ODE problems. As for guidelines I would say analyze the problem and see if values of x will be out of the domain when solved.

  • 0
    @DonAntonio: I'd say that $\ln x+C$ makes little sense. Why choose the same constant for $x<0$ and $x>0$? (See Rahul's and countinghaus' answer.)2012-11-11
  • 0
    I've already addressed this question.2012-11-12
  • 0
    This is incomplete, if not incorrect. See Rahul's answer.2015-01-11
2

I think the introduction of complex variables here is unnecessary. The function $1/x$ is a perfectly well-defined function on $\mathbb{R} \setminus \{0\}$ and we can ask if it has an antiderivative on that set. On the positive real axis, $\log(x)$ is an antiderivative. On the negative real axis, $\log(-x)$ is an antiderivative (and $\log(x)$ doesn't make sense). This is confusing, so we write $\log(|x|)$ so that we don't have to remember. Note that $\log(|x|) + C$ is not good notation, since the constant can be different on the negative and positive real axes.

1

I remember studying the principal logarithm a few months back, and understand that Ln(z) = ln|z| + iArg(z). Could you show me how to integrate 1/x using it?

Right, and this is why the "most" correct answer is that $\ln(x)$ would be the antiderivative, considered as a function over the complex numbers (still not defined at zero). So that (as an example) one could use $\ln(-x)=\ln(x)+i\pi$ in the manner of Rahul's answer (with $c_2=i\pi$, which Euler wonderfully treats as a constant to ignore in some of his papers).

This has the problem that it's a multivalued function, but has the advantage that this enables one to choose a consistent branch to integrate over all sorts of interesting contours.

For instance, then the integral of $1/x$ over the unit circle (in $\mathbb{C}$) has to follow from $\ln(1)=0$ to $\ln(1)=2\pi i$ giving $2\pi i-0 = 2\pi i$, where I've here really followed the function up the Riemann surface, as it were - obviously not a function any more. Not how we usually think of the FTC, granted! But that really is the value of the contour integral.

See http://www.ma.utexas.edu/maxima/maxima_13.html for one CAS' solution to this issue.

  • 0
    Thank you, that makes so much sense. So in the end I can leave off the abs brackets if I state that my constant is in C rather than R. Could you please give me some examples of its multivalued nature? It's confusing me a little. Unfortunately I don't quite understand the curve integral/Riemann surface you described (although it sounds quite interesting, and I believe I am going to cover it in one of my future units). I have studied how to integrate these things using the sum of residues however. What does FTC stand for?2012-11-11
  • 1
    @Aralox and kcrisman: I'm sorry to say this, but I think that this answer doesn't make so much sense. There's no $\ln x$ for negative $x$ in Rahul's answer, and $\ln(-x)=\ln x+i\pi$ is true only for certain branches of the complex logarithm. Moreover, $\ln x$ isn't _the_ antiderivative, but only _an_ antiderivative (cf. Rahul's answer). Finally, if I only look at the question, then taking about complex number only introduces unnecessary confusion here. I'd go with Rahul's answer, Aralox.2012-11-11
  • 0
    I can see how there should rightly be separate constants for the positive and negative real axis, and that this assumes that they are the same (like a few of the existing answers below). However kcrisman's answer gave me the complex viewpoint that I was looking for. If somehow I could combine his, Rahul's and Joe's answers together, it would be perfect.2012-11-11
  • 0
    Actually I'm rethinking this again - the constant does take into account the pos/neg x axis if it is complex2012-11-11
  • 0
    I'm not suggesting $\ln(-x)=\ln(x)+i\pi$ all the time, just that in Rahul's answer that's how one could interpret this. But I see how that could have been misinterpreted, so I'll edit the answer - thanks.2012-11-13
0

On the negative axis their difference is a constant. Both are antiderivatives.

  • 0
    Hmm. As real functions only one is defined on the negative axis. As complex functions one is not holomorphic and thus cannot be an antiderivative. I don't see how to reconcile these facts with your answer.2015-01-11
  • 0
    $\log(x)$ on the negatives is the restriction of a holomorphic branch of $\log(z)$ on $\mathbb{C}\backslash\{0\}$, preferably mapping to $\mathcal{Im} \zeta = \pm \pi$ so it coincides on $(0,\infty)$ with the usual $\log$. For instance, $\log(-3) = \log 3 + i \pi$. The equality $\log(z)' = \frac{1}{z}$ ( for any branch one takes) is valid for complex derivatives so also for real derivatives.2015-01-11
  • 0
    I know what you mean. My point was that $\log(|z|)$ is nowhere holomorphic, and it wasn't IMO clear exactly which two functions you refer to, when you say *Both are antiderivatives*.2015-01-11