Zero to the power of zero

Zero to the power of zero, denoted as 0, is a mathematical expression with different interpretations depending on the context. In certain areas of mathematics, such as combinatorics and algebra, 0 is conventionally defined as 1 because this assignment simplifies many formulas and ensures consistency in operations involving exponents. For instance, in combinatorics, defining 0 = 1 aligns with the interpretation of choosing 0 elements from a set and simplifies polynomial and binomial expansions.
However, in other contexts, particularly in mathematical analysis, 0 is often considered an indeterminate form. This is because the value of x as both x and y approach zero can lead to different results based on the limiting process. The expression arises in limit problems and may result in a range of values or diverge to infinity, making it difficult to assign a single consistent value in these cases.
The treatment of 0 also varies across different computer programming languages and software. While many follow the convention of assigning 0 = 1 for practical reasons, others leave it undefined or return errors depending on the context of use, reflecting the ambiguity of the expression in mathematical analysis.
Many widely used formulas involving natural-number exponents require 0 to be defined as 1. For example, the following three interpretations of b make just as much sense for b = 0 as they do for positive integers b:
All three of these specialize to give 0 = 1.
When evaluating polynomials, it is convenient to define 0 as 1. A (real) polynomial is an expression of the form a0x + ⋅⋅⋅ + anx, where x is an indeterminate, and the coefficients ai are real numbers. Polynomials are added termwise, and multiplied by applying the distributive law and the usual rules for exponents. With these operations, polynomials form a ring R[x]. The multiplicative identity of R[x] is the polynomial x; that is, x times any polynomial p(x) is just p(x). Also, polynomials can be evaluated by specializing x to a real number. More precisely, for any given real number r, there is a unique unital R-algebra homomorphism evr : R[x] → R such that evr(x) = r. Because evr is unital, evr(x) = 1. That is, r = 1 for each real number r, including 0. The same argument applies with R replaced by any ring.
Defining 0 = 1 is necessary for many polynomial identities. For example, the binomial theorem ( 1 + x ) n = ∑ k = 0 n ( n k ) x k {\textstyle (1+x)^{n}=\sum _{k=0}^{n}{\binom {n}{k}}x^{k}} holds for x = 0 only if 0 = 1.
Similarly, rings of power series require x to be defined as 1 for all specializations of x. For example, identities like 1 1 − x = ∑ n = 0 ∞ x n {\textstyle {\frac {1}{1-x}}=\sum _{n=0}^{\infty }x^{n}} and e x = ∑ n = 0 ∞ x n n ! {\textstyle e^{x}=\sum _{n=0}^{\infty }{\frac {x^{n}}{n!}}} hold for x = 0 only if 0 = 1.
In order for the polynomial x to define a continuous function R → R, one must define 0 = 1.
In calculus, the power rule d d x x n = n x n − 1 {\textstyle {\frac {d}{dx}}x^{n}=nx^{n-1}} is valid for n = 1 at x = 0 only if 0 = 1.
Limits involving algebraic operations can often be evaluated by replacing subexpressions with their limits; if the resulting expression does not determine the original limit, the expression is known as an indeterminate form. The expression 0 is an indeterminate form: Given real-valued functions f(t) and g(t) approaching 0 (as t approaches a real number or ±∞) with f(t) > 0, the limit of f(t) can be any non-negative real number or +∞, or it can diverge, depending on f and g. For example, each limit below involves a function f(t) with f(t), g(t) → 0 as t → 0 (a one-sided limit), but their values are different: lim t → 0 + t t = 1 , {\displaystyle \lim _{t\to 0^{+}}{t}^{t}=1,} lim t → 0 + ( e − 1 / t 2 ) t = 0 , {\displaystyle \lim _{t\to 0^{+}}\left(e^{-1/t^{2}}\right)^{t}=0,} lim t → 0 + ( e − 1 / t 2 ) − t = + ∞ , {\displaystyle \lim _{t\to 0^{+}}\left(e^{-1/t^{2}}\right)^{-t}=+\infty ,} lim t → 0 + ( e − 1 / t ) a t = e − a . {\displaystyle \lim _{t\to 0^{+}}\left(e^{-1/t}\right)^{at}=e^{-a}.}
Thus, the two-variable function x, though continuous on the set {(x, y) : x > 0}, cannot be extended to a continuous function on {(x, y) : x > 0} ∪ {(0, 0)}, no matter how one chooses to define 0.
On the other hand, if f and g are analytic functions on an open neighborhood of a number c, then f(t) → 1 as t approaches c from any side on which f is positive. This and more general results can be obtained by studying the limiting behavior of the function log ⁡ ( f ( t ) g ( t ) ) = g ( t ) log ⁡ f ( t ) {\textstyle \log(f(t)^{g(t)})=g(t)\log f(t)} .
In the complex domain, the function z may be defined for nonzero z by choosing a branch of log z and defining z as e. This does not define 0 since there is no branch of log z defined at z = 0, let alone in a neighborhood of 0.
In 1752, Euler in Introductio in analysin infinitorum wrote that a = 1 and explicitly mentioned that 0 = 1. An annotation attributed to Mascheroni in a 1787 edition of Euler's book Institutiones calculi differentialis offered the "justification"
0 0 = ( a − a ) n − n = ( a − a ) n ( a − a ) n = 1 {\displaystyle 0^{0}=(a-a)^{n-n}={\frac {(a-a)^{n}}{(a-a)^{n}}}=1}
as well as another more involved justification. In the 1830s, Libri published several further arguments attempting to justify the claim 0 = 1, though these were far from convincing, even by standards of rigor at the time.
Euler, when setting 0 = 1, mentioned that consequently the values of the function 0 take a "huge jump", from ∞ for x < 0, to 1 at x = 0, to 0 for x > 0. In 1814, Pfaff used a squeeze theorem argument to prove that x → 1 as x → 0.
On the other hand, in 1821 Cauchy explained why the limit of x as positive numbers x and y approach 0 while being constrained by some fixed relation could be made to assume any value between 0 and ∞ by choosing the relation appropriately. He deduced that the limit of the full two-variable function x without a specified constraint is "indeterminate". With this justification, he listed 0 along with expressions like ⁠0/0⁠ in a table of indeterminate forms.
Apparently unaware of Cauchy's work, Möbius in 1834, building on Pfaff's argument, claimed incorrectly that f(x) → 1 whenever f(x),g(x) → 0 as x approaches a number c (presumably f is assumed positive away from c). Möbius reduced to the case c = 0, but then made the mistake of assuming that each of f and g could be expressed in the form Px for some continuous function P not vanishing at 0 and some nonnegative integer n, which is true for analytic functions, but not in general. An anonymous commentator pointed out the unjustified step; then another commentator who signed his name simply as "S" provided the explicit counterexamples (e) → e and (e) → e as x → 0 and expressed the situation by writing that "0 can have many different values".
There do not seem to be any authors assigning 0 a specific value other than 1.
The IEEE 754-2008 floating-point standard is used in the design of most floating-point libraries. It recommends a number of operations for computing a power:
The pow variant is inspired by the pow function from C99, mainly for compatibility. It is useful mostly for languages with a single power function. The pown and powr variants have been introduced due to conflicting usage of the power functions and the different points of view (as stated above).
The C and C++ standards do not specify the result of 0 (a domain error may occur). But for C, as of C99, if the normative annex F is supported, the result for real floating-point types is required to be 1 because there are significant applications for which this value is more useful than NaN (for instance, with discrete exponents); the result on complex types is not specified, even if the informative annex G is supported. The Java standard, the .NET Framework method System.Math.Pow, Julia, and Python also treat 0 as 1. Some languages document that their exponentiation operation corresponds to the pow function from the C mathematical library; this is the case with Lua's ^ operator and Perl's ** operator (where it is explicitly mentioned that the result of 0**0 is platform-dependent).
R, SageMath, and PARI/GP evaluate x to 1. Mathematica simplifies x to 1 even if no constraints are placed on x; however, if 0 is entered directly, it is treated as an error or indeterminate. Mathematica and PARI/GP further distinguish between integer and floating-point values: If the exponent is a zero of integer type, they return a 1 of the type of the base; exponentiation with a floating-point exponent of value zero is treated as undefined, indeterminate or error.