This is documentation for Mathematica 8, which was
based on an earlier version of the Wolfram Language.

# Unequal

 or returns False if lhs and rhs are identical.
• returns True if lhs and rhs are determined to be unequal by comparisons between numbers or other raw data, such as strings.
• Approximate numbers are considered unequal if they differ beyond their last two decimal digits.
• gives True only if none of the are equal. False.
• represents a symbolic condition that can be generated and manipulated by functions like Reduce and LogicalExpand.
• For exact numeric quantities, Unequal internally uses numerical approximations to establish inequality. This process can be affected by the setting of the global variable \$MaxExtraPrecision.
Returns True if elements are guaranteed unequal, and otherwise stays unevaluated:
Enter as != or as Esc != Esc:
Returns True if elements are guaranteed unequal, and otherwise stays unevaluated:
 Out[1]=

Enter as != or as Esc != Esc:
 Out[1]=
 Scope   (11)
Test unequality of numbers:
Approximate numbers that differ in at most their last eight binary digits are considered equal:
Compare an exact numeric expression and an approximate number:
Compare two exact numeric expressions; a numeric test may suffice to prove unequality:
Proving equality requires symbolic methods:
Symbolic methods used by Unequal are insufficient to prove this False:
Use RootReduce to decide whether two algebraic numbers are unequal:
Numeric methods used by Unequal do not use sufficient precision to prove this unequality:
RootReduce proves that the two algebraic numbers are not equal:
Increasing \$MaxExtraPrecision may also prove unequality:
This symbolic unequality is always False:
Unequal does not automatically prove this unequality:
Use Expand to prove it:
Compare more than two expressions:
Compare lists:
Compare strings:
The negation of two-argument Unequal is Equal:
The negation of three-argument Unequal does not simplify automatically:
Use LogicalExpand to express it in terms of two-argument Equal:
The negation of three-argument Unequal is not equivalent to three-argument Equal:
Unequal tests mathematical unequality of objects represented by expressions:
UnsameQ tests syntactic unequality of expressions:
When Unequal cannot decide whether two numeric expressions are equal it returns unchanged:
FullSimplify uses exact symbolic transformations to disprove the unequality:
PossibleZeroQ uses numeric and symbolic heuristics to decide whether an expression is zero:
Numeric methods used by PossibleZeroQ may incorrectly decide that a number is zero:
Unequality for machine-precision approximate numbers can be subtle:
The extra digits disrupt equality:
Arbitrary-precision approximate numbers do not have this problem:
Thanks to automatic-precision tracking, Unequal knows to look only at the first 10 digits:
In this case, the unequality test for machine numbers gives the expected result:
The extra digits in this case are ignored by Unequal: