0
$\begingroup$

Why does something like Conjugate[Sqrt[Exp[I x]]] give output Conjugate[Sqrt[E^(I x)]] instead of Sqrt[E^(-I x)]?

In some places I get outputs such as: Conjugate[0.752066 E^((3 I \[Pi])/2 - (0. + 3.46164 I) x - x^2/2)]. Why does this happen?

$\endgroup$
6
  • 2
    $\begingroup$ Use ESC+e+e+ESC for e and ESC+i+i+ESC for i. $\endgroup$ Commented Jul 9 at 21:43
  • 2
    $\begingroup$ Or use Exp[I] $\endgroup$
    – mikado
    Commented Jul 9 at 21:57
  • 2
    $\begingroup$ Use Exp[ ] for exponential function and (capital) I for the imaginary unit. Conjugate[Exp[I]] correctly returns Exp[-I] as expected. $\endgroup$
    – A. Kato
    Commented Jul 10 at 0:42
  • $\begingroup$ I use ESC+e+e+ESC and the same for i. I only wrote like that for simplicity. Exp[I] works on its own, but not inside other functions. But still I was not aware of it thank you for pointing it out. $\endgroup$ Commented Jul 10 at 4:56
  • 1
    $\begingroup$ @A.Kato you are right. I will edit my question accordingly. $\endgroup$ Commented Jul 10 at 11:01

3 Answers 3

2
$\begingroup$

Mathematically speaking, conjugation of a function $\bar{f}(z)$ is not necessarily same as the same function evaluated at the conjugate argument $f(\bar{z})$. As an example, if $f(z)=z+i$, clearly $\bar{f}(z)\ne f(\bar{z})$. Therefore, Mathematica cannot replace $\bar{e}(z)$ with $e(\bar{z})$ if $e$ is undefined, which is why Conjugate[e^i] does not evaluate to something simpler

In case of Exp[x], Mathematica does realize that exponential is a function which obeys Schwarz Reflection Principle, hence evaluates Conjugate[Exp[f[x]]] to Exp[Conjugate[f[x]]].

$\endgroup$
3
  • $\begingroup$ There are outputs in my code that are of the form Conjugate[E^(0+0.37294 I)]. $\endgroup$ Commented Jul 10 at 5:46
  • 1
    $\begingroup$ @EFETÜRBEDAR Why didn't you add this concrete example Conjugate[E^(0+0.37294 I)] in your question? $\endgroup$ Commented Jul 10 at 8:39
  • $\begingroup$ @UlrichNeumann I really should have. I wiill fix my question. $\endgroup$ Commented Jul 10 at 11:03
2
$\begingroup$

Why does something like Conjugate[Sqrt[Exp[I x]]] give output Conjugate[Sqrt[E^(I x)]] instead of Sqrt[E^(-I x)]?

Because the two are not equivalent, for example:

{Conjugate[Sqrt[Exp[I x]]], Sqrt[E^(-I x)]} /. x -> 1 + I
FunctionExpand[%]
N[%%]

{Conjugate[Sqrt[E^(-1 + I)]], Sqrt[E^(1 - I)]}

{E^(-(1/2) - I/2), E^(1/2 - I/2)}

{0.532281 - 0.290786 I, 1.44689 - 0.790439 I}
$\endgroup$
2
  • $\begingroup$ Ok but they are the same when x is not complex, and even when it is shouldn't it output Sqrt[Exp[-I Conjugate[x]]] ? Also even after putting in values for x, I am left with expressions that have Conjugate[] in them. $\endgroup$ Commented Jul 10 at 18:49
  • $\begingroup$ @EFETÜRBEDAR "Also even after putting in values for x, I am left with expressions that have Conjugate[] in them." Use FunctionExpand afterwards like I did in my answer. Then maybe use also ComplexExpand if needed. $\endgroup$ Commented Jul 10 at 20:28
0
$\begingroup$

Do any of these help?

Complex $x$:

ComplexExpand[Conjugate[Sqrt[E^(I  x)]], x] // FullSimplify
(*  E^(-(Im[x]/2))/Sqrt[E^(I Re[x])]  *)

Real $x$:

ComplexExpand[Conjugate[Sqrt[E^(I  x)]]] // FullSimplify
(*  1/Sqrt[E^(I x)]  *)

Complex $x$:

PowerExpand[Conjugate[Sqrt[E^(I  x)]], Assumptions -> True]
(*  E^(-(1/2) I Conjugate[x] + I π Floor[1/2 - Re[x]/(2 π)])  *)

Real $x$:

PowerExpand[Conjugate[Sqrt[E^(I  x)]], 
 Assumptions -> x \[Element] Reals]
(*  E^(-((I x)/2) + I π Floor[1/2 - x/(2 π)])  *)
$\endgroup$

Your Answer

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

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