(Solved) Deriving Pi from Euler's Identity I was tinkering with Euler's Identity and I come to wonder if it was possible to derive $\pi$ from it. 

I know $\pi$ can't be expressed as a fraction of two rational numbers but neither $i$ nor $e$ is rational. 

$e^{\pi i} = -1$ (square both sides)

$e^{2\pi i} = 1$ (logarithm both sides)

$2\pi * i * \log e = \log 1 = 0$

This is how far I got before meeting a contradiction as this the left side equals roughly $9.1 i$. 
Is it even possible to derive $\pi$ from Euler's Identity and where have I messed up?
Let us write
$$\log(-1) = \pi i\tag{1}$$
We can make sense of this by defining
$$
\log(-1) := \int_1^{-1}\frac{dz}{z}
$$
where (since we cannot integrate through the pole at $z=0$) we integrate by convention along a curve in the upper half-plane.  For example along the sides of a rectangle.  Using numerical integration, we can compute $\pi$ numerically this way.

Historical: ($1$) appeared in the literature earlier than Euler's identity. 

Note: If we use curves not remaining in the upper half plane, we may get values other than $\pi i$ for the integral.
Well, if we know that

$e^{i\pi} = -1$

Then we can use log base e, or just ln() to take out the e and just get the pi*i, so:

$\ln(-1) = i\pi$

That was the hard part -- now we just have to divide by i:

$\frac{\ln(-1)}{i} = \pi$

And now we have pi!