# How to compare logs without a calculator

I have multiple different log sums that I need to evaluate. How would I calculate the following without using a calculator or log tables?

-
What exactly are you trying to compare? Just by inspection $x=z$. – copper.hat May 12 '12 at 17:39

Define the function $f:(0,1) \rightarrow \mathbb{R}$ by $f(x) = -(x \log(x) + (1-x) \log(1-x))$.

Note that $$f(x) = f(1-x)$$ Then$$f'(x) = \log(1-x) - \log(x)$$ And$$f''(x) = -(\frac{1}{x}+\frac{1}{1-x})$$ It follows from this that $f$ hits a maximum at $x=\frac{1}{2}$, is strictly increasing on $x<\frac{1}{2}$.

Your problem is (presumably) to compare $x = f(\frac{2}{5})$, $y = f(\frac{1}{5})$ and $z = f(\frac{2}{5})$. Note that $\frac{1}{5} < \frac{2}{5} < \frac{1}{2}$. Hence $y < x = z$.

-

Here's another way to show that $x>y$ that doesn't require a calculator - only rules of logarithms and the inequality $4>3$. Notice that $$x = -\frac25(\log 2-\log 5) - \frac35(\log 3-\log 5) = \log 5 - \frac25\log 2 - \frac35\log 3,$$ and similarly $y = \log 5 - \frac45\log 4 = \log 5 - \frac85\log 2$. Therefore the following inequalities are all eqiuvalent to one another: $$x>y$$

$$\log 5 - \frac25\log 2 - \frac35\log 3 > \log 5 - \frac85\log 2$$

$$\frac25\log 2 + \frac35\log 3 < \frac85\log 2$$

$$\frac35\log 3 < \frac65\log 2$$

$$\log 3 < 2\log 2$$

$$3 < 2^2.$$

-