Have been experimenting with the Log function to demonstrate simple Log relationships such as Log[xy], Log[x+y] etc.

m =b^x;
n = b^y;

The output i get is


Why is Log[b,b] not being evaluated to 1 ? Also Log[b,b^x]=x so why is it not showing this ? Also the log statements in the output have no base shown ?

I tried


which gives me


Simplify doesn't seem to do anything

Thanks David.

  • $\begingroup$ Replace log by Log (first letter=Uppercase) $\endgroup$
    – andre314
    Commented Feb 8, 2013 at 14:21

1 Answer 1


Log[b, b] does evaluate to 1; your error is in assuming that Log[b, b^x] is supposed to simplify automatically to x; Mathematica assumes that symbols like b and x are generically complex numbers unless told otherwise, and you should know that $\log_b b^x\neq x$ in a large region of the complex plane.

However, you can use Simplify[] and assumptions:

Simplify[Log[b, b^x], Positive[b] && Element[x, Reals]]
(* x *)

FWIW: you are aware of the change-of-base formula? Mathematica, for a number of reasons, prefers that all logarithms be expressed as natural logarithms $\log\,x$ ($\ln\,x$ in less-advanced work), and does so. So, Log[b, x] is automagically transformed to Log[x]/Log[b]. Similar transformations are done for Log2[x] and Log10[x].

  • $\begingroup$ Thanks. It did occur to me it was using natural logs but being able to specify assumptions on Simplify is very useful. $\endgroup$ Commented Feb 8, 2013 at 15:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.