Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

0 log(0)?

670 views
Skip to first unread message

Bill Simpson

unread,
Apr 16, 1996, 3:00:00 AM4/16/96
to
I have the expression
x = a log(a)
and I wonder: what is x when a is 0?

Is x just 0, or is it something trickier?

Thanks very much for any help.

Bill Simpson

theodore hwa

unread,
Apr 16, 1996, 3:00:00 AM4/16/96
to
Bill Simpson (wsim...@uwinnipeg.ca) wrote:
: I have the expression

: x = a log(a)
: and I wonder: what is x when a is 0?

Well, it is not defined at a=0.

But, if you mean the LIMIT as a->0 of a log a, then that's different.
The limit exists. One way to calculate it is to write the expression
as log(a)/ (1/a) and use L'hopital's rule.

Mustafa Aslan

unread,
Apr 16, 1996, 3:00:00 AM4/16/96
to wsim...@uwinnipeg.ca
Bill Simpson <wsim...@uwinnipeg.ca> wrote:
>I have the expression
>x = a log(a)
>and I wonder: what is x when a is 0?
>
>Is x just 0, or is it something trickier?
>
>Thanks very much for any help.
>
>Bill Simpson

let approach this problem from different wiev point

if x= a log (a) then log (10^x)=log (a^a)

hence 10^x=a^a

if a=0 then 10^x = undefined
and x = undefined

you may use infinitive instead of undefined


Kurt Foster

unread,
Apr 16, 1996, 3:00:00 AM4/16/96
to
Bill Simpson (wsim...@uwinnipeg.ca) wrote:
: I have the expression
: x = a log(a)
: and I wonder: what is x when a is 0?

: Is x just 0, or is it something trickier?

:
Since log(0) isn't defined, 0 * log(0) isn't defined, either. One
can, however, evaluate the limiting value of a * log(a) as _a_ APPROACHES 0
through positive values (I'm assuming the logs are to a real base
b > 1). Taking, for illustration, the sequence a_n = b^(-n), n running
through the positive integers, one has

x_n = log(a_n) = -n/(b^n)

Since the series

x_1 + x_2 + x_3 + ...

has a finite sum (use the fact that 1 + 2x + 3x^2 + ... converges to
1/(1-x)^2 when |x| < 1), the terms tend to 0 as n increases without
bound. Of course, this isn't a complete proof, but it's enough to show
that, if the limiting value does exist, that value is 0.

Daniel M Grasso

unread,
Apr 16, 1996, 3:00:00 AM4/16/96
to
The analytical solution may be different, but the function

f(x) = x log x

is not defined at zero.


Regards,
Dan

*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*
Daniel M Grasso
SUNY At Buffalo School of Engineering and Applied Science
dmgr...@eng.buffalo.edu
"I don't want to repeat my innocence.
I want the pleasure of losing it again."
-Fitzgerald
~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*


Bill Simpson

unread,
Apr 16, 1996, 3:00:00 AM4/16/96
to
I would like to explain why I am interested in 0 log(0).

I have a 2 x 2 table of counts:

n11 n12 | n1.
n21 n22 | n2.
-------------------
n.1 n.2 | n..

The . notation means that summing has been done over the dotted index.

The log likelihood ratio for interaction is:

G=Sum Sum (nij ln(nij) - nij ln(ni. nj./n..))
i j

In the case where the cell count is 0 we have 0 log 0. If this
is undefined, I have no idea how to compute G. One possibility is
to "falsify" the data by adding some small number (e.g. 0.5) to all the
cells prior to computing G. Then the 0 log 0 problem does not arise.
I don't like this solution! I would prefer to just let 0 log 0 = 0.
If I add a very small constant to all cells, this is what I would get
anyway (in the limit as the constant approaches 0). Is this rationale for
saying 0 log 0 = 0 OK?

ra...@scylla.math.mcgill.ca

