I am trying to find the gradient of the phase of complex exponential functions.
For example:
Grad[Arg[Exp[-I (x + z)]], {x, z}]
Should be {1,1} for all x,z (Reals). However, instead I get:
{-I E^(-I (x + z))
Derivative[1][Arg][E^(-I (x + z))], -I E^(-I (x + z))
Derivative[1][Arg][E^(-I (x + z))]}
I think it has to do with the fact that Arg[Exp[-I (x + z)]]
doesn't return (x+z). I assumed that was because it doesn't know that x,z are Reals.
I also tried Refine[Arg[Exp[-I (x + z)]], x \[Element] Reals && z \[Element] Reals]
but that doesn't return (x+z) either.
Thanks!