Updated! February 5, 2017
The value of zero raised to the zero power, , has been discussed since the time of Euler in the 18th century (1700s). There are three reasonable choices: 1,0, or “indeterminate”. Despite consensus amongst mathematicians that the correct answer is one, computing platforms seem to have reached a variety of conclusions: Google, R, Octave, Ruby, and Microsoft Calculator choose 1; Hexelon Max and TI-36 calculator choose 0; and Maxima and Excel throw an error (indeterminate). In this article, I’ll explain why, for discrete mathematics, the correct answer cannot be anything other than 0^0=1, for reasons that go beyond consistency with the Binomial Theorem (Knuth’s argument).
Context of the Debate: Continuous Mathematics
The three choices for the value of appear because , as a function of two continuous variables, is discontinuous at (0,0) and takes three different values depending on the direction of approach to the discontinuity:
- Fixing y=0, we have for all . (Proof: , each statement holding for all ). Indeed, as , approaching from left or right, with y=0. (This was Euler’s reason.)
- Fixing x=0, we have for . (When y < 0 we have division by zero which is undefined in the reals and in the extended reals). Taking limits, as , approaching from above only, with x=0.
- Fixing x=0, we have an undefined value when y < 0 due to division by zero.
Notice that the discontinuity is not a simple (point) discontinuity, but rather a pole discontinuity due to the approach from below. (Exercise: what happens as the origin is approached from 45 degrees?)
Principles for a Decision in Mathematics: Extension and Consistency
In mathematics, when there is more than one choice, a decision is typically made by extending an existing precedent to maintain consistency with the evidence that is already accumulated and accepted.
An elementary example is the way ordinary multiplication is extended from two positive numbers to a positive and a negative number, then to two negative numbers, i.e. .
“Minus times minus is plus.
The reason for this we need not discuss!”
— W.H. Auden
Empirically, multiplication of two positive numbers has a well-defined, tangible meaning as repeated addition. This meaning holds when one of the numbers is negative. But when both are negative, the empirical meaning fails.
For the mathematician, declaring something to be undefined (throwing an error) means a loss of efficiency because every instance now has to be checked for the undefined case, and this must be treated separately. If a definition could be found that remains consistent with all other empirically obtained rules, and if that definition means that calculation can proceed indifferent to the decision, then that is a big win.
The consistency in this particular case is the distributivity of multiplication over addition, a law which, for positive numbers, can be accepted on entirely empirical grounds. (See the footnote for the full argument.1.)
Turning to Discrete Mathematics – Consistency with the Binomial Theorem
In discrete mathematics, there is no notion of “approaching” — one is either at or away from it, in which case or .
The case of can be decided on consistency grounds with respect to the binomial theorem, i.e. loss of computational efficiency to have to treat this case separately. This is the argument of Knuth (of The Art of Computer Programming, and TeX fame), based on maintaining consistency with the binomial theorem when x=0, due to its fundamental place in both discrete and continuous mathematics:
“Some textbooks leave the quantity undefined, because the functions and have different limiting values when decreases to 0. But this is a mistake. We must define for all , if the binomial theorem is to be valid when , and/or . The theorem is too important to be arbitrarily restricted! By contrast, the function is quite unimportant.”
– from Concrete Mathematics, p.162, R. Graham, D. Knuth, O. Patashnik, Addison-Wesley, 1988
Different Conventions Among Mathematical Computing Platforms
Given the universality of the convention amongst mathematicians, it is surprising to find that various computing platforms have implemented different values:
- Value one: Google Calculator, R, Octave, Ruby, and Microsoft’s Calculator all give .
- Value zero: Hexalon Max (calculator) and a physical TI-36 hand calculator give .
- Value indeterminate: Maxima and Microsoft Excel (2000) give is indeterminate, i.e. an error is thrown.
An Alternative Decision Criteria – tangible computation with verifiable count that requires the answer
While Knuth’s argument of convenient extension works, the finite summation of integer powers provides us with a real, tangible result (a finite sum), whose value (an empirically determinable fact) depends unavoidably on the chosen value of . So here we have a consistency argument that does not rely on efficiency.
Extracting the relevant part of that derivation, we have:
After expanding the binomial power using the binomial formula and further manipulation, we arrive at:
The key step happens in (***) above: we peel off the term of the inner summation to get: . Peeling this out of the outer summation requires considering the expression for all . Now, 0 raised to any positive power is 0, so we can dispel the case of . But what is ? A decision must be made: it is either or . Indeterminacy is not an option, since the situation is real and is required to continue the simplification.
The Argument for
What are the consequences of choosing the other definition, i.e. ? In this case, the final formula for is off by a linear constant , while the choice leads to the exact formula and a computed value that matches a brute force summation.
For , the difference is between 220,825 (the correct, verifiable answer), and 220,815 (verifiably NOT correct). The correct definition is clear: 0^0 = 1 is for empirical reasons that have to do with counting and summing. While it is the binomial theorem that provides the detail, the argument is one of verifiable necessity and not one of consistency.
For discrete mathematics, the empirical evidence shows that 0^0=1 is required:2
The Math Forum
(If you’re a software developer of a mathematical package, I’d be interested in how you arrived at your decision. You can send me an email using the Comments link below.)
If you enjoyed this article, feel free to click here to subscribe to my RSS Feed.
- Considering that any quantity times zero is zero, and that one times any quantity is the quantity, we have no hesitation in granting . But then observe that we way write , which means, combining the two expressions, we have . If we accept the law of distribution of multiplication over addition for positive whole numbers, purely on empirical grounds, and if we wish negative numbers to behave in the same manner as our empirically accepted positive whole numbers, then we want the distributive law to hold as well. And therefore we have Which means that must be the oppositive (additive inverse) of , and hence ↩
- The implications for continuous mathematics are a consideration for another discussion. The statement that a discontinuity exists at the origin isn’t quite enough. ↩