0
$\begingroup$

Applying "FullSimplify" fails to simplify the following expressions:

Input:

FullSimplify[(-0.0001+0.01*I)*E^((-1.6*10^7-2.1*10^8*I)*t)-(0.0001+0.01*I)*E^((-1.6*10^7+2.1*10^8*I)*t)]

Output:

(-0.0001 + 0.01 I) E^((-1.6*10^7 - 2.1*10^8 I) t) - (0.0001 + 0.01 I) E^((-1.6*10^7 + 2.1*10^8 I) t)

However, in fact, by applying Euler's formula, the above expression can be manually simplified to:

-2*(0.0001*Cos[-2.1*10^8*t] + 0.01*Sin[-2.1*10^8*t])*E^(-1.6*10^7*t)

How can I do to simplify to this form in Mathematica?

Thank you very much!

$\endgroup$
2
  • $\begingroup$ Have you already seen ExpToTrig[]? $\endgroup$ Jun 10, 2022 at 15:52
  • $\begingroup$ ExpToTrig[] makes the expression more complex. The output is: (-0.0001 - 0.01 I) Cos[(2.1*10^8 + 1.6*10^7 I) t] - (0.0001 - 0.01 I) Cosh[(1.6*10^7 + 2.1*10^8 I) t] + (0.01 - 0.0001 I) Sin[(2.1*10^8 + 1.6*10^7 I) t] + (0.0001 - 0.01 I) Sinh[(1.6*10^7 + 2.1*10^8 I) t]. Moreover, the terms of Sinh[] and Cosh[] cannot be cancelled out with TrigExpand[] or TrigReduce[]. $\endgroup$
    – Jeremy
    Jun 10, 2022 at 15:59

1 Answer 1

2
$\begingroup$
expr = (-0.0001 + 0.01*I)*
   E^((-1.6*10^7 - 2.1*10^8*I)*t) - (0.0001 + 0.01*I)*
   E^((-1.6*10^7 + 2.1*10^8*I)*t)

ComplexExpand[expr, TargetFunctions -> {Abs, Arg}] // 
  TrigReduce // Chop

$$-0.0002 e^{-1.6\times 10^7 t} (1. \cos (2.1\times 10^8 t)-100. \sin (2.1\times 10^8 t))$$

$\endgroup$
1
  • 1
    $\begingroup$ Thanks, your method solved my problem! $\endgroup$
    – Jeremy
    Jun 11, 2022 at 13:47

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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