I have a bit of difficulty with this. I am trying to express $\sin x + \cos x$ with complex exponential.

I started by using Euler's equations. Then, I used the trigonometric substitution $\sin x = \cos(x+\pi/2)$. The problem is that I always end up with $i - 1$ and $i + 1$ (by using different exponent operations), and the fact $e^{i \pi/2} = 1$ and such.

I'm lost. It would be supposed to give me $\sqrt{2}\cos(X)$, where $X$ is undetermined. I just don't get it.

Could anyone help?


  • 1
    $\begingroup$ Take $z = e^{ix} + ie^{ix}$, then look at $$ \frac{z-\overline{z}}{2i} $$ $\endgroup$ – Prahlad Vaidyanathan Oct 4 '13 at 19:45

Your first guess (Euler's equation) was good. You have $$ e^{ix} = \cos(x) + i \sin(x), \qquad e^{-ix} = \cos(-x) + i \sin(-x) = \cos(x) - i \sin(x) $$ which implies that $$ \cos(x) = \frac {2\cos(x)}2 = \frac{\cos(x) + i \sin(x) + \cos(x) - i \sin(x)}2 = \frac{e^{ix} + e^{-ix}}2 $$ and $$ \sin(x) = \frac {2 i \sin(x)}{2i} = \frac{\cos(x) + i \sin(x) - \cos(x) + i \sin(x)}{2i} = \frac{e^{ix} - e^{-ix}}{2i}. $$ Then you can just add up the expressions and get your exponential formula.

Added : by adding up the previous two equations,

$$ \sin(x) + \cos(x) = \frac {(1-i)e^{ix}}2 + \frac{(1+i)e^{-ix}}2 = \frac 1{\sqrt 2} \left( e^{-i\pi/4}e^{ix} + e^{i\pi/4} e^{-ix} \right) = \frac {e^{i(x-\pi/4)} + e^{-i(x-\pi/4)}}{\sqrt 2} = \sqrt 2 \cos(x-\pi/4). $$

Hope that helps,

  • $\begingroup$ I'm sorry, it seems indeed the solution I was about to get, as stated I was ending up with (1 - i) and (1 + i). But I don't get how you got rid of these expressions. I'm sorry if I look like a dumbass, I really don't get it. Seems like you calculated the modulus of (1 - i) and (i + i), giving sqrt(2)/2 = 1/sqrt(2). Hum, can you tell me what you did :( thank you for taking all this time, im grateful $\endgroup$ – Yannick Oct 4 '13 at 20:37
  • $\begingroup$ Ohhhh nevermind. I got what you did there. Wow... I guess I gotta go bed... Thank you :) $\endgroup$ – Yannick Oct 4 '13 at 20:46
  • $\begingroup$ @Yannick : Haha, guess I didn't even have to work to help you, just had to wait a bit until you understood yourself! By the way, we've all thought we're a bit stupid every now and then, don't torture yourself over it. Feel free to green-check the answer if you like it. $\endgroup$ – Patrick Da Silva Oct 4 '13 at 21:22

$$ \sin(x)+\cos(x)=\sqrt{2}\left(\frac{1}{\sqrt{2}}\sin (x) + \frac{1}{\sqrt{2}}\cos (x)\right)=\\ \sqrt{2}\left(\sin(\pi/4)\sin (x) + \cos(\pi/4)\cos (x)\right)= \sqrt{2} \cos (x-\pi/4) $$

  • $\begingroup$ That is exactly what the result I'm supposed to get. Problem is... I gotta use complex exponential to achieve the same result. $\endgroup$ – Yannick Oct 4 '13 at 19:57
  • $\begingroup$ @Yannick : I thought you wanted an expression in terms of the complex exponential? This is just a shifted cosine. $\endgroup$ – Patrick Da Silva Oct 4 '13 at 19:57
  • $\begingroup$ Yes. The weird thing, the thing I don't get is... The question states "Use complex exponential to find the value of sinx + cosx" and the answer in the solutions is indeed the result found there. What I don't get it how the heck you'd do it with only complex exponential, without making it disgraceful i.e. by "truly" using complex exponential. It's a weird question I must admit. $\endgroup$ – Yannick Oct 4 '13 at 20:00
  • $\begingroup$ @Yannick : Well look at my answer huh! $\endgroup$ – Patrick Da Silva Oct 4 '13 at 20:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.