def power, problem when raising power to decimals

colas.francis at gmail.com colas.francis at gmail.com
Thu Apr 17 05:56:56 EDT 2008


On 17 avr, 00:49, "Gabriel Genellina" <gagsl-... at yahoo.com.ar> wrote:
> En Wed, 16 Apr 2008 19:21:18 -0300, John Machin <sjmac... at lexicon.net>
> escribió:
>
> > skanem... at yahoo.se wrote:
> >> also i found a link which states 0^0 isnt 1 even though every
> >> calculator ive tried says it is.
> >> it doesnt say what it is but i presume 0 then.
> >> but it seems the dude is wrong and it is 1?
>
> > Of the possible results of 0 ** 0 (i.e. 1, 0, and NaN), 1 seems to be
> > the least implausible. It allows X ** 0 to be 1 for all X.
>
> But a result of 0 would allow 0 ** X to be 0 for all X. (btw, this is the
> reason lim(x**x) for x->0 does not exist)

lim(x**x) for x->0+ is well defined, exists and equals 1. [1]
As x**x is continuous in 0+, it is widely customary to have: 0**0:=1

[1] Recall that x**x := exp(x*log(x))
The limit of x*log(x) for x->0 is 0 [2] therefore lim(x**x) for x->0
is 1.


[2] Let y = 1/x; x*log(x)= -log(y)/y and the limit of log(y)/y for y->
+inf is 0.



More information about the Python-list mailing list