2
$\begingroup$

I am having some confusion in regards to the log based value of a negative number. I know that this is said to be undefined, though I accidentally entered in '$\log(-x)$' instead of '$\log(x)$' via a graphing application, and it actually graphed a series of $x$-$y$ values, but, once again, I thought this was undefined.

So, like, apparently the value of $\log(-10) = 1$?

I get that you can have negative $y$ values, thus transforming the $y$ values over the $x$ axis, as well as things like $1/\log(x)$, etc., but not $\log(-x)$; I am not really sure what the $-$ sign actually implies (in this context).

By the way, if I enter in $\log(-10)$ in the graphing application of any other mathematical tool, it does indeed say that it is undefined, as expected. I also tested this in other graphing apps, and $\log(-x)$ is for some reason also a legit operation, so it doesn't seem to be some sort of bug in the software.

Thanks to those who answered, it is very much appreciated :)

In addition I'd like to mention that I realised that one could use algebra to figure out why -x works. For instance, log_2(-x) = 3 if x=8, thus -x =8, so x must equal -8, as --8 = +8.

Thus flipping the values over the y axis, from 8, to -8, but keeping the value of the y constant. So all positive values of x must be negative, since the negative of a negative is positive.

$\endgroup$
  • 2
    $\begingroup$ The function $\log(-x)$ is defined on the negative real numbers. So this will flip the graph of $\log(x)$ over the $y$-axis. $\endgroup$ – MathNewbie Jun 10 '15 at 20:31
  • $\begingroup$ Are you familiar with eulers formula? $\endgroup$ – grdgfgr Jun 10 '15 at 20:31
  • $\begingroup$ @randomgirl: it also exist when $x>0$ and it gives $x+i\pi$. $\endgroup$ – idm Jun 10 '15 at 20:34
  • 4
    $\begingroup$ @idm or $3i\pi$, or $5i\pi$, or $7i\pi$... $\endgroup$ – Matt Samuel Jun 10 '15 at 20:36
  • 2
    $\begingroup$ @idm: $\ln x+i\pi$, presumably. $\endgroup$ – Brian Tung Jun 10 '15 at 20:42
1
$\begingroup$

When $x$ is a real number, $\log x$ exists only when $x>0$. Thus, if you write $\log(-x)$, you must have $-x>0$ i.e. $x<0$.

However, the logarithm can be defined over negative numbers, but you have to consider complex numbers (and this new logarithm is not the usual one, is a new logarithm, called complex logarithm).

$\endgroup$
  • $\begingroup$ Hi Joe! Thanks for your answer. So, is it that logarithms can work with negative x values, or is it that you can take the negative value of x values which aren't themselves negative, but somehow this flips the x values over the y axis? Thanks again :) $\endgroup$ – Jim Jam Jun 10 '15 at 20:40
  • $\begingroup$ You're welcome. No, log can't work with negative values, unless you consider complex numbers. I suppose you want to remain into the real numbers, so don't misunderstand the minus sign ahead of $x$: when you consider $\log(-x)$ you're not taking negative values. You simply have to set the argument of the function $\xi\mapsto\log\xi$ positive. So if $\xi=-x$ you'll take $-x>0$ i.e. $x<0$. $\endgroup$ – Joe Jun 10 '15 at 23:12
  • $\begingroup$ More generally: if you have $\log f(x)$, where $f:\Bbb R\to\Bbb R$, you have to find which values of $x$ give $f(x)>0$: they are the all and only points you are allowed to take account in. In your example the function is $f(x)=-x$ which so simple to create confusion! $\endgroup$ – Joe Jun 10 '15 at 23:15
2
$\begingroup$

In the field of real numbers the function $\log$ is defined ( i.e. has real value) only if its argument is positive. So $\log x$ is defined only if $x>0$ and $\log (-x)$ is defined only if $x<0$ and $\log |x|$ is defined only if $x\ne 0$.

We can define the logarithm of negative arguments in the field of complex numbers, as inverse of complex exponentiation, but the definition require some care because the complex exponential is a periodic function, so it is not invertible in a simple manner. You can see here for an introduction.

$\endgroup$

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.