Why is $\left(e^{2\pi i}\right)^i \neq e^{-2 \pi}$?
Solution 1:
In complex numbers, either $x^y$ is a multivalued function, or you have to give up the notion that $(x^y)^z = x^{yz}$.
If you allow $x^y$ to be multi-valued, then one of the values for $1^i$ is $e^{-2\pi}$.
If $x^y$ is not multivalued, then you have to pick a single value for $\log 1$ to define $1^y$. We usually pick $\log 1 = 0$, for some reason. :)
The multivalued nature makes sense when you consider that $\sqrt{1}=1^{1/2}$ can be thought of as having two values, $-1$ and $1$. In general, though, when $y$ is irrational, you get $1^y$ (or more generally, $x^y$) can take infinitely many values.
The only time $x^y$ is naturally single-valued is when $y$ is an integer.
Solution 2:
The law of exponents $x^{ab} = (x^a)^b$ does not hold in general.
Raising numbers to complex powers is multivalued.
For example, $1^i = e^{\log(1^i)} = e^{i (\ln(1)+2\pi k i)} = e^{i(2\pi k i)} = e^{-2\pi k}$ for any integer $k$. Choosing $k=-1$ matches your left hand side, $k=0$ matches the right.