I'm not sure if this is the right forum to place this in, I know most of you on the forum should be able to deal with this kind of stuff in your sleep, but it's an Advanced Topic to me.

About 10 minutes ago, for some reason unknown to me, I developed an interest in Complex Logarithms (I don't know if that's what it's called). I am talking about taking the logs of negative numbers and complex numbers. I browsed a few sites, including wikipedia, but most of the stuff flew over my head, I was hoping someone here could dumb it down for me. I will expound all that I have gotten from my "research" and hopefully someone can fill in the gaps.

Here's some background knowledge for the small percentage of readers that actually know less about this topic than I do.

Background:

There is a nifty little thing that we callEuler's Formula, which can be derived by using Taylor Series (among other things I suppose). The formula states that:

$\displaystyle \boxed { e^{i \theta} = \cos \theta + i \sin \theta }$

where $\displaystyle i$ is the imaginary unit, specifically, $\displaystyle i = \sqrt {-1}$

Using this formula, we can derive what is perhaps the most aesthetic identity in all of Math, this identity is known asEuler's Identity.

Euler's Identity:

$\displaystyle \boxed { e^{i \pi} + 1 = 0 }$

Or as it is usually stated:

$\displaystyle \boxed { e^{i \pi} = -1 }$

We obtain this beautiful identity by simply plugging in $\displaystyle \pi$ for $\displaystyle \theta$ in Euler's Formula.

Another thing the reader should be aware of is how to represent a complex number in polar coordinates. This is (relatively) easy if we do so by the use of an Argand Diagram.

Recall that a Complex Number is a number made up of a real number component and a imaginary number component. The sum of these components form the complex number. In an Argand diagram, we set up a vertical and a horizontal axis much like the familiar Cartesian axis', but with different meaning. The horizontal axis represents the real number line, while the vertical axis represents the imaginary number line. Any point on the imaginary axis is purely imaginary (that is, the real component of any complex number represented in this way is zero), any point on the horizontal axis is purely real (the imaginary part of the complex number is zero), and any point that is not on either axis represents a complex number, that is, one of its coordinates will represent the real part of the complex number (the first number in the coordinate pair), and the other coordinate represents the imaginary part of the complex number. For the sake of familiarity, we will use $\displaystyle x$ to represent a number on the real (horizontal) axis and use the variable $\displaystyle y$ to represent a number on the imaginary (vertical) axis.

We define $\displaystyle r$ to be the length of the line that connects the origin to any point in the Argand-plane. We can find the value of $\displaystyle r$ using Pythagoras' Theorem. And we can find the angle that $\displaystyle r$ makes with the real axis using the tangent ratio. In doing so, we can define any complex number much like the way we define Cartesian Coordinates in polar coordinates.

Recall: To go from Polar Coordinates $\displaystyle (r, \theta)$ to Cartesian Coordinates $\displaystyle (x,y)$ , we use:

$\displaystyle x = r \cos \theta $ and $\displaystyle y = r \sin \theta$

where $\displaystyle r = \sqrt {x^2 + y^2}$ and $\displaystyle \theta = \arctan \left( \frac {y}{x} \right)$

So, for any complex number $\displaystyle x + iy$, we can write

$\displaystyle x + iy = r \cos \theta + i~r \sin \theta$

$\displaystyle \Rightarrow x + iy = r ( \cos \theta + i \sin \theta)$

But we can rewrite what's in brackets using Euler's Formula. Thus we see that the said complex number can be expressed as follows:

$\displaystyle \boxed { x + iy = r \cdot e^{i \theta} }$

where $\displaystyle r = \sqrt {x^2 + y^2}$ and $\displaystyle \theta = arctan \left( \frac {y}{x} \right)$

Finally we are done with introductions, let's get to the meat of the matter. Here are the scraps of knowledge that I could pick up.

So far as I've seen, we make much use of Euler's formula, and polar representation of complex number when dealing with complex logarithms, and so it comes as no surprise that the natural logarithm, $\displaystyle \ln$, is what we work with here.Taking logarithms of Negative Numbers

Complex Logarithms use an imaginary component analogous to that of $\displaystyle i$ used to denote the imaginary component in a complex number. This component is $\displaystyle i \pi$ and it is defined to be $\displaystyle \ln (-1)$. This is an ingenious contraption, since any negative number can be thought of as -1 times the positive opposite of the negative number. Thus we can use the product law of logarithms (and if needed, the change of base formula for logarithms) to isolate the $\displaystyle \ln (-1)$ from any log of a negative number.

Before we see a demonstration of the technique, some readers may be wondering why is it that we use $\displaystyle i \pi$ to mean $\displaystyle \ln (-1)$. It is no big deal, we simply apply some laws of logarithms coupled with Euler's Identity (see the "Background" section above).

Recall the laws of logarithms (I will number the laws to refer to them in this thread, but the numbers should not be taken to mean anything other than that, that is, don't assume that the law I call "Law 1" is a fundamental law of logarithms and is of huge importance. The laws are in no particular order):

Law 1:$\displaystyle \log_a x^n = n \log_a x$

Law 2:$\displaystyle \log_a a = 1$

Law 3:We define $\displaystyle \log_e x$ to be $\displaystyle \ln x$. Therefore, $\displaystyle \ln e = 1$ (by Law 2).

Law 4:$\displaystyle \log_a b = \frac { \log_c b}{ \log_c a}$ .....change of base law

Law 5:$\displaystyle \log_a xy = \log_a x + \log_a y$

Now we can examine $\displaystyle \ln (-1)$

$\displaystyle \ln (-1) = \ln \left( e^{i \pi} \right)$ ........Applied Euler's Formula

$\displaystyle \Rightarrow \ln (-1) = i \pi \ln e$ .............Applied Law 1

$\displaystyle \Rightarrow \ln (-1) = i \pi \cdot 1$ ...............Applied Law 3

Thus we have:

$\displaystyle \boxed { \ln (-1) = i \pi }$

Now that we have all doubt dispersed regarding our "imaginary" component (I'm not sure if that's what it's called), let us see it in action.

Example 1:

Evaluate $\displaystyle \ln (-10)$

$\displaystyle \ln (-10) = \ln (-1 \cdot 10)$

$\displaystyle = \ln (-1) + \ln (10)$ .........Law 5

$\displaystyle = i \pi + \ln (10)$

$\displaystyle \approx 2.303 + i \pi$

What if we have a logarithm in some other base? We simply use the change of base formula, that is, Law 4

Example 2:

Evaluate $\displaystyle \log_{10} (-100)$

$\displaystyle \log_{10} (-100) = \frac { \ln (-100) }{ \ln 10}$ ........Law 4

$\displaystyle = \frac { \ln (-1 \cdot 100)}{ \ln 10}$

$\displaystyle = \frac { \ln (-1) + \ln 100}{ \ln 10}$ .............Law 5

$\displaystyle = \frac {i \pi + \ln 100}{ \ln 10}$

$\displaystyle = \frac {i \pi}{ \ln 10} + \frac { \ln 100}{ \ln 10}$

$\displaystyle = i \frac { \pi}{ \ln 10} + \frac { \ln 10^2}{ \ln 10}$

$\displaystyle = i \frac { \pi}{ \ln 10} + \frac {2 \ln 10}{ \ln 10}$ .........Applied Law 1 to the numerator

$\displaystyle = i \frac { \pi}{ \ln 10} + 2$ ...........Finally.

This seems to take forever, but that's just because I showed every step. Textbooks often get criticized for not showing all the steps, and students get frustrated when they do not understand how the book jumped from one step to another. I didn't want such criticisms to fall on me. However, we could still make it shorter. We did not have to jump into the change of base formula like that, we could have waited until we isolated the $\displaystyle \log_{10} (-1)$

Rework Example 2:

$\displaystyle \log_{10} (-100) = \log_{10} (-1 \cdot 100)$

$\displaystyle = \log_{10} (-1) + \log_{10} (100)$ ..............Law 5

$\displaystyle = \frac { \ln (-1)}{ \ln 10} + 2$ ..............Applied Law 4 to the first log while evaluating the second

$\displaystyle = \frac {i \pi}{ \ln 10} + 2$

$\displaystyle = 2 + \frac { \pi}{ \ln 10}~i$

So yeah, we can take the logarithm of negative numbers, they lied to you! Just like they lied to you when you were a child telling you you cannot subtract a bigger number from a smaller number, and then you get to the 6th grade and they do it all the time!

Anyway, I forgive them. Let's summarize what we have learnt here.

Let $\displaystyle x > 0$ be a real number.

Then $\displaystyle \boxed { \ln (-x) = \ln x + i \pi }$

and

$\displaystyle \boxed { \log_a (-x) = \frac { \ln x}{ \ln a} + \frac { \pi}{ \ln a}~i }$

Now that we know we can take the logarithm of a negative number, the next logical question to ask (I think) would be: "If we can take the logarithm of a negative number to get a complex number, does that mean we can take the logarithm of a complex number as well?" (That's the question I asked myself when I researched the above, I don't know if it is a logical train of thought or not--generally I'm not a logical person).

The answer is yes. Follow me deeper into the dark.

Taking logarithms of Complex Numbers

Recall the we could express any complex number, $\displaystyle x + i y$ by the following:

$\displaystyle \boxed { x + iy = r \cdot e^{i \theta} }$

where $\displaystyle r = \sqrt {x^2 + y^2}$ and $\displaystyle \theta = arctan \left( \frac {y}{x} \right)$

With all the background knowledge I gave, I don't think it is hard for the average reader to see where I'm going with this, so I'll just say it.

We can take the logarithm of a complex number by making use of the following formula:

$\displaystyle \boxed { \log_a (x + iy) = \log_a \left( r \cdot e^{i \theta} \right) }$

or equivalently (by applying Law 5): $\displaystyle \boxed { \log_a (x + iy) = \log_a r + \log_a e^{i \theta} }$

or to simplify even more (by applying Law 1): $\displaystyle \boxed { \log_a (x + iy) = \log_a r + i \theta \log_a e }$

Not much explanation is needed here. Let's jump right into the examples.

Let's start with something "simple"

Example 3:

Evaluate $\displaystyle \ln (1 + i)$

First we rewrite $\displaystyle 1 + i$ in polar coordinates, that is, in the form $\displaystyle r \cdot e^{i \theta}$. Using the formulas discussed earlier in this thread, we find

$\displaystyle r = \sqrt {1^2 + 1^2} = \sqrt {2}$

$\displaystyle \theta = \arctan 1 = \frac { \pi}{4}$

Thus,

$\displaystyle \ln (1 + i) = \ln \left( \sqrt {2} \cdot e^{i \pi /4}\right)$

$\displaystyle = \ln \sqrt {2} + \ln e^{ i \pi /4}$

$\displaystyle = \frac { \ln 2}{2} + i \frac { \pi}{4} \ln e$ ..........Applied Law 1 to both logs (remember $\displaystyle \sqrt {2} = 2^{ \frac {1}{2}}$)

$\displaystyle = \frac { \ln 2}{2} + \frac { \pi}{4} ~i$

Let's do another.

Example 4:

Evaluate $\displaystyle \ln (-4 + 3i)$

First we find $\displaystyle r \mbox { and } \theta$

$\displaystyle r = \sqrt {(-4)^2 + 3^2} = \sqrt {25} = 5$

$\displaystyle \theta = \arctan \left( - \frac {3}{4} \right) \approx -0.644$

Thus,

$\displaystyle \ln (-4 + 3i) = \ln \left( 5 \cdot e^{-0.644i} \right)$

$\displaystyle = \ln 5 + \ln e^{ -0.644i}$ ............Applied Law 5

$\displaystyle = \ln 5 - 0.644i \ln e$

$\displaystyle = \ln 5 - 0.644i$

That wasn't so bad, was it?

One more example for ol' times sake. Let's do one where we need the change of base law.

Example 5:

Evaluate $\displaystyle \log_3 (-2 - 8i) $

Find $\displaystyle r \mbox { and } \theta$

$\displaystyle r = \sqrt {(-2)^2 + (-8)^2} = \sqrt {68}$

$\displaystyle \theta = \arctan \left( \frac {-8}{-2} \right) \approx 1.326$

Thus

$\displaystyle \log_3 (-2 - 8i) = \log_3 \left( \sqrt {68} \cdot e^{1.326i} \right)$

$\displaystyle = \log_3 \sqrt{68} + 1.366i \log_3 e$ .........Applied Law 1

$\displaystyle \approx 1.92 + 1.243i $ .............I applied law 4 (change of base law) to evaluate the logs in base 3

So to summarize what we have learned here.

Let $\displaystyle x + iy$ be any complex number. And let $\displaystyle r = \sqrt {x^2 + y^2}$ and $\displaystyle \theta = \arctan \left( \frac {y}{x} \right)$

Then $\displaystyle \boxed { \ln (x + iy) = \ln r + i \theta }$

and

$\displaystyle \boxed { \log_a (x + iy) = \log_a r + ( \theta \log_a e)~i }$

Exercises

For those readers who would like to see if they really "get it," here are some problems you can practice on. You can post your solutions in this thread for the other members to critique... if you want. I made up random numbers, so don't expect the answers to be clever or "nice." (I could make some "nice" problems if I wanted to, but I'm not in a thinking mood at the moment).

Evaluate the following logarithms:

$\displaystyle \ln (i)$

$\displaystyle \log_7 (-49)$

$\displaystyle \log_17 0$

$\displaystyle \log_a \left( - \frac {4}{5} \right)$

$\displaystyle \log_5 ( 4 + i)$

$\displaystyle \log_3 (-6 - 7i)$

$\displaystyle \log_2 (-3 + 1)$

$\displaystyle \log_8 (8 - 3i)$

Despite appearances, I did not mean for this thread to be a tutorial of any sort, I made this thread so that the genius' on this forum can give me feedback as to whether or not I actually understand the material. Here are just a few questions I have at the moment, more questions may arise if any discussion results.

- Was everything I said correct? Would anyone like to add anything that can deepen my, as well as other readers', understanding?Questions:

- Is there a way to take logarithms of negative numbers without working with natural logarithm?

- Doing all the things I said seems cumbersome, is there anyway to make it easier? Like some mnemonic I should know or something?

- Are there logs with negative or complex bases? If so, how would we evaluate them?

- (A bit off-topic) How do we evaluate numbers with complex exponents? (I think I could have come up with more interesting problems if I knew that)