unread,
Apr 16, 1996, 3:00:00 AM4/16/96
to
In article <4l0unv$6...@azure.acsu.buffalo.edu>,

Daniel M Grasso <dmgr...@acsu.buffalo.edu> wrote:
>The analytical solution may be different, but the function
>
>f(x) = x log x
>
>is not defined at zero.
>
Of course, but I cannot help thinking that what the original poster
wanted was the limiting value lim_{x\to0} x log x , which is (of
course) 0 , the value he suggested. I would hope that he also knows
that this is not the same thing as saying 0 log 0 = 0 (he did specify
a log a when a = 0, which is where I take the clues from).

= rags =

--
RAG Seely
<ra...@math.mcgill.ca>

Mustafa Aslan

unread,
Apr 17, 1996, 3:00:00 AM4/17/96
to ra...@scylla.math.mcgill.ca

0.infinity=undefined infinity/infinity=undefined

1^infitity=undefined infinity.infinity=undefined

since log(0)=infinity

and since 0.infinity=undefined

0.log(0)=undefined


Mustafa Aslan

unread,
Apr 17, 1996, 3:00:00 AM4/17/96
to ra...@scylla.math.mcgill.ca
By using your fashion

since a^-b^=(a-b)(a+b) we can write

x^2-x^2=(x-x)(x+x)
x(x-x)=(x-x)(x+x)
x=2x
1=2


Gabriel Dos Reis

unread,
Apr 17, 1996, 3:00:00 AM4/17/96
to
>>>>> «Mustafa», Mustafa Aslan <mas...@odin.cmp.ilstu.edu> écrit :

Mustafa> By using your fashion
Mustafa> since a^-b^=(a-b)(a+b) we can write

Mustafa> x^2-x^2=(x-x)(x+x)
Mustafa> x(x-x)=(x-x)(x+x)
^^^^^^^^^^^^^^^^^^
||
\/
Mustafa> x=2x
Mustafa> 1=2

Good, the simplification. A new arithmetic ? First rule in algebraic
computation: Cancelling by zero is illegal.

--
_______ ___ ___ ______
Gabriel DOS REIS / ____/ / \/ / / __/
dos...@dptmaths.ens-cachan.fr / __/_ / / _\ \
http://yoko.ens-cachan.fr:8080/~dosreis/ /______/ /__/\___/ /_____/

Mustafa Aslan

unread,
Apr 17, 1996, 3:00:00 AM4/17/96
to dos...@dptmaths.ens-cachan.fr
By his thinking way why not?
If 0.infinity=0 then 0/0=1
Accordint to his fashion


Tony2back

unread,
Apr 17, 1996, 3:00:00 AM4/17/96
to
In article <Pine.OSF.3.91.960416...@io.UWinnipeg.ca>,
Bill Simpson <wsim...@uwinnipeg.ca> writes:

>I have the expression
>x = a log(a)
>and I wonder: what is x when a is 0?
>
>Is x just 0, or is it something trickier?
>

>Thanks very much for any help.
>
>Bill Simpson
>
>

The limit as a -> 0 is found from l'Hospital's rule as follows:

aln(a) = ln(a)/(1/a) which as 'a' tends to 0 would tend to
infinity/infinity.

Using l'Hospital's rule, ratio = (1/a)/(-1/a^2) = - a^2/a = -a

And so in the limit the value tends to 0.


Anthony Hugh Back

Bill Simpson

unread,
Apr 17, 1996, 3:00:00 AM4/17/96
to
Thanks for the helpful replies.

Does saying
0 log 0 = undefined
mean
"it could be 0 or it could be something else"? (All bets are off)

Could I then say
"I take it to be zero by the following limiting argument"? (Since the value
is arbitrary I define it in the following way from the following argument)

In answer to one question, No I don't really understand the distinction
between
lim a->0 a log a
and
a=0, a log a.

