If I run this line of code

Assuming[{Element[a, Reals], a > 0}, TrigToExp[ComplexExpand[Sqrt[a]]]]

I get

(a^2)^(1/4) E^(1/2 I Arg[a]).

Why does Mathematica assume that the parameter a has a phase, after I declared that it is real and positive?

  • 3
    $\begingroup$ Most Mathematica functions ignore assumptions. TrigToExp appears to be one of those. $\endgroup$ – John Doty Jan 10 at 22:03
  • 2
    $\begingroup$ Could use Refine, as that accounts for assumptions. $\endgroup$ – Daniel Lichtblau Jan 10 at 22:37
  • 1
    $\begingroup$ Simplify[TrigToExp[ComplexExpand[Sqrt[a]]], Assumptions -> {a \[Element] Reals, a > 0}] yields the expected result $\endgroup$ – Mat Jan 11 at 0:03
  • 1
    $\begingroup$ Only functions whose Options include Assumptions make use of $Assumptions or the assumptions specified in Assuming. Neither TrigToExp nor ComplexExpand take the option Assumptions. $\endgroup$ – Bob Hanlon Jan 11 at 2:41

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Browse other questions tagged or ask your own question.