6
$\begingroup$

What is gap $\log(n+1)-\log(n)$ between log of consecutive integers? That is what precision of logarithms determines integers correctly?

$\endgroup$
  • 4
    $\begingroup$ You should specify the base. All answers are assuming base e, because if you mean base 10 most answers are wrong (by a fixed constant) $\endgroup$ – user Jul 22 '18 at 18:52
20
$\begingroup$

$\log(n+1)-\log n=\log(1+\frac1n)$. Using the Taylor series for $\log(1+x)$, this is $$\frac1n-\frac1{2n^2}+\frac1{3n^3}-\cdots\approx\frac1n.$$

$\endgroup$
16
$\begingroup$

Especially Lime's answer is absolutely correct and a very good approach. Let me show a conceptually somewhat simpler one, that only uses the derivative, namely $(\log x)'=1/x$. This is a strictly decreasing function, so $\log x$ is concave. In particular, its graph is below the tangent line at any point of the graph.

We obtain $\log (n+1)< \log n + 1/n$ and $\log n< \log (n+1) - 1/(n+1)$. To sum up:

$$\frac{1}{n+1} < \log (n+1)-\log n < \frac{1}{n}$$

$\endgroup$
9
$\begingroup$

This is rather similar to previous answers, but I think it's still worth pointing out. You're asking about the slope of a chord of the graph of $\log x$, the chord joining $(n,\log n)$ to $(n+1,\log(n+1))$. By the mean value theorem, this equals the slope of the tangent line, $1/x$, at some $x$ between $n$ and $n+1$.

$\endgroup$
8
$\begingroup$

Just added for your curiosity.

In the same spirit as in other answers, instead of Taylor series, you could consider Padé approximants and get things such as $$\log(n+1)-\log n=\log\left(1+\frac1n\right) \approx \frac{2}{2 n+1}$$ $$\log(n+1)-\log n=\log\left(1+\frac1n\right) \approx \frac{6 n+3}{6 n^2+6n+1}$$ $$\log(n+1)-\log n=\log\left(1+\frac1n\right) \approx \frac{60 n^2+60 n+11 } {60 n^3+90 n^2+36 n+3 }$$ $$\log(n+1)-\log n=\log\left(1+\frac1n\right) \approx \frac{420 n^3+630 n^2+260 n+25 }{420 n^4+840 n^3+540 n^2+120 n+6 }$$

These are respectively equivalent to Taylor series to $O\left(\frac{1}{n^3}\right)$, $O\left(\frac{1}{n^5}\right)$, $O\left(\frac{1}{n^7}\right)$ and $O\left(\frac{1}{n^9}\right)$.

$\endgroup$
5
$\begingroup$

Here's a geometric way to get a good approximation for $\ln(n+1)-\ln(n)$:

Use the fact that $\ln(x)=\int_1^x \frac1t dt$. (For $x>0$.)

Then $\ln(n+1)-\ln(n)$ is the area under the curve $f(x)=\frac1x$ from $n$ to $n+1$.

We are looking for the area over an interval of length $1$. So numerically the area should be equal to the 'average' height. Because the $\frac1x$ function is strictly decreasing, we get a good approximation to that 'average' height by evaluating the $\frac1x$ function a the midpoint of the interval (namely at $n+\frac12$).

So $\ln(n+1)-\ln(n)\approx \frac{1}{n+\frac12}$, with the approximation getting better and better as $n$ gets large.

$\endgroup$
  • 1
    $\begingroup$ Notice that $\frac{1}{n+1/2}$ is the same as the Padé approximant given in @ClaudeL's answer of $\frac{2}{2n+1}$! $\endgroup$ – Silverfish Jul 22 '18 at 23:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.