My practical problem is that I CANNOT say I have an undefined value
when the cell count is 0 (when I compute count log count). I have to deal
with the problem in some way so that a cell count of 0 yields some
numerical value. One solution is to falsify the data by adding a small
constant to all cells. Another is to declare that I take 0 log 0 to be 0
(even though I know it to be undefined, strictly speaking). I guess another
is to revise the log likelihood formula so that it involves
f(x)= x log (x) x>0
= 0 x=0
Maybe this last idea is the best.

Sorry if I seem thick. I have no mathematical training.

Thanks again for all the help.

Bill Simpson

Travis Kidd

unread,
Apr 17, 1996, 3:00:00 AM4/17/96
to
log 0 = -oo, therefore 0 * log 0 = 0 * -oo, which is indeterminate, which
basically means it takes on different values depending on the situation.

-Travis


Terry Moore

unread,
Apr 19, 1996, 3:00:00 AM4/19/96
to
Simpson <wsim...@uwinnipeg.ca> wrote:
>
> I have the expression
> x = a log(a)
> and I wonder: what is x when a is 0?
>
> Is x just 0, or is it something trickier?

It's undefined. However, you might be interested in
lim_a->0+(a log(a)) (the expression is undefined,
at least as a real number, if a < 0).
This is easy. Just think of the behaviour for small a
Note that a ln(a) = -ln(b)/b where b = 1/a so we
can think about ln(b)/b for large b.
Now let b = exp(c), so ln(b)/b = c/exp(c) and let
c be large.

This allows us to get several nice results at once.
Exp(c) = 1 + c + c^2/2! + ... and so exponentials
beat polynomials as c -> oo (take a term of higher
degree than the polynomial). In particular c/exp(c)
-> 0 so ln(b)/b -> 0 (polynomials beat logs).
Thus lim_a->0+(a log(a)) = 0 as you
hypothesised.

Terry Moore, Statistics Department, Massey University, New Zealand.

Imagine a person with a gift of ridicule [He might say] First that a
negative quantity has no logarithm; secondly that a negative quantity has
no square root; thirdly that the first non-existent is to the second as the
circumference of a circle is to the diameter. Augustus de Morgan

Toby Bartels

unread,
Apr 19, 1996, 3:00:00 AM4/19/96
to
Mustafa Aslan (mas...@odin.cmp.ilstu.edu) wrote:

>By his thinking way why not?
>If 0.infinity=0 then 0/0=1

>According to his fashion

What's 0.infinity got to do with 0/0?
There's no infinity in 0/0 in his fashion.


-- Toby
to...@ugcs.caltech.edu

Jonathan Halcrow

unread,
Apr 20, 1996, 3:00:00 AM4/20/96
to
Bill Simpson <wsim...@uwinnipeg.ca> wrote:

>I have the expression
>x = a log(a)
>and I wonder: what is x when a is 0?

>Is x just 0, or is it something trickier?

>Thanks very much for any help.

>Bill Simpson

X would have to be zero no matter what the log was. Anything times 0
is always going to be zero.


Terry Moore

unread,
Apr 21, 1996, 3:00:00 AM4/21/96
to
In article <4l2cpk$p...@newsbf02.news.aol.com>, tony...@aol.com

(Tony2back) wrote:
>
> In article <Pine.OSF.3.91.960416...@io.UWinnipeg.ca>,
> Bill Simpson <wsim...@uwinnipeg.ca> writes:
>
> >I have the expression
> >x = a log(a)
> >and I wonder: what is x when a is 0?

> The limit as a -> 0 is found from l'Hospital's rule as follows:


>
> aln(a) = ln(a)/(1/a) which as 'a' tends to 0 would tend to
> infinity/infinity.
>
> Using l'Hospital's rule, ratio = (1/a)/(-1/a^2) = - a^2/a = -a
>
> And so in the limit the value tends to 0.

Some people have argued against using l'Hospital's rule
because it is an automatic procedure and they want
students to think. But here we see how useful it is.
Take a limit that doesn't exist and it gives us a
definite answer :-)

