# How are we able to take the log of both sides of the equation?

1. Feb 8, 2010

### Juwane

Here is an equation:

$$x^3 + 1 = 3^x$$

We have no problem of taking ln of both sides, right?

But if we write the equation as

$$x^3 - 3^x + 1 = 0$$

Now let's take ln of both sides

$$ln ( x^3 - 3^x + 1 ) = ln (0)$$

But ln (0) is undefined.

My question is: After just taking 3x to the other side, how does the equation become into a one of which we're not able to take the log of both sides?

2. Feb 8, 2010

### snipez90

This is not that hard to conceptualize is it? Presumably, writing the equation in the second form means that you are attempting to find x for which the equation is 0. But any solutions will obviously give you 0, and we already know ahead of time that ln(0) is undefined. You could have used a simpler example:

x = 1 implies ln(x) = 0, but x - 1 = 0, so clearly you cannot take the natural log of both sides.

3. Feb 11, 2010

### Redbelly98

Staff Emeritus
Similarly, we cannot take the reciprocal of both sides of the second equation in the OP, while we can for the first equation.

4. Feb 11, 2010

### Hurkyl

Staff Emeritus
Actually there is a problem -- this is an equation of real numbers, but we are only allowed to apply the logarithm to positive real numbers.

So, we have to split the problem into two cases:
Case 1: x3+1=3x and 3x > 0
Case 2: x3+1=3x and 3x <= 0

(I've done some simple algebra to reduce the number of cases from four to two)

In the first case, we can take the log of both sides, because we have the guarantee that both sides are positive. We have to find other (but very easy) means to deal with the second case.

5. Feb 11, 2010

### sutupidmath

when exactly does this happen in R?

6. Feb 11, 2010

### Hurkyl

Staff Emeritus
I did say there were very easy means to deal with this case.

7. Feb 11, 2010

### JSuarez

You may also see like this: the equality:

$$x^3 + 1 = 3^x$$

Is an equality between two functions, and we want to determine the set of values of $x$ such that both sides make sense and the equality is true. In this case, it's possible to compose the functions on both sides (casting aside the sign issue for the left side) with $log$, because the image of $3^x$ is contained in the domain of $\rm{log}$.

But in the case:

$$x^3 - 3^x + 1 = 0$$

We have a different equality, with different functions on both sides, and for one of these, the 0 function on the right, its image set is disjunct from the logarithm's domain, so it's not possible to apply $\rm{log}$.

8. Feb 12, 2010

### Tac-Tics

Here is your mistake: $$ln ( x^3 - 3^x + 1 )$$ is undefined too.

When we say ln(0) is undefined, we don't just mean when you see it spelled el-en-of-zero.

You see this trick in a lot of "false proofs". You can use variables to sort of "hide" zeros from people's attention. Remember that $$\frac{x}{x}$$ does NOT equal 1! I mean, it's USUALLY equal to 1. But not always.

You might also consider the fine print on the log rules you learned in school:

ln(xy) = ln x + ln y ONLY IF x and y are both nonzero.

ln(xy) = y ln x ONLY IF x is nonzero

Those kinds of clauses tend to get forgotten in the heat of the moment.