0
$\begingroup$

I want to solve the following equation for $\theta$

$$ e^{i2\theta} = x $$

where both $x$ and $\theta$ can be complex numbers. Judging from WolframAlpha's solution it is not simply taking the logarithm and rearranging for $\theta$. What is the correct way to solve this?

  • 0
    Can $\theta$ be a complex number?2017-01-27
  • 0
    Yes it can. updated the question.2017-01-27

3 Answers 3

0

Write $x = e^{\text{Log} x}$ ($\text{Log}$ is the principal branch of logarithm - defined for $x \neq 0$; note that for $x=0$ there isn't a solution), and note that:

$$e^z = e^w \iff z = w + 2ik\pi, \text{ for some $k \in \Bbb Z$}$$

0

Well, we know Euler's formula:

$$e^{\varphi i}=\cos\varphi+i\sin\varphi\tag1$$

So, when we have for your LHS:

$$e^{2\theta i}=e^{2\left(\sigma+\zeta i\right)i}=e^{2\sigma i-2\zeta}=e^{2\sigma i}\cdot e^{-2\zeta}=\frac{\cos\left(2\sigma\right)+\sin\left(2\sigma\right)i}{e^{2\zeta}}\tag2$$

Where $\sigma$ is the real part of $\theta$ and $\zeta$ is the imaginary part of $\theta$.

So, we can setup a system of equations:

$$ \begin{cases} \frac{\cos\left(2\sigma\right)}{e^{2\zeta}}=\Re\left(x\right)\\ \\ \frac{\sin\left(2\sigma\right)}{e^{2\zeta}}=\Im\left(x\right) \end{cases}\space\space\space\space\space\space\therefore\space\space\space\space\space\space\frac{\cos\left(2\sigma\right)}{\Re\left(x\right)}=\frac{\sin\left(2\sigma\right)}{\Im\left(x\right)}\space\Longleftrightarrow\space\tan\left(2\sigma\right)=\frac{\Im\left(x\right)}{\Re\left(x\right)}\tag3 $$

  • 0
    The problem is that this does not give me the correct answers. I want to solve for the real part of $\theta$, so I did this in matlab: "theta_real = 1/2 * atan(imag(x)/real(x))".2017-01-27
  • 0
    @Yoda It actually do: $$\sigma=\frac{\arctan\left(\frac{\Im\left(x\right)}{\Re\left(x\right)}\right)+\pi\text{n}}{2}$$ Where $\text{n}\in\mathbb{Z}$. So when $\text{n}=0$: $$\sigma=\frac{\arctan\left(\frac{\Im\left(x\right)}{\Re\left(x\right)}\right)+\pi\cdot0}{2}=\frac{\arctan\left(\frac{\Im\left(x\right)}{\Re\left(x\right)}\right)}{2}$$2017-01-27
  • 0
    I'm not sure I follow when you set up the system of equations. Where did the factor of $i$ in $\sin(2\sigma)i$ go?2017-01-27
  • 0
    Well, you must know that: $i\cdot i=i^2=-1$ and in order to set up the system use real part of the RHS equals the LHS real part and vice versa for the imaginary part2017-01-27
  • 0
    Sorry, but I don't see how that helps. Is there a step I'm not able to see in going from (2) to the left side of $\therefore$.2017-01-27
0

For given $c\ne0$ the equation $e^z=c$ has infinitely many solutions $z\in{\mathbb C}$. The solution set $S$ is given by $$S=\log|c|+ i\>{\rm arg}(c)$$ and is a one-dimensional lattice in the vertical direction, spaced by $2\pi i$. If $z\in S$ is written as $z=2i\theta$, and the given $c$ is named $x$, then this amounts to $$\theta={1\over2i}\log|x|+{1\over2}{\rm arg}(x)\ .$$

  • 0
    How do I get the argument of x with matlab? Simply arg(x) does not work.2017-01-27