Rationals

Rationals
represents the domain of rational numbers, as in .

DetailsDetails

  • evaluates immediately only if x is a numeric quantity.
  • Simplify[exprRationals] can be used to try to determine whether an expression corresponds to a rational number.
  • The domain of integers is taken to be a subset of the domain of rationals.
  • Rationals is output in TraditionalForm as .

ExamplesExamplesopen allclose all

Basic Examples (3)Basic Examples (3)

is a rational number:

In[1]:=
Click for copyable input
Out[1]=

A sum of rational numbers is a rational number:

In[1]:=
Click for copyable input
Out[1]=

Find rational solutions of an equation:

In[1]:=
Click for copyable input
Out[1]=
New in 4
New to Mathematica? Find your learning path »
Have a question? Ask support »