If the integral of $c/x$ is $c.log(x)+C$ what is the base?

211 Views Asked by At

This question is a follow up to an answer I gave here: What is the correct integral of $\frac{1}{x}$? After the algebra I said that 'This step of course gives the argument of $\log(x)$ the value $e$... and note that so far we have not specified a base for $\log(x)$ - the proof is true using any logarithm. For convenience we therefore give $\log(x)$ the base $e$ and denote it $\ln(x)$; consequently $\ln′(x)=1/x$ but given another base the numerator would be different.' And then quoted wikipedia which said the same thing in a different way. However WolframAlpha says '$\log(x)$ is the natural logarithm' when they give the answer in the title. So who is wrong? And why?

EDIT - I did some tests using the following python3 script:

from math import log    #log is ln by default in python

#[c/(xp+ep) - c/xp]/ep = -c/(xp**2+ep*xp): finite derivative of 1/x
def numerint(a, b, c, eps):
    ep = (b - a)/eps    #one epsilon
    intg = 0            #the numerical integral
    xp = a              #the current x point
    for x in range(eps):
        intg += c/xp*ep - 1/2*ep**2*c/(xp**2 + ep*xp)
        xp += ep
    print('Numerical integral of 1/x:', intg)
    intgcalc = log(b) - log(a)
    print('ln(b) - ln(a):', intgcalc, intg/intgcalc)

numerint(0.5, 2.5, 3, 10000)
#The derivative is log(e)/x to any base, what base can be raised by c to yield e?

The objective is to see what happens when we change the third numerint argument, set at 3 above. The third print statement in this case gives 3; in general it gives c. This means that even though the base of the logarithm is undetermined we can write it as a natural logarithm and just multiply it by $c$ instead of writing it in a different base. Wikipedia: 'Logarithms can be defined to any positive base other than 1, not only e. However, logarithms in other bases differ only by a constant multiplier from the natural logarithm, and are usually defined in terms of the latter.'

2

There are 2 best solutions below

8
On BEST ANSWER

The base is the one that satisfies

$$\begin{align*} \frac1x &= \frac{d}{dx}\log_a x\\ &=\lim_{h\to0}\frac{\log_a(x+h)-\log_a x}{h}\\ &= \lim_{h\to0}\log_a\left(1+\frac hx\right)^{1/h}\\ &= \lim_{h\to0}\log_a\left(1+\frac hx\right)^{x/hx}\\ &= \frac1x\log_a\left[\lim_{h\to0}\left(1+\frac hx\right)^{x/h}\right]\\ \end{align*}$$

It happens that the limit is special enough to have a name $e$. If $a\ne e$, then there is an ugly scaling constant $\log_a e$ on the right hand side; otherwise, that constant $\log_e e = 1$.

So, $a$ is the base chosen to make $\frac{d}{dx}\log_a x$ free of scaling constants other than $1$.

6
On

It is the natural log! Think about it this way.

Let $y=\ln(x)$. It follows that $e^y=x$. From there, we can differentiate implicity; $y'*e^y=1$. Now, $e^y=x$, so $x*y'=1$, and $y'=1/x$.