[Note that a ln(a) is undefined for a < 0, at least
if we work only with real numbers].

Terry Moore

unread,
Apr 22, 1996, 3:00:00 AM4/22/96
to
In article <4l9ggv$29...@mule1.mindspring.com>, jhal...@atl.mindspring.com
(Jonathan Halcrow) wrote:

>
> Bill Simpson <wsim...@uwinnipeg.ca> wrote:
>
> >I have the expression
> >x = a log(a)
> >and I wonder: what is x when a is 0?
>
> >Is x just 0, or is it something trickier?

> X would have to be zero no matter what the log was. Anything times 0


> is always going to be zero.

And if that something is -oo?

(BTW, my previous reservations about negative a
don't matter if we allow complex analysis, a ln(a) then
tends to zero as a -> 0 from any direction in the
complex plane.)

Anyway, we have all now agreed that 0^0 = 1 :-)

Taking logs gives 0 = ln(1) = ln(0^0) = 0 ln(0) so we
ought to define 0 ln(0) = 0.

This, of course, will be totally non-controversial.

Toby Bartels

unread,
Apr 22, 1996, 3:00:00 AM4/22/96
to
Jonathan Halcrow (jhal...@atl.mindspring.com) wrote:

>Bill Simpson (wsim...@uwinnipeg.ca) wrote:

>>I have the expression
>>x = a log(a)
>>and I wonder: what is x when a is 0?

>X would have to be zero no matter what the log was. Anything times 0


>is always going to be zero.

Ah, but log(0) is not a thing!


-- Toby
to...@ugcs.caltech.edu

Toby Bartels

unread,
Apr 22, 1996, 3:00:00 AM4/22/96
to
Travis Kidd (tk...@hubcap.clemson.edu) wrote:

>log 0 = -oo, therefore 0 * log 0 = 0 * -oo, which is indeterminate, which
>basically means it takes on different values depending on the situation.

I assume you're talking about the limit here,
in which case you should specify so.


-- Toby
to...@ugcs.caltech.edu

matthew b charlap apmt stnt

unread,
Apr 22, 1996, 3:00:00 AM4/22/96
to
In article <4l9ggv$29...@mule1.mindspring.com>,
Jonathan Halcrow <jhal...@atl.mindspring.com> wrote:

>Bill Simpson <wsim...@uwinnipeg.ca> wrote:
>>I have the expression
>>x = a log(a)
>>and I wonder: what is x when a is 0?
>
>>Is x just 0, or is it something trickier?
>X would have to be zero no matter what the log was. Anything times 0
>is always going to be zero.

Actually, it dependss how you get there.
0 log (0) is undefined. now if you do:
lim a log (a)
a->0+

then this = lim (log (a))/(1/a)=lim (1/a)/(-1/a*a)=lim (-a) = 0-
a->0+ a->0+ a->0+

so then x=0 (I assumed you were working with real numbers so log is
undefines for negative values)
--Matthew


Vidhyanath K. Rao

unread,
Apr 22, 1996, 3:00:00 AM4/22/96
to
In article <T.Moore-22...@fims-mac12.massey.ac.nz>,

Terry Moore <T.M...@massey.ac.nz> wrote:
>In article <4l9ggv$29...@mule1.mindspring.com>, jhal...@atl.mindspring.com
>(Jonathan Halcrow) wrote:
>> X would have to be zero no matter what the log was. Anything times 0
>> is always going to be zero.
>
>And if that something is -oo?
>
>Anyway, we have all now agreed that 0^0 = 1 :-)
>
>Taking logs gives 0 = ln(1) = ln(0^0) = 0 ln(0) so we
>ought to define 0 ln(0) = 0.
>
>This, of course, will be totally non-controversial.

Set theorists and category-theorists will probably agree with no
reservations that 0 \infty = 0 = \infty 0 :-)

