# A petite observation about logarithms

1. Nov 15, 2005

### homology

Here's something cute:

Consider the graph of ln(x^2) and then consider the graph of 2ln(x), missing anything?

I was momentarily caught off guard by this until I realized that when we derive the property: ln(x^a)=aln(x), we choose the positive root.

Has anyone ever run into a situation where it was better to say that ln(x^2)=2ln|x| ?

2. Nov 15, 2005

### Lonewolf

Well, consider the case x < 0. Then ln(x^2) is real, but 2ln(x) has a non-zero imaginary part, so clearly they can't be equal.

3. Nov 15, 2005

### HallsofIvy

Yes, that's a very good point.

Solving the equation ln(x^2)= 0 is NOT the same as solving 2ln(x)= 0 and, yes, it is better to write ln(x^2)= 2ln(|x|).

4. Nov 20, 2005

### D H

Staff Emeritus
On most computers it is not better to write ln(x^2) instead of 2ln(|x|) in a computer program.

5. Nov 20, 2005

### HallsofIvy

I'm sorry, what does that have to do with my response? My point was NOT that it was better to write ln(x^2) rather than 2ln(|x|) but rather that it was better to write ln(x^2)= 2ln(|x|) rather than ln(x^2)= 2ln(x).