bookshelf/Bookshelf/Real/Rational.lean

15 lines
384 B
Plaintext
Raw Normal View History

import Bookshelf.Real.Basic
/--
Assert that a real number is irrational.
-/
def irrational (x : ) := x ∉ Set.range RatCast.ratCast
/--
Assert that a real number is rational.
Note this does *not* require the found rational to be in reduced form. Members
of `` expect this (by proving the numerator and denominator are co-prime).
-/
def rational (x : ) := ¬ irrational x