Analysts may be have split opinions, even if you ask only one:
Rudin ``Real and Complex Analysis'' (1.22, p.18 of first Indian
edition) says
a\infty = \infty a = \infty if 0< a \le \infty
0 if a = 0

But somewhere earlier, I think that he says ``note that this definition
does not need 0\infty to be defined'' or words to that effect.
But I couldn't find it when I looked just now.

--
Vidhyanath Rao It is the man, not the method, that solves
nath...@osu.edu the problem. - Henri Poincare
(614)-366-9341 [as paraphrased by E. T. Bell]

Kevin Johnson

unread,
Apr 22, 1996, 3:00:00 AM4/22/96
to
Terry Moore (T.M...@massey.ac.nz) wrote:
> In article <4l2cpk$p...@newsbf02.news.aol.com>, tony...@aol.com
> (Tony2back) wrote:
> >
> > In article <Pine.OSF.3.91.960416...@io.UWinnipeg.ca>,
> > Bill Simpson <wsim...@uwinnipeg.ca> writes:
> >
> > >I have the expression
> > >x = a log(a)
> > >and I wonder: what is x when a is 0?

> > The limit as a -> 0 is found from l'Hospital's rule as follows:


> >
> > aln(a) = ln(a)/(1/a) which as 'a' tends to 0 would tend to
> > infinity/infinity.
> >
> > Using l'Hospital's rule, ratio = (1/a)/(-1/a^2) = - a^2/a = -a
> >
> > And so in the limit the value tends to 0.

> Some people have argued against using l'Hospital's rule
> because it is an automatic procedure and they want
> students to think. But here we see how useful it is.
> Take a limit that doesn't exist and it gives us a
> definite answer :-)

> Terry Moore, Statistics Department, Massey University, New Zealand.

I noticed the same phenomenon when I was in college. People would look
at the problem lim(x->0) Sin(x)/x and say Ohhh... L'Hopital's can do
this, and proceed to do say that lim(x->0) Sin(x)/x=lim(x->0) Cos(x)/1=1
But somewhere they forgot that the definition of the derivative for the
top was lim(h->0,x=0) is (Sin(h)-Sin(0))/h = lim(h->0) Sin(h)/h ... Oh well.
:-)

--
"The problem of the outsider | Kevin Johnson | My company doesn't
is that he sees too deeply | kevin....@waii.com| agree with me about
and too much, and what he | Western Geophysical | anything.
sees is essentially chaos." |--------------------------------------------
-- The Outsider, | 3.1415926535897932384626433832795028841972
Colin Wilson | 2.7182818284590452353602874713526624977573

R.E.Tu...@ncl.ac.uk

unread,
Apr 23, 1996, 3:00:00 AM4/23/96
to
At the risk of seeming "cheeseparing", as to the second point above,the
negative quantity surely has no "real" square root,but the square root
of minus one is surely the "imaginary" number "i", which often
disappears in some calculations,leaving one with real numbers only,but,
of course, I am not familiar with hos far, if at all, imaginary numbers
occur in the course of statistics problems, Augustus?
Edward Turnbull

J.H. Meyer

unread,
Apr 24, 1996, 3:00:00 AM4/24/96
to
jhal...@atl.mindspring.com (Jonathan Halcrow) wrote:
>Bill Simpson <wsim...@uwinnipeg.ca> wrote:
>
>>I have the expression
>>x = a log(a)
>>and I wonder: what is x when a is 0?
>
>>Is x just 0, or is it something trickier?
>
>>Thanks very much for any help.
>
>>Bill Simpson
>
>X would have to be zero no matter what the log was. Anything times 0
>is always going to be zero.
>
>

0log(0) does not exist, simply because log(0) is not defined. So the
graph of the function f(x) = xlog(x) does not have any points with
x-co-ordinate = 0. In fact, since log(x) is not defined for any x<0 also,
the graph of f will be situated completely to the right of the y-axis.

However, one can consider the behaviour of f(x) = xlog(x) if x approaches
0 (from the right hand side), i.e., one can consider

lim xlog(x).
x->0+

By an easy application of L'Hospitals rule, it is found that the above
limit is indeed equal to 0. This merely implies that the value of xlog(x)
can be made arbitrarily close to 0 just by taking x close enough to 0
(but still positive).

To say that 0log(0) = 0, ``because anything times 0 is 0'' is not
correct. Since then we must have, for example, 1/x = 0 if x=0, because
1/x = x(1/x^2).


Good luck, Johan Meyer.


Terry Moore

unread,
Apr 28, 1996, 3:00:00 AM4/28/96
to

In article <4lkv5p$r...@pukrs7.puk.ac.za>, "J.H. Meyer"
<ww...@wwg3.uovs.ac.za> wrote:

> 0log(0) does not exist, simply because log(0) is not defined.

This is true. But we sometimes find it useful to give a meaning to a
composite symbol when its constituents are undefined (e.g.
integral(f(x) dx). As z ln(z) -> as z -> 0 for complex z (even
though ln(z) is many valued), defining 0 ln(0) is removing a
removable discontinuity. There are also many practical
advantages for defining 0 ln(0) = 0. That was just what was
needed in Bill Simpson's original question, for example.
And, as I said before, if 0^0 = 1 then its log should be 0
and formally ln(0^0) = 0 ln(0) even though this is _only_
a formal relation.

Terry Moore, Statistics Department, Massey University, New Zealand.

Imagine a person with a gift of ridicule [He might say] First that a

Scott J. McCaughrin

unread,
Apr 30, 1996, 3:00:00 AM4/30/96
to

In a previous article, to...@ugcs.caltech.edu (Toby Bartels) says:

>Jonathan Halcrow (jhal...@atl.mindspring.com) wrote:


>
>>Bill Simpson (wsim...@uwinnipeg.ca) wrote:
>
>>>I have the expression
>>>x = a log(a)
>>>and I wonder: what is x when a is 0?
>

>>X would have to be zero no matter what the log was. Anything times 0
>>is always going to be zero.
>

>Ah, but log(0) is not a thing!

Right, which then begs the question: what does a*log(a) look like as a
approaches 0 from the right? Since a*log(a) = log(a)/1/a is indeterminate
(-inf/inf) and differentiable, l'Hospital gives lim(a->0+) 1/a / (-1/a^2) =
lim(a->0+) -a = 0, and stays negative "near" 0.


Bengt Mansson

unread,
May 1, 1996, 3:00:00 AM5/1/96
to

to...@ugcs.caltech.edu (Toby Bartels) wrote:

>Jonathan Halcrow (jhal...@atl.mindspring.com) wrote:

>>Bill Simpson (wsim...@uwinnipeg.ca) wrote:

>>>I have the expression
>>>x = a log(a)
>>>and I wonder: what is x when a is 0?

>>X would have to be zero no matter what the log was. Anything times 0
>>is always going to be zero.

However, lim (a log(a) ) = 0 as a tends to 0 through positive values.
Perhaps that's what the original questioner needs.

/ Bengt M


Jon

unread,
May 2, 1996, 3:00:00 AM5/2/96
to

to...@ugcs.caltech.edu (Toby Bartels) wrote:

yeah. I don't understand what he could mean by oo unless he meant a
limit, for that's all the quantity oo can be defined to be, a limit.

Limit(x*log(x),x->0+) = 0. Limit(x*log(x),x->0-) = ?, all I know is
(-1)*log(-1)= - I*Pi.

later!

Life is grand, don't mess it up..
Existence is meaningless, buck up!
----------
Email : jo...@tamu.edu
PGP-Key : email TO:pgp-pub...@pgp.mit.edu SUBJECT: get jo...@tamu.edu
Web Page: http://blackhole.dorms.tamu.edu
Ftp Site: ftp://blackhole.dorms.tamu.edu

0 new messages