TransWikia.com

Complex Exponentials to Trig Functions?

Mathematica Asked on June 1, 2021

I have an expression

expr = 1/2 a E^(-3 I ω t) (E^(3 I ω t)+2 Cos[π x/a]) (1+2 E^(3 I ω t) Cos[π x/a]) Sin[π x/a]^2;
expr // TeXForm

$frac{1}{2} a e^{-3 i t omega } sin ^2left(frac{pi x}{a}right) left(2 cos
left(frac{pi x}{a}right)+e^{3 i t omega }right) left(1+2 e^{3 i t omega }
cos left(frac{pi x}{a}right)right)$

It is in complex exponential form, and I need it in trigonometric form. How do I do this? I see that in the Wolfram Language (https://reference.wolfram.com/language/guide/ComplexNumbers.html) there is a function for it, but I do not seem to be able to use that, for when I enter it as an argument, nothing changes. I am using Mathematica 11.3. How would I go about getting this into trigonometric form?
Down at the bottom is the expression with complex terms I want to change to trigonometric terms

One Answer

Use ExpToTrig:

expr = 1/2 a E^(-3 I ω t) (E^(3 I ω t)+2 Cos[π x/a]) (1+2 E^(3 I ω t) Cos[π x/a]) Sin[π x/a]^2;

ExpToTrig[expr] //TeXForm

$frac{1}{2} a sin ^2left(frac{pi x}{a}right) (cos (3 t omega )-i sin (3 t omega )) left(2 cos left(frac{pi x}{a}right)+i sin (3 t omega )+cos (3 t omega )right) left(2 cos left(frac{pi x}{a}right) cos (3 t omega )+2 i cos left(frac{pi x}{a}right) sin (3 t omega )+1right)$

Answered by Carl Woll on June 1, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP