$$ x + yi = (a + bi)^{c+di} $$
Find $x$ and $y$ in terms of $a$, $b$, $c$ and $d$.
Where, $i$ is defined as $\sqrt{-1}$ and $a$, $b$, $c$, $d$ are real numbers.
I defined two new real number variables
$$ r = \sqrt{a^2 + b^2} \\ \theta = arg(a + bi). $$
The expression becomes
$$ x + yi = \left(re^{\theta i}\right)^{c+di} = r^{c+di}e^{-\theta d + \theta c i} = \left[r^{c}e^{-\theta d}\right]r^{di}e^{\theta c i} = \left[r^{c}e^{-\theta d}\right]r^{di}(cos(\theta c) + isin(\theta c)) \\ = r^{di}\left[r^{c}e^{-\theta d}cos(\theta c) + ir^{c}e^{-\theta d}sin(\theta c)\right]. $$
I'm not able to go on any further because of the term $r^{di}$. I don't know how to open it.
Step by step:
$$ \begin{array}{rcl} && x + jy = (a + jb)^{c+jd} \\ &=& (re^{j\theta})^{c+jd} \\ &=& r^{c+jd} (e^{j\theta})^{c+jd} \\ &=& r^cr^{jd} e^{j\theta c}e^{-\theta d} \\ &=& r^c e^{\displaystyle\ln r^{jd}} e^{j\theta c}e^{-\theta d} \\ &=& r^c e^{-\theta d} e^{\displaystyle jd \ln r} e^{\displaystyle j\theta c} \\ &=& r^c e^{-\theta d} e^{\displaystyle j(d \ln r + \theta c)} \\ &=& r^c e^{-\theta d} [\cos(d \ln r + \theta c) + j\sin(d \ln r + \theta c)] \\ &=& [r^c e^{-\theta d} \cos(d \ln r + \theta c)] + j[r^c e^{-\theta d}\sin(d \ln r + \theta c)] \\ &=& \left[(a^2+b^2)^{c/2} e^{-\theta d} \cos\left(d \ln(\sqrt{a^2+b^2}) + \theta c\right)\right] + \\ && \left[(a^2+b^2)^{c/2} e^{-\theta d}\sin\left(d \ln((a^2+b^2)^{1/2}) + \theta c\right)\right]j \\ &=& \left[(a^2+b^2)^{c/2} e^{-\theta d} \cos\left(\frac{d}{2} \ln(a^2+b^2) + \theta c\right)\right] + \\ && \left[(a^2+b^2)^{c/2} e^{-\theta d}\sin\left(\frac{d}{2} \ln(a^2+b^2) + \theta c\right)\right]j \\ &=& \begin{cases} \left[(a^2+b^2)^{c/2} e^{-d\arctan(\frac{b}{a})} \cos\left(\frac{d}{2} \ln(a^2+b^2) + c\,\arctan(\frac{b}{a})\right)\right] + &\\ \left[(a^2+b^2)^{c/2} e^{-d\arctan(\frac{b}{a})} \sin\left(\frac{d}{2} \ln(a^2+b^2) + c\,\arctan(\frac{b}{a})\right)\right]j & \text{if} \; a\!>\!0 \\ \left[(a^2+b^2)^{c/2} e^{-d\arctan(\frac{b}{a}) - \pi d} \cos\left(\frac{d}{2} \ln(a^2+b^2) + c\,\arctan(\frac{b}{a}) + \pi c\right)\right] + & \\ \left[(a^2+b^2)^{c/2} e^{-d\arctan(\frac{b}{a}) - \pi d} \sin\left(\frac{d}{2} \ln(a^2+b^2) + c\,\arctan(\frac{b}{a}) + \pi c\right)\right]j & \text{if} \; a\!<\!0 \; \text{and} \; b \!\ge\! 0 \\ \left[(a^2+b^2)^{c/2} e^{-d\arctan(\frac{b}{a}) + \pi d} \cos\left(\frac{d}{2} \ln(a^2+b^2) + c\,\arctan(\frac{b}{a}) - \pi c\right)\right] + & \\ \left[(a^2+b^2)^{c/2} e^{-d\arctan(\frac{b}{a}) + \pi d} \sin\left(\frac{d}{2} \ln(a^2+b^2) + c\,\arctan(\frac{b}{a}) - \pi c\right)\right]j & \text{if} \; a\!<\!0 \; \text{and} \; b\!<\!0 \\ \left[(a^2+b^2)^{c/2} e^{-\frac{\pi d}{2}} \cos\left(\frac{d}{2} \ln(a^2+b^2) + \frac{\pi c}{2}\right)\right] + & \\ \left[(a^2+b^2)^{c/2} e^{-\frac{\pi d}{2}} \sin\left(\frac{d}{2} \ln(a^2+b^2) + \frac{\pi c}{2}\right)\right]j & \text{if} \; a\!=\!0 \; \text{and} \; b\!>\!0 \\ \left[(a^2+b^2)^{c/2} e^{+\frac{\pi d}{2}} \cos\left(\frac{d}{2} \ln(a^2+b^2) - \frac{\pi c}{2}\right)\right] + & \\ \left[(a^2+b^2)^{c/2} e^{+\frac{\pi d}{2}} \sin\left(\frac{d}{2} \ln(a^2+b^2) - \frac{\pi c}{2}\right)\right]j & \text{if} \; a\!=\!0 \; \text{and} \; b\!<\!0 \\ 0 & \text{if} \; a\!=\!0 \; \text{and} \; b\!=\!0 \\ \end{cases} \end{array} $$
Implementation in computer:
Testing for $e^{j\pi}\!=\!-1$:
Program output:
My implementation calculates $e^{j\pi}$ as $-1\!+\!j1.22465\!\times\!10^{-16}$. I don't know the reason for the error in the imaginary part, but the result is still very close enough to the actual one.