How can we represent $\mathbb{R \setminus Q}$ in lambda calculus and make it practical to derive further operations on this set?
Here is my attempt so far: (tl;dr: using infinite recursion to define $ e $ seems like the program would get stuck).
$$ pair = (\lambda\ a\ b\ s : s\ a\ b) $$ $$ first = (\lambda\ l\ r : l) $$ $$ second = (\lambda\ l\ r : r) $$ $$ rational = (\lambda\ n\ d : (pair\ n\ d))) $$
Where $ n \in \mathbb{Z} $ is the numerator and $ d \in \mathbb{N_1} $ the denominator.
An integer is constructed using a pair: $ (pair\ a\ b) $ meaning $ a - b $.
The following is a rational number:
$$ (rational\ (pair\ 3\ 0)\ 5) = 3/5 $$
In the above, $$ 0 = (\lambda\ f\ x: x) $$ $$ 3 = (\lambda\ f\ x: (f (f (f\ x)))) $$ $$ 5 = (\lambda\ f\ x: (f (f (f (f (f\ x)))))) $$
Now let's define the $ e $ function under the assumption that $ plus $, $ factorial $, and $ successor $ have been defined.
$$ e = (\lambda\ t: (plus\ (rational\ (pair\ 1\ 0)\ (factorial\ t))\ (e\ (successor\ t)))) $$ $$ \Rightarrow (e\ 0) = 2.718... $$
My problem is that $ (e\ 0) $ is an infinite recursion. Say we are comparing two irrational numbers. Comparing for inequality of two non-equal numbers can be computed lazily (eventually, a dissimilarity must be found). If the two numbers are equal, then both end up recurring infinitely.