How to solve for negative numbers in logarithmic equations I am trying to solve the equation
$$z^n = 1.$$
Taking $\log$ on both sides I get $n\log(z) = \log(1) = 0$.
$\implies$ $n = 0$ or $\log(z) = 0$
$\implies$ $n = 0$ or $z = 1$.
But I clearly missed out $(-1)^{\text{even numbers}}$ which is equal to $1$.
How do I solve this equation algebraically?
 A: You can't take the logarithm of a negative number, unless you consider the multivalued complex logarithm.
If you are willing to expand to complex numbers in that manner, then you can take the log of both sides. $\log(1) = 2\pi i k$, $k \in \mathbb{N}$, so then you're solving for $n \log(z) = 2 \pi i k $, which gives $\log z = 2\pi i\frac{k}{n}$, or $z = e^{2 \pi i\frac{k}{n}}$, which describes all of the roots of unity.
A: Working in the reals, take the $n$th root of both sides. 
If $n$ is even then you'd write $(z^n)^{1/n}=|z|$.
For example $z^2=1 \iff (z^2)^{1/2}=1^{1/2} \iff |z|=1$.
For odd powers, you could say, for example:
$z^3=1 \iff (z^3)^{1/3}=1^{1/3} \iff  z =1$.
A: If you want to do this properly you need complex numbers.  The logarithm is a multivalued function; $z^n = 1$ is equivalent not to $n \log z = \log 1$ but to 
$n \log z = 2 \pi i m$ where $m$ is an arbitrary integer.  If $n \ne 0$ this says
$\log z = (2 \pi i m)/n$ and $z = e^{2 \pi i m/n}$.  In particular with $n = 2 m$, $z = e^{\pi i} = -1$.
A: First of all, note that, apart from $z=1$, all other answers will be complex. For the equation
$z^n=1$, we use the theorems $e^{ix}=cosx + i sin x$ and that $(cosx + i sin x)^{n}=cos(nx)+ sin(nx)$.
Then, $z^n=1$ implies $r^n(cos(nx)+ sin(nx))=1$, where $z=re^{ix}$. Hence, $r=1$ and
$cos(nx)+ isin(nx)=1$. Thus, $cos(nx)=1$ and $sin(nx)=0$, equating real and imaginary parts separately.
That gives the answer $z=cos(\frac{2\pi}{k})+isin(\frac{2\pi}{k}), k=1,2 \cdots (n-1)$
A: To solve it algebraically, I'd say:


*

*For even values of $n$, $z=1$ or $z=-1$ are the solutions.

*For odd values of $n$, $z=1$ is the answer.

*And if $n=0$, $\forall z \in \mathbb{R}$ would be valid as an answer.

