Sign up ×
Mathematica Stack Exchange is a question and answer site for users of Mathematica. It's 100% free, no registration required.

First of all, it appears to me that

$$\left|\frac{1}{x} + x^2\right| \Leftrightarrow \frac{|1 + x^3|}{|x|}$$

is true.

I don't know why, but my attempt to verify it in Mathematica failed.

In[1]:= Abs[1/x + x^2] === Abs[1 + x^3]/Abs[x]
Out[1]= False

It's weird because Mathematica is unable to find a counterexample.

In[2]:= FindInstance[Abs[1/x + x^2] != Abs[1 + x^3]/Abs[x], x, Complexes]
Out[2]= {}
share|improve this question
Somewhat related: (8796) – Mr.Wizard Dec 15 '13 at 1:50

1 Answer 1

up vote 15 down vote accepted

You are using SameQ which does a direct structural comparison rather than a mathematical one. Since the expressions are not exactly the same it returns False. Try Equal:

FullSimplify[Abs[1/x + x^2] == Abs[1 + x^3]/Abs[x]]

FullSimplify is needed for nontrivial comparisons; without it Mathematica will return the equality as given if it is not trivially equivalent.

You can also use ForAll and Resolve which I think is sometimes faster (no example at hand):

ForAll[x, x != 0, Abs[1/x + x^2] == Abs[1 + x^3]/Abs[x]] // Resolve
share|improve this answer
Sorry, but no ForAll[x, Abs[1/x + x^2] == Abs[1 + x^3]/Abs[x]] // Resolve send False – mlpo Dec 15 '13 at 1:40
@mlpo Strange, it returns True in version 7. What version are you using? – Mr.Wizard Dec 15 '13 at 1:43
@Mr.Wizard Windows 8 Mathematica 9.01 False – Alex Dec 15 '13 at 1:46
@mlpo Okay, I think I have an explanation for that behavior. If x is zero we have an indeterminate expression; I think later versions may recognize this while v7 does not? In that sense your equivalence is actually false, yet that is not the result you wanted. – Mr.Wizard Dec 15 '13 at 1:46
9.0.1, but I found the problem, when x = 0. Try with ForAll[x, x != 0, Abs[1/x + x^2] == Abs[1 + x^3]/Abs[x]] // Resolve – mlpo Dec 15 '13 at 1:47

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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