This site is supported by donations to The OEIS Foundation.

# The special case of zero to the zeroth power

Some calculators, when asked to compute ${\displaystyle \scriptstyle 0^{0}\,}$, the zeroth (also spelled zeroeth) power of 0, will return 1 as the result. Others will lock up and require the clear error key to be pressed before doing anything else. Computer algebra systems like Sage and Pari return 1. The return value of Maple depends on the release, old releases returned 'not defined', newer releases return 1 in the case of the integer power function. Mathematica will return Indeterminate.

According to the IEEE standard, the result of the pow and the integer pown functions is 1.0 (with no error). The standard defines an additional function powr with the value NaN for 0^0, but this function is not widely available. Modern computer languages like C# accordingly compute pow(0, 0) = 1.

Aside from mathematicians, scientists and engineers, lots of people incorrectly think that the answer is 0.[1]

## In discrete mathematics

### The binomial expansion formula requires 0! = 1 and 0 0 = 1

In algebra, for the binomial expansion

${\displaystyle (1+x)^{n}=\sum _{i=0}^{n}{\binom {n}{i}}\,x^{n-i}\equiv \sum _{i=0}^{n}{\frac {n!}{i!\,(n-i)!}}\,x^{n-i}={\frac {n!}{0!\,(n-0)!}}\,x^{n-0}+~\cdots ~+{\frac {n!}{n!\,(n-n)!}}\,x^{n-n},\,}$

where the ${\displaystyle \scriptstyle {\binom {n}{i}}\,}$ are binomial coefficients, we need

${\displaystyle 0!=1,\ 0^{0}=1.\,}$

For example

${\displaystyle (1+x)^{3}=\sum _{i=0}^{3}{\binom {3}{i}}\,x^{3-i}={\frac {3!}{0!\,3!}}\,x^{3}+{\frac {3!}{1!\,2!}}\,x^{2}+{\frac {3!}{2!\,1!}}\,x^{1}+{\frac {3!}{3!\,0!}}\,x^{0}=1x^{3}+3x^{2}+3x^{1}+1x^{0}=x^{3}+3x^{2}+3x^{1}+1\,}$

Especially, for the constant term, we need ${\displaystyle \scriptstyle x^{0}\,}$ to be 1 for any value of ${\displaystyle \scriptstyle x\,}$, including ${\displaystyle \scriptstyle x\,=\,0\,}$. We may define those two values by convention or we may rely on the concept of empty product, defined as the multiplicative identity, i.e. 1, to provide us the value 1 for both cases. Since the factorial of ${\displaystyle \scriptstyle n\,}$ is defined as the product of positive integers up to ${\displaystyle \scriptstyle n,\,}$ the factorial of 0 is effectively the empty product. And since ${\displaystyle \scriptstyle n^{0}\,}$ means multiply the base ${\displaystyle \scriptstyle n\,}$ by itself zero times, i.e. don't ever multiply, this is also effectively the empty product and it doesn't matter what the base ${\displaystyle \scriptstyle n\,}$ is, since we don't ever use it.

Now, defining ${\displaystyle \scriptstyle 0!\,=\,1\,}$ and ${\displaystyle \scriptstyle 0^{0}\,=\,1\,}$ to suit this context does not contradict other mathematical contexts where those might be indeterminate. For example, if we consider ${\displaystyle \scriptstyle n\,=\,0\,}$ in

${\displaystyle n^{0}=n^{k-k}={\frac {n^{k}}{n^{k}}},k\neq 0,\,}$

we get

${\displaystyle 0^{0}=0^{k-k}={\frac {0^{k}}{0^{k}}}={\frac {0}{0}},k\neq 0,\,}$

giving the indeterminate quotient ${\displaystyle \scriptstyle {\frac {0}{0}},\,}$ so we cannot define ${\displaystyle \scriptstyle 0^{0}\,}$ this way.

What would be a problem is if other mathematical contexts required different definitions, e.g. if other contexts (is there any?) required ${\displaystyle \scriptstyle 0!\,=\,0,\,0^{0}\,=\,0,\,}$ in which case we would have to consider those values indeterminate.

## In analysis

### Taylor series expansions require 0! = 1 and 0 0 = 1

Taylor series expansions like

${\displaystyle e^{x}=\sum _{n=0}^{\infty }{\frac {x^{n}}{n!}}}$

require ${\displaystyle \scriptstyle 0!\,=\,1\,}$ and ${\displaystyle \scriptstyle 0^{0}\,=\,1\,}$ to be valid at ${\displaystyle \scriptstyle x\,=\,0\,}$.

### Limits

We may consider different limits and what should be the value of ${\displaystyle \scriptstyle 0^{0}\,}$ if we wanted continuity at ${\displaystyle \scriptstyle x\,=\,0,\,}$ although those continuity arguments do not have the weight of the strict requirement for the binomial expansion formula.

#### Limit of 1/x, x → 0

There are those who will argue that any nonzero value divided by zero is infinity (zero divided by zero being indeterminate), thus zero to a negative power is infinity, on the evidence of such graphs as of the mapping of ${\displaystyle \scriptstyle {\frac {1}{x}}\,}$ from ${\displaystyle \scriptstyle \mathbb {R} \,}$ to ${\displaystyle \scriptstyle \mathbb {R} \,}$:

As positive ${\displaystyle \scriptstyle x\,}$ gets very small and tends towards 0, ${\displaystyle \scriptstyle {\frac {1}{x}}\,}$ does get very large and grows towards infinity from the positive direction (arbitrary large but finite positive values.) On the other side of the vertical axis, as negative ${\displaystyle \scriptstyle x\,}$ gets very small and tends towards 0, ${\displaystyle \scriptstyle {\frac {1}{x}}\,}$ grows towards infinity from the negative direction (arbitrary large but finite negative values.) Note that there is only one absolute infinity and it has no direction, whereas the potential infinities (arbitrary large but finite values) do have a direction (negative or positive in the case of the real line, any angle in the case of the complex plane).

If we consider the mapping of ${\displaystyle \scriptstyle {\frac {1}{z}}\,}$ from ${\displaystyle \scriptstyle \mathbb {C} \,}$ to ${\displaystyle \scriptstyle \mathbb {C} \,}$, then as the norm ${\displaystyle \scriptstyle \rho \,}$ of ${\displaystyle \scriptstyle z\,=\,\rho e^{i\theta }\,}$ gets very small and tends towards 0 (thus ${\displaystyle \scriptstyle z\,}$ tending towards 0 from direction ${\displaystyle \scriptstyle \theta \,}$,) ${\displaystyle \scriptstyle {\frac {1}{z}}\,=\,\rho ^{-1}e^{-i\theta }\,}$ grows towards infinity from direction ${\displaystyle \scriptstyle -\theta \,}$. When we consider the mapping from ${\displaystyle \scriptstyle \mathbb {R} \,}$ to ${\displaystyle \scriptstyle \mathbb {R} \,}$, ${\displaystyle \scriptstyle {\frac {1}{x}}\,}$ grows towards infinity from the directions ${\displaystyle \scriptstyle \theta \,=\,0\,}$ or ${\displaystyle \scriptstyle \theta \,=\,\pi \,}$. When we consider ${\displaystyle \scriptstyle \lim _{\rho \to 0}\rho ^{-1}e^{-i\theta }\,}$ we are considering potentially infinite norms (arbitrarily large but finite norms) so there is a defined direction. When we consider the norm ${\displaystyle \scriptstyle \rho \,}$ of ${\displaystyle \scriptstyle z\,=\,\rho e^{i\theta }\,}$ to be absolute 0, then ${\displaystyle \scriptstyle \theta \,}$ is meaningless (no direction) and ${\displaystyle \scriptstyle {\frac {1}{z}}\,}$ is ${\displaystyle \scriptstyle \infty .\,}$

#### Limit of x 0, x → 0

Consider the graph of ${\displaystyle \scriptstyle x^{0}\,}$ for ${\displaystyle \scriptstyle x\,\to \,0.\,}$

If we wanted continuity at ${\displaystyle \scriptstyle x\,=\,0,\,}$ we would need ${\displaystyle \scriptstyle 0^{0}\,\equiv \,1.\,}$

#### Limit of 0 x, x → 0

Now, consider the graph of ${\displaystyle \scriptstyle 0^{x}\,}$ for ${\displaystyle \scriptstyle x\,\to \,0\,}$ instead.

If we consider the graph of ${\displaystyle \scriptstyle 0^{x},\,}$ we obtain 0 for positive ${\displaystyle \scriptstyle x\,}$ and infinity for negative ${\displaystyle \scriptstyle x\,}$, thus not continuous at ${\displaystyle \scriptstyle x\,=\,0\,}$. If we wanted continuity from the right (i.e. for nonnegative ${\displaystyle \scriptstyle x\,}$) at ${\displaystyle \scriptstyle x\,=\,0,\,}$ we would need ${\displaystyle \scriptstyle 0^{0}\,\equiv \,0.\,}$

The OEIS has sequences for both interpretations: A000007 lists the powers of zero with ${\displaystyle \scriptstyle 0^{0}=1\,}$, while A000004 accords with the interpretation ${\displaystyle \scriptstyle 0^{0}\,=\,0.\,}$

(...)

## Sequences

A000007: The characteristic function of 0: a(n) = 0^n.

{1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ...}

A000004: The zero sequence.

{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ...}

## Notes

1. Alonso del Arte, Pop Quiz: What is 0^0?, Wayne State University College of Engineering. Most engineering students polled gave 1 as the answer, but almost all technicians in the call center, who are not engineers, gave 0 as the answer.