RealValuedNumberQ
RealValuedNumberQ[expr]
returns True if expr is a number with a real value and False otherwise.
Examples
open allclose allScope (8)
Integers are real-valued numbers:
Rational numbers are real valued:
Approximate reals are real-valued numbers:
Complex numbers are not real valued:
Approximate complex numbers are not considered real valued even if their imaginary part equals zero:
RealValuedNumberQ gives False for expressions that are real valued but not explicitly numbers:
RealValuedNumberQ[Infinity] gives False:
RealValuedNumberQ[Overflow[]] and RealValuedNumberQ[Underflow[]] give True:
They are both treated as Real:
Properties & Relations (3)
RealValuedNumberQ is effectively equivalent to MatchQ[#,_Integer _Rational _Real]&:
RealValuedNumberQ[x] is equivalent to NumberQ[x]&&Head[x]=!=Complex:
If RealValuedNumberQ[x] is True, then RealValuedNumericQ[x] is also True:
Text
Wolfram Research (2023), RealValuedNumberQ, Wolfram Language function, https://reference.wolfram.com/language/ref/RealValuedNumberQ.html.
CMS
Wolfram Language. 2023. "RealValuedNumberQ." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/RealValuedNumberQ.html.
APA
Wolfram Language. (2023). RealValuedNumberQ. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/RealValuedNumberQ.html