I am using Mathematica 11.1, and I stumbled upon this strange response using the Abs
function.
FullSimplify[Abs[x],x<0]
(* Abs[x] *)
while, for example
FullSimplify[Abs[x],x>0]
(* x *)
as expected.
My question: Why doesn't Mathematica simplify
Abs[x]
to-x
when it is given the extra informationx<0
? Could it be on purpose?
I looked for duplicates, but I could not find a question that was spot on. I'm sorry if I missed some question.
Abs[z] is left unevaluated if z is not a numeric quantity
So really, both cases should be left unevaluated. But looking atReduce[Abs[x] == x]
it saysRe[x] >= 0 && Im[x] == 0
so it seems like this is special case whereAbs[z]
is simplified toz
. But help says it should be unevaluated ifz
is not numeric! $\endgroup$FullSimplify
is applied? Maybe not. Always. It is still a bit confusing to me, if I per default have to count minus signs... $\endgroup$> Scope
there). $\endgroup$