is the symbol for the Boolean value true.
Background & Context
- True is the symbol that represents the Boolean value true. Expressions that can be rigorously established to be true return this symbol. Examples of testing expressions that may return True include Equal, Unequal, SameQ, UnsameQ, Less/Greater/etc., Exists, and quantifier elimination via Resolve. While "Q"-functions (e.g. TrueQ, SameQ, UnsameQ) always return True or False, non-Q comparison and equality-testing functions (e.g. Equal, Unequal, Less, Greater) return unevaluated when they cannot be definitively resolved. Constructs that can be used to take a different evaluation path depending on if a condition is True or False include If, Which, and Piecewise.
- The negation Not[True] of True is given by False. The domain consisting of True and False is denoted Booleans.
- TrueQ is a special case of If that yields True if an expression is explicitly True, and otherwise yields False.
Examplesopen allclose all
Introduced in 1988