-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathfunora.tex
627 lines (359 loc) · 83.7 KB
/
funora.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
\documentclass[12pt]{article}
\usepackage{personal}
\usepackage{realoracles}
\newtheorem{theorem}{Theorem}[section]
\newtheorem{lemma}{Lemma}[section]
\newtheorem{corollary}{Corollary}[section]
\newtheorem{proposition}{Proposition}[section]
\title{Elementary Analysis with Function Oracles}
\jtauthor
\date{December 19, 2023}
%\sloppy%\openup-.1\jot
\begin{document}\maketitle
\begin{abstract}
Real numbers can be viewed as oracles that say Yes to an interval which contains the real number and No otherwise. Other topological spaces can also benefit from this oracle point of view. Both were detailed elsewhere. Having obtained new spaces from oracles, a natural next step is a new definition of a function, called function oracles. These are oracles that give affirmation for rational rectangles whose walls contain the image of the base under the function it is modeling. These turn out to be equivalent to functions that are continuous everywhere except possibly on the rationals or, more generally, the points of the original space. This paper explores function oracles and some aspects applied to elementary analysis.
\end{abstract}
\tableofcontents
\section{Pointwise Oracles}
In previous work \cite{taylor23main}, we explored the notion of considering real numbers as objects which indicate whether the real number ought to be contained in a given, inclusive, rational interval or not; it is a Yes interval if it contains the number, a No interval if not. Since we are defining the real number, we have to abstract out a set of properties to use to determine whether such an object can faithfully represent what we want from a real number. Any object that satisfies the following properties is an oracle which can be taken to be a real number:
\begin{enumerate}
\item Consistency. Intervals that contain Yes intervals are Yes, those contained in No intervals are No.
\item Existence. There should be at least one Yes interval.
\item Closed. If a rational number is in every Yes interval, then the real number is that rational number.
\item Rooted. There is at most one rational number in every Yes interval.
\item Interval Separation. If we divide a Yes interval into two pieces, one interval is Yes, the other is No unless the real number happens to be the partitioning rational number in which case both intervals are Yes.
\end{enumerate}
From these properties, an ordered arithmetic of oracles can be developed. It can be shown that this space satisfies all the real number axioms including completeness. In many ways, the oracles can be shown to be the foundation which is underlying the usual different notions of real numbers. The idea of interval approximation of real numbers is central to their use. Oracles present this in a fashion with unique representatives and in conformance with how real numbers are actually used. It promotes a healthy appreciation for interval bounding of real numbers in a precise fashion.
The idea of an oracle naturally extends to metric spaces \cite{taylor23metric}. The f
\section{Function Oracles as Families of Narrowing Rational Rectangles}\label{sec:funora}
The oracles are equivalent to the axiomatic real numbers and we could, therefore, just do the usual story of pointwise defined functions being maps from oracles (reals) to oracles. But that not only discards the idea and usefulness of oracles, but it also gives up an opportunity to have the theory be based more in line with how we actually compute functions. When we compute $e^{\sqrt{2}}$, for example, we might use the Taylor polynomial for $e^x$ which is a partial approximation, but the input of $\sqrt{2}$ is also a partial approximation. While the easiest approach is to simply take an output number that hopefully represents something close enough, a more precise approach is to develop some notion of saying ``this interval maps into this other interval.'' This is what functional oracles will do. They allow one to make clear, precise statements about results that are inherently imprecise. As we have throughout, we do allow intervals to be rational singletons.
With a function oracle, there is a fundamental difference between rationals and irrationals in this setup. Indeed, we will eventually derive that the function oracles represent pointwise functions which are continuous at the irrationals in their domain, but possibly discontinuous at the rationals.
A natural structure to look at as providing a basis for functions is that of rational rectangles. The base will represent the valid inputs and the wall will represent the possible outputs. The family of rectangles will have the property that we can narrow the range of the outputs with a possible narrowing of the input range. A basic requirement will be that if an oracle $\alpha$ is in the domain of the function with supposed value $\beta$ at that point, then, given an $\alpha$-Yes interval $a:b$ and a $\beta$-Yes interval $c:d$, there is a Yes rectangle contained in $a:b \times c:d$ such that the base is $\alpha$-Yes and the wall is $\beta$-Yes.
We could imagine that the rectangle $a:b \times c:d$ just needs to be an $(\alpha, \beta)$-Yes rectangle for a given $\alpha$ and $\beta$. This would be essentially the way to recover the usual set of functions that we discuss in real analysis as we would have each collection of rectangles tied to a given pair. But we have in mind the desire that these Yes rectangles contain all the function values for the inputs contained in the base of the rectangle. This implies that over the base, the rectangle is a bounding rectangle for our function.
For rationals, we do allow singleton bases which enables them to be independent of the surrounding regions. For irrationals, we are effectively requiring them to be in line with their neighbors. The model to have in mind is the difference between discrete probability (probability mass function) and a continuous probability (probability density function). Just as we can mix these in probability, we can have that here. The functions that get defined by this should be continuous on the irrationals, but can be discontinuous on the rationals. Thomae's function is an example of this, as discussed below.
This is largely a sketch of the foundations for function oracles as a basis of analysis. We do establish the arithmetic of function oracles, including the exponential operator of oracles raised to an oracle power. After we explore continuity in the context of function oracles, we then also discuss composition which is strongly linked to continuity questions in this framework. The main continuity result is that function oracles are equivalent to pointwise functions continuous everywhere on its domain except possibly at the rational numbers. We also give a few examples of how common functions are modeled with function oracles. In the companion paper on generalizing oracles to other topological spaces, \cite{taylor23metric}, it generalizes oracle functions to that more general context.
\subsection{Definitions}
A \textbf{rectangle} $R$ with sides $a \lte b$ and $c \lte d$ will give the property to an ordered pair $(u, v)$ of being in the rectangle if $a \leq u \leq b$ and $c \leq v \leq d$. The \textbf{base} of the rectangle is $\base{R} = a:b$ and the \textbf{wall} of the rectangle is $\wall{R} = c:d$. We denote the rectangle by $a:b \times c:d$. Note that we will only consider rational rectangles, that is, those such that $a, b, c, d, u, v$ are all rational numbers.
A rectangle $M = a \lte b \times c \lte d$ is contained in another rectangle $N = A \lte B \times C \lte D$ if $A \leq a \leq b \leq B$ and $C \leq c \leq d \leq D$. They have the same base if $a=A$ and $b=B$ while they have the same wall if $c=C$ and $d=D$. The rectangle $M$ base-contains $N$ if $a \leq A \leq B \leq b$ and $M$ wall-contains $N$ if $c \leq C \leq D \leq d$.
The \textbf{intersection} of two rectangles $a \lte b \times c \lte d$ and $A \lte B \times C \lte D$ is the rectangle formed from $\max{a,A} \lte \min{b,B} \times \max{c, C} \lte \min{d, D}$; the intersection is empty if the inequality on either side is not satisfied in which case these are \textbf{disjoint} rectangles. The \textbf{container} of the two rectangles is the rectangle $\min{a,A} \lte \max{b,B} \times \min{c, C} \lte \max{d, D}$. The container always exists.
The rectangle $R$'s base contains $\alpha$ exactly when the base of $R$ is an $\alpha$-Yes interval. Similarly, $R$'s wall contains $\beta$ if the wall of $R$ is a $\beta$-Yes interval.
We will call a rectangle $R$ of the from $a:a\times b:b$ a \textbf{singleton rectangle} or even just a singleton. We do consider the singletons to be rectangles. If a rectangle has a singleton base of $R$, then we may refer to it as a \textbf{mass point}. If a rectangle has a wall that is a singleton, we may call it a \textbf{constant} rectangle.
A \textbf{function oracle} $f$ is a rule that, given any rectangle $R$, either says Yes or No and satisfies:
\begin{enumerate}
\item Elongating Consistency. If the wall of rectangle $M$ contains all of the walls of a collection of Yes rectangles $\mathcal{N}$ with the union of the bases of $\mathcal{N}$ being equal to the base of $M$, then $M$ is an $f$-Yes rectangle.
\item Narrowing Consistency. If the base of rectangle $M$ contains the base of rectangle $N$ with $N$ and $M$ sharing the same wall, then $N$ is an $f$-Yes rectangle if $M$ is.
\item Intersecting. If two $f$-Yes rectangles have intersecting bases, then the two rectangles have non-empty intersection and that intersection is an $f$-Yes rectangle.
\item Separating. Given a Yes rectangle $M$, an oracle $\alpha$ contained in the base of $M$, and two rational values $r$ and $s$ contained in the wall of $M$, then there exists a Yes rectangle contained in $M$, not containing at least one of those values in its wall with $\alpha$ contained in its base.
\item Closed. If a rational pair $(u,v)$ is contained in every $f$-Yes rectangle whose base contains $u$, then $u:u \times v:v$ is an $f$-Yes rectangle.
\end{enumerate}
Here are a few consequences:
\begin{enumerate}
\item Narrowing Elongating Consistency (NEC). If the wall of $M$ contains the wall of $N$ and the base of $N$ contains the base of $M$, then $M$ is an $f$-Yes rectangle if $N$ is an $f$-Yes Rectangle. This implies that if $M$ is $f$-No then $N$ is $f$-No. This property is established by looking at the intermediate rectangle $P = \base{M} \times \wall{N}$, which is a Yes rectangle by the Narrowing property applied to using $N$ being Yes to conclude $P$ is Yes. We can then use the Elongating property to go from $P$ being Yes to $M$ being Yes.
\item Given an interval $I$ in the base of the $f$-Yes rectangle $R$, there exists an $f$-Yes rectangle $S$ such that $I$ is the base of $S$. One such rectangle is $I \times \wall{R}$ which is $f$-Yes by Narrowing Consistency.
\item Similar to real oracles, Narrowing, Elongating, and Closed are included to ensure the maximal and unique nature of a function oracle. These properties are sometimes needed to be added in to what is otherwise a natural definition.
\item The Separating property focuses on separating the rational elements in the walls as rationals are what we have to work with. But it will also separate oracles. Given a Yes rectangle $M$, an oracle $\alpha$ in the base of $M$, and oracles $\beta$ and $\gamma$ in the wall of $M$, then there exists a Yes rectangle $N$ whose base contains $\alpha$ and that at least one of $\beta$ and $\gamma$ is not in the wall of $N$. We can see that by choosing two rationals between the oracles $\beta$ and $\gamma$. Apply the separating property to those two rationals. The resulting Yes rectangle $N$ cannot contain both $\beta$ and $\gamma$ without also containing both of the two rational values which the Separating property asserts it will not. Thus, it is sufficient to focus on separating rational values in establishing that something is a function oracle.
\end{enumerate}
To allow for expansive ranges in the elongation property and in order to support jump discontinuities, we do not require that every value in the wall is imagined to be a value of the function. This is a key reason why the separating property does not require one of the values to be in the Yes rectangle.
\subsubsection{Graphing}
We can graph function oracles in the following way. We assume that we are given a grid to graph on with the axes already chosen and coordinatized with rationals. By the narrowing property, we can assume that the bases of all function oracles fit within the horizontal side of a given grid box. As for the vertical, we fill in a grid box if it contains a portion of the Yes rectangle. Ideally, we would be able to shorten the function rectangle until it fits into one grid box, but if that is not practical, then this gives a representation of the remaining uncertainty. Filling up a grid box is using the elongating property. If the horizontal base is too short, we can consider the container of Yes rectangles whose bases will fill up the horizontal, adding more uncertainty vertically if need be. This will work best when the entire box which the grid sits in is itself a Yes rectangle implying the displayed horizontal axis is fully in the domain and that the graph of the function can be visibly seen within the box.
\subsection{Foundational rectangles}
In a similar fashion to our use of fonsis, it is convenient to have a setup for a basis for the function oracles. We define a set of rectangles to be \textbf{foundational} if the set of rectangles satisfies the following properties:
\begin{enumerate}
\item Intersecting. If two foundational rectangles have intersecting bases, then the two rectangles have non-empty intersection and, for a given $\alpha$ in the base intersection, there exists a foundational rectangle whose base is contained in the base intersection with $\alpha$ contained in the base as well such that wall is contained in both of the two rectangles.
\item Separating. Given a foundational rectangle $M$, an oracle $\alpha$ contained in the base of $M$, and two rational values $r$ and $s$ contained in the wall of $M$, then there exists a foundational rectangle contained in $M$, not containing at least one of those values in its wall with $\alpha$ contained in its base.
\item Weak Narrowing. Given a foundational rectangle $M$, an interval $I$ in the base of $M$, and an oracle $\alpha$ in that interval, then there exists a foundational rectangle $N$ contained in $M$ whose base both contains $\alpha$ and is contained within $I$.
\end{enumerate}
The set of Yes rectangles for a function oracle is a foundational set. Foundational sets, just like fonsis, often arise naturally. We need to complete them to become full functional oracles and the process to do so is similar to that of fonsis.
If we have a foundational set of rectangles, we can \textbf{restrict the set to the oracle $\alpha$} which means the collection of all foundational rectangles whose base contains $\alpha$. If $\mathcal{F}$ is the foundational set, then the restriction to $\alpha$ will be denoted as $\mathcal{F}_{\alpha}$. The set of walls from that set will be denoted as $\wall{\mathcal{F}_{\alpha}}$.
We start by establishing that the set of walls of foundational rectangles restricted to an oracle is a fonsi.
\begin{proposition}
Given a foundational set of rectangles $\mathcal{F}$ and a real oracle $\alpha$ in the base of at least one of the rectangles, then $\wall{\mathcal{F}_{\alpha}}$ is a fonsi.
\end{proposition}
\begin{proof}
We need to demonstrate the overlapping and notionally shrinking properties.
Let $M$ and $N$ be two arbitrary elements of $\mathcal{F}_{\alpha}$.
Overlapping: Let $I = \wall{M}$ and $J= \wall{N}$. Since both bases are $\alpha$-Yes intervals, the bases do intersect. By the Intersection property, they have a non-empty intersection and contain a foundational rectangle $P$. Let $K = \wall{P}$. $K$ is therefore contained in $I$ and $J$. Thus, $I$ and $J$ intersect. Since $I$ and $J$ represent arbitrary elements of $\wall{\mathcal{F}_{\alpha}}$, we have established the overlapping property.
Notionally Shrinking: Let rational $\varepsilon > 0$ be given. Let $h = |\wall{M}|$ be the height of the wall of $M$. If $h < \varepsilon$ then we are done. If not, find $k$ such that $(\frac{2}{3})^k < \frac{\varepsilon}{h}$. We construct a sequence of foundational rectangles as follows. Start with $M_0= M$. Assume $M_i$ is defined. Let $a_i$ and $b_i$ be the endpoints of the interval $\wall{M_i}$. If $a_i=b_i$, then the length is 0 and we are done. Assume they are not equal. Let $c_i =\frac{2a_i + b_i}{3}$ and $d_i = \frac{a_i +2b_i}{3}$. Using the Separating Property, we obtain a foundational rectangle $M_{i+1}$ which excludes at least one of $c_i$ or $d_i$, is contained in $M_i$, and whose base contains $\alpha$. Since each of the two points separates the interval into two pieces of a third and two-thirds length, we can conclude that the exclusion of one of them leads to $|\wall{M_{i+1}}| < \frac{2}{3} |\wall{M_i}|$. Each wall of $M_i$ is in the family as $M_i$ is in $\mathcal{F}_{\alpha}$. After $k$ steps, we will have that the wall of $M_k$ will have length less than $\varepsilon$ as $|\wall{M_k}| < \frac{2}{3}^k h < \varepsilon$.
Thus the set of walls of $\mathcal{F}_{\alpha}$ is a fonsi.
\end{proof}
We define the \textbf{domain} of a foundational set of rectangles $\mathcal{F}$ as the property that, for a given oracle $\alpha$, it is in the domain of $\mathcal{F}$ if there exists a rectangle in $\mathcal{F}$ whose base contains $\alpha$.
\begin{corollary}\label{cor:fshrink}
Given a foundational set of rectangles $\mathcal{F}$ and an $\varepsilon > 0$, then for any oracle $\alpha$ in the domain of $\mathcal{F}$ there exists a rectangle $M$ in $\mathcal{F}_{\alpha}$ such that $|\wall{M}| < \varepsilon$.
\end{corollary}
This follows immediately from the walls forming a fonsi and is what the notionally shrinking portion of that proof was establishing.
\begin{proposition}\label{pr:classfun}
Given a foundational set of rectangles $\mathcal{F}$ and an oracle $\alpha$ in the domain of $\mathcal{F}$, there exists a unique oracle $\beta$ such that the wall of every rectangle in $\mathcal{F}_{\alpha}$ is a $\beta$-Yes interval.
\end{proposition}
\begin{proof}
Given $\mathcal{F}$ and $\alpha$, the walls of $\mathcal{F}_{\alpha}$ form a fonsi. Therefore, there is a unique oracle $\beta$ associated with this fonsi such that the elements of the fonsi are $\beta$-Yes intervals.
\end{proof}
We can write $\mathcal{F}(\alpha) = \beta$ to denote this relation.
A \textbf{rooted} foundational set is one which satisfies the rooted property. Namely, if there is a $(u,v)$ pair in every foundational rectangle whose base includes $u$, then $u:u \times v:v$ is in the foundational set. Given a foundational set, there is a unique rooted foundational set that includes the original foundational set. This is obtained by including any singleton rectangles that are required. For a given $u$, there will be at most one such singleton included. As a practical matter, this could be a non-trivial operation to implement.
A \textbf{containerizable} collection of rectangles is a collection of rectangles contained in another rectangle $M$ such that the base of $M$ is the union of the bases while the wall of $M$ should contain all the walls of the collection. Note the union of the walls need not be an interval while the union of the bases do. Any rectangle whose base is the union of all the bases in the collection and whose wall contains all the walls of the collection is called a \textbf{container} of the collection.
\begin{proposition}\label{pr:foundation}
Given a foundational set of rectangles, there is a unique function oracle such that foundational rectangles are all Yes rectangles and the foundational set and function oracle have identical domains.
\end{proposition}
\begin{proof}
Given a foundational set $\mathcal{F}$, we first root it. Once we have rooted it, then we can define a function oracle by stipulating a Yes rectangle are the containers of any containerized collection of rectangles from the rooted foundational set. We will call such rectangles as built-up rectangles.
With the roots added in, any rational point $(u,v)$ which is contained in every foundational rectangle whose base includes $u$ will imply that $u:u \times I$ is a Yes rectangle where $I$ is an interval that contains $v$.
We establish existence by establishing the proof of each property. They generally follow directly from definitions.
\begin{itemize}
\item Elongating Consistency. This is satisfied by construction. It is by definition that such a rectangle $M$ as in the definition is a Yes rectangle if the collection $\mathcal{N}$ referenced in the property is a collection of foundation rectangles. If the collection contains built-up rectangles, they can eventually be broken up into foundational rectangles and then that establishes $M$ is a built-up rectangle itself and thus is a Yes rectangle. This collection process also includes the singletons of the roots and their extensions.
\item Narrowing Consistency. Given $M$ and $N$ with the same wall, $N$'s base contained in $M$, and $M$ a Yes rectangle, we need to argue that $N$ is a Yes rectangle. For every $\alpha$ contained in $N$'s base, there is a foundational rectangle $P$ that contains $\alpha$ and is contained in $M$ by definition of $M$ being a Yes rectangle. By the weak narrowing property, we can also find a foundational rectangle $Q$ whose base is contained in the base of $N$, contains $\alpha$, and is contained in $P$ implying it is contained in $M$. The collection of such $P$ is containerized as they are all contained in $M$. The rectangle that is formed from the bases of all such $Q$ and crossed with their walls will be contained in the wall of $M$ (so $N$ as well) and the base will be the base of $N$. That is, $N$ is a Yes rectangle.
\item Intersecting. Let $M$ and $N$ be two Yes rectangles whose bases intersect at $\alpha$. Then there exist foundational rectangles $P_{\alpha}$ and $Q_{\alpha}$ whose bases contain $\alpha$ and are contained in $M$ and $N$ respectively. By the Intersecting property, we have a single foundational rectangle $R_{\alpha}$ whose base contains $\alpha$ and is included in $P_{\alpha}$ and $Q_{\alpha}$ implying containment in $M$ and $N$. The collection of $R_{\alpha}$ for each $\alpha$ in the base intersection is containerized and is a collection of foundational rectangles. Thus, any container of them is a Yes rectangle and will be in the intersection of the two rectangles and having the same base. As any such container works, we can take one which is the intersection of the walls of $M$ and $N$; this intersection does contain the walls of all of the $R_{\alpha}$.
\item Separating. Given a Yes rectangle $M$, an oracle $\alpha$, and rational values $r$ and $s$, we need to find a Yes rectangle $N$ whose base contains $\alpha$ and whose wall excludes at least one of $r$ and $s$. By the definition of $M$, there exists a foundational rectangle $N$ contained in it whose base contains $\alpha$. If $r$ or $s$ is not in the wall of $N$, then we are done. If they are both in it, then we use Separating as applied to $N$ as part of the definition of foundational rectangles. That separating foundational rectangle is a Yes rectangle and will satisfy the criteria for the functional oracle Separating property.
\item Closed. Any rational point $(u,v)$ that is contained in all of the Yes rectangles whose base contains $u$ would appear in all of the foundational rectangles whose base contains $u$. Thus, by definition, $u:u\times v:v$ is a Yes rectangle.
\end{itemize}
For uniqueness, we need to argue that any other functional oracle that has all of the foundational rectangles being Yes rectangles and has the same domain. Given a rectangle $M$, we need to argue that the the alternate functional oracle ($A$) and the collective function oracle ($C$), will agree on $M$. If $M$ contains an oracle $\alpha$ in its base that is not in any of the foundational set rectangle's base, then $M$ is a No rectangle for $C$ by definition and a No rectangle for $A$ by hypothesis of having the same domain. So we will only consider rectangles whose bases are in the domain of the foundational set.
Assume that $M$ is a $C$-Yes rectangle. Then we need to argue that it is an $A$-Yes rectangle. As we did with the Elongating Consistency property, we can view any such $M$ as a collection of foundational rectangles. By the Elongating Consistency property of $A$ and that foundational rectangles are Yes for it, we have that $M$ must be Yes as well.
Now let's assume $M$ is an $A$-Yes rectangle. We need to show it is a collection of the rooted foundational rectangles. In that case, they would then be a $C$-Yes rectangle. For any $\alpha$ in the base of $M$, there is a foundational rectangle $N_{\alpha}$ that contains $\alpha$ by the domain assumption. By the weak narrowing property, we can assume that the foundational rectangle is contained in the base of $M$ and contains $\alpha$.
To get the wall of $N_{\alpha}$ to be contained in $M$, we know that if we restrict the foundational set to $\alpha$ and look at the walls, then we get a fonsi. If the oracle of that fonsi is rooted, then, since we included the roots, we have that we can take
By Separating, we can argue that we can take the foundational rectangle to have as small a wall as we like.
CONSIDER the functional oracle y = 1. foundational set is just rectangles whose walls lower endpoint is 1. For the functional oracle, consider a rectangle whose upper wall endpoint is 1. This will not be a build-up of the foundational set but it is a build-up of the limit of their intersection.
??????????? the foundational rectangle need be contained in the wall of $M$. Also the closure bits.
As this is true for every oracle in the base of $M$, we can see that $M$ is a collection of such rectangles.
\end{proof}
\begin{corollary}
If two foundational sets with equal domain have the property that their union is a foundational set, then they are associated with the same functional oracle.
\end{corollary}
\begin{proof}
The union will have its unique functional oracle containing the foundational rectangles of both foundational sets and thus is the unique functional oracle established above.
\end{proof}
\subsubsection{Pointwise Defined Functions}
We now look at this giving rise to a pointwise function, namely, the ability to write $f(\alpha) = \beta$. Essentially, the sides of the rectangle are the intervals defining these oracles.
\begin{proposition}
If an oracle $\alpha$ has a Yes-interval which is the base of a Yes rectangle for a function oracle $f$, then $f(\alpha)$ is defined as the unique oracle $\beta$ associated with the fonsi consisting of the walls of $f$-Yes rectangles whose base is an $\alpha$-Yes interval.
\end{proposition}
\begin{proof}
We need to show that the set of walls associated with $\alpha$ and $f$ is a fonsi, meaning we need to show they overlap and they can be taken as small as we please.
Overlapping: Let $I$ and $J$ be walls of $f$-Yes rectangles $M$ and $N$, respectively, such that the bases are $\alpha$-Yes intervals. Since both bases are $\alpha$-Yes intervals, the bases intersect. By the Intersection property, they have a non-empty intersection as an $f$-Yes rectangle. The wall of that $f$-Yes rectangle is therefore not empty and in both $I$ and $J$. As $I$ and $J$ were arbitrary elements of the proposed fonsi, we have that the overlapping property is satisfied. We also note that the intersection is a part of the proposed fonsi which supports it being almost maximal already.
Notionally Shrinking: Let rational $\varepsilon > 0$ be given. Let $M$ be an $f$-Yes rectangle whose base is an $\alpha$-Yes interval; this exists by assumption. Let $L = |\wall{M}|$ be the length of the wall of $M$. If $L < \varepsilon$ then we are done. If not, find $k$ such that $(\frac{2}{3})^k < \frac{\varepsilon}{L}$. We construct a sequence of rectangles as follows. Start with $M_0= M$. Assume $M_i$ is defined and we will next define $M_{i+1}$ as follows. Let $a_i$ and $b_i$ be the endpoints of the interval $\wall{M_i}$. If $a_i=b_i$, then the length is 0 and we are done. Assume they are not equal. Let $c_i =\frac{2a_i + b_i}{3}$ and $d_i = \frac{a_i +2b_i}{3}$. Using the Separating Property, we obtain a rectangle $M_{i+1}$ which excludes at least one of $c_i$ or $d_i$, is contained in $M_i$, and whose base contains $\alpha$. Since each of the two points separates the interval into two pieces of a third and two-thirds length, we can conclude that the exclusion of one of them leads to $|\wall{M_{i+1}}| < \frac{2}{3} |\wall{M_i}|$. Each wall of $M_i$ is in the family. After $k$ steps, we will have that the wall $\wall{M_k}$ will have length less than $\frac{2}{3}^k L < \varepsilon $.
Since this family of intervals satisfies the overlapping and notionally shrinking properties, it is a fonsi and therefore defines a unique oracle.
\end{proof}
Note that by the Elongating Consistency property and that the intersections of the walls are also walls as we showed, the fonsi is almost a maximal fonsi. The only missing intervals are possibly those which have an endpoint that is the root of the oracle. For neighborly oracles, this will not be an issue.
An example to demonstrate this concern is modelling the function $f(x) = \frac{3}{\sqrt{2}}x$ whose core rectangles can be of the form $a\lte b \times \frac{3a}{d} \lte \frac{3b}{c}$ where $c\lt d$ is a $\sqrt{2}$-Yes interval. Since $f(\sqrt{2}) = 3$, that is a singleton, but there will be no rectangle whose wall is just $3$ because that would required $a=d$ and $b=c$ but $c < d$ while we assumed in the setup that $a \leq b$.
We say that an oracle $\alpha$ is in the domain of the function oracle if there is at least one $R$-Yes rectangle $M$ whose base is an $\alpha$-Yes interval. By the proposition above, being in the domain does imply that the function will have a value at $\alpha$ in the pointwise sense.
By the above proposition, we also have that if there exists a rational tuple $(u,v)$ contained in every $f$-Yes rectangle whose base contains $u$, then the value of the function at $u$ is $v$.
\begin{corollary}\label{cor:wallorac}
Given a function oracle $f$ and an oracle $\alpha$ in its domain, then given a neighborly $\beta=f(\alpha)$-Yes interval $a\lt b$ that strictly contains a $\beta$-Yes interval $c \lte d$, then we can find an $f$-Yes rectangle whose base contains $\alpha$ and whose wall contains $a:b$.
\end{corollary}
\begin{proof}
Let $f$, $\alpha$, $a<b$, and $c\lte d$ be given as in the hypothesis. In particular, we should have $a< c \leq d < b$. Since $\alpha$ is in the domain of $f$, there exists an $f$-Yes rectangle whose base contains $\alpha$. By the theorem above, every such rectangle has that its wall is a $\beta$-Yes interval.
Because $c:d$ is a $\beta$-Yes interval, any $\beta$-Yes interval that includes $a$ must include $c$ and similarly for $b$'s presence implying $d$'s presence. This is because all $\beta$-Yes intervals intersect and $c$, respectively $d$, is the closest rational to $a$, respectively $b$, in the interval $c:d$.
We will use the Separating Property twice. We start with an $f$-Yes rectangle $M$ that includes $\alpha$. The wall of $M$ is a $\beta$-Yes interval. If it excludes $a$, then we call $M$ as $N$. Otherwise, we use Separation to find an $f$-Yes rectangle $N$, contained in $M$, whose base contains $\alpha$ and that does not include at least one of $a$ or $c$. Since $\alpha$ is in the base, $N$'s wall is a $\beta$-Yes interval which means that if $a$ was present, then $c$ would be. Thus, $a$ cannot be present. $c$ may or may not be.
If $N$ excludes $b$, then we call $N$ to be $P$. Otherwise, we use Separation to find an $f$-Yes rectangle $P$, contained in $N$, whose base contains $\alpha$ and that does not include at least one of $b$ or $d$. Since $\alpha$ is in the base, $P$'s wall is a $\beta$-Yes interval which means that if $b$ was present, then $d$ would be. Thus, $b$ cannot be present. $d$ may or may not be.
Since $P$ is contained in $N$, we have that $P$'s wall does not contain $a$. Since $P$'s wall is a $\beta$-Yes interval that excludes both $a$ and $b$, we must have that it is contained in $a:b$. By the Elongating Property, we then have that $\base{P} \times a:b$ is a $f$-Yes rectangle.
\end{proof}
It is useful to specifically extract the notionally shrinking portion:
\begin{corollary}
Given a function oracle $f$, an oracle $\alpha$ in its domain, and an $\varepsilon > 0$, then we can find an $f$-Yes rectangle whose base is an $\alpha$-Yes interval such that its wall has length less than $\varepsilon$.
\end{corollary}
Oracle functions, as we shall see, are the functions that are constrained by their values on the rational numbers. In particular, we need what happens on the rationals to be, in a certain sense, close to what is happening on the irrationals.
In what follows, we will establish that elementary functions can be modeled as function oracles. But we start with exploring Thomae's function and related functions.
\subsection{Thomae's Function}
First, let us look at a couple of functions with jumps that come to the opposite conclusions.
Define the function oracle $f$ with the following rules for rectangles $R$:
\begin{itemize}
\item If 2 is not in the base of $R$, then it is an $f$-Yes rectangle if and only if the wall contains 0.
\item If 2 is in the base of $R$ and it is not a singleton, then it is an $f$-Yes rectangle if and only if the wall contains both 0 and 1.
\item If it is a singleton whose base is $2:2$, then it is $f$-Yes if and only if the wall contains 1.
\end{itemize}
This leads to the pointwise function which is everywhere 0 except at 2 for which its value is 1 at that point.
A very similarly defined Yes/No rule on rectangles can be obtained by replacing 2 with $\pi$. This does not work as we cannot have the $\pi$ singleton. Without the singleton, we fail to satisfy the separating property as there does not exist a Yes rectangle whose base contains $\pi$ but whose wall separates 1 and 0.
This exemplifies that the rationals have more privileges than the irrationals, corresponding to the fact that we can specifically address any given rational number while we cannot do so with irrationals. The behavior of irrationals can only be specified in a general location and thus we must have continuity there for this to make actual sense.
The characteristic function of the rationals cannot be modeled by a function oracle, again by the lack of a way to separate the values of 0 and 1.
We can, however, model Thomae's function which is the classic example of a function continuous on the irrationals, but not the rationals.
Define the function oracle $T$ as giving a Yes result on neighborly rectangles $p/q : r/s \times c\lt d$ exactly when $c \leq 0 \lt 1/n \leq d$ is satisfied where $n$ is the smallest denominator for all rationals in $p/q \lt r/s$. The number $n$ is well-defined since we know it will be bounded above by $q$ and $s$. We should also say we ignore $0$ for the rational denominators. For singletons, if the base value is $p/q$ in reduced form, then it is a Yes rectangle exactly when it contains $1/q$. If the base value is $0$, then it must include $0$ in the wall.
Thanks to the singletons, this does satisfy the Separating property. The other properties follow quickly.
It should also be easy to see that this is Thomae's function. At a rational $\frac{p}{q}$, we have $1/q$ as common to all the rectangles while for any irrational, $0$ is common for all of them.
It is also worthwhile to think about graphing this function. In the customary presentation, it would be a bit of quandary. Our graphing tools technically only work with rational numbers. So any graph of the rational points would never have 0 in the range. From a probabilistic point of view, however, the rationals are a set of measure zero. This implies that if we were to randomly sample the interval, then the function should be identically zero.
Our approach suggests graphing rectangles. As we narrow the base, we end up with more varied rectangles of various heights. If we were to narrow in on an irrational number, say using the mediant process, then we progressively get past the smaller denominators and the bar heights do go to zero. For a rational, we can use a singleton to get its precise value.
Notice that for the characteristic function of the rationals, no amount of zooming changes the rectangles. The graph is simply a rectangle whose wall must contain the interval $0:1$, regardless of the base.
I take it to be a merit of this approach that it brings this out. These rectangles are also guarantees that the values will be in the rectangle. This means that if we want to know if a function value is in a given interval, then we can answer with confidence whether it is or not if the rectangle's wall contains the interval or is disjoint from it, respectively.
\subsection{Monotonic Functions}
For any monotonic rational function, $Q$, such as $x^3$, the rectangle approach works quite well. The minimal rectangle for a given interval $a \lt b$ would be $a:b \times Q(a):Q(b)$. The intersection of two such minimal rectangles, say with bases satisfying $A \lt a \lt B \lt b$ leads to $a \lt B \times Q(a):Q(B) $. We add in the appropriate rectangles containing these minimal rectangles for the consistency properties. The intersecting and separating properties can be handled using the monotonic properties.
We also need to consider monotonic functions whose values on rationals may not be rational. Examples include $\pi x$ and $\sqrt{x}$. For both of these, setting $x=2$ leads to non-rational oracles, specifically, $2 \pi$ and $\sqrt{2}$. We thus need to expand the minimal set of rectangles to be those whose $y$-side has that extra bit of oracle interval room.
Specifically, given a monotonically increasing function $F$ defined on the rationals whose outputs are possibly oracles, a rectangle is a Yes rectangle if it is of the form $a \lte b \times c\lte d$ where $c \lte d$ is an interval that is both an $F(a)$ and an $F(b)$ Yes interval. We also require that all rationals in $a:b$ have defined values.
Monotonically decreasing functions are handled the same way, but with a reversal of the upper and lower limits. Indeed, we can write it in an agnostic way by using $a:b \times c:d$ with $c:d$ being both a Yes interval for both $F(a)$ and $F(b)$. Monotonicity tells us that all the values of $F$ on the interval $a:b$ should be between $F(a)$ and $F(b)$ implying $c:d$ includes them all as a wall should.
This gives us all of the $x^r$ functions for rational $r$, quite explicitly. We can extend this to all $x^{\alpha}$ for oracles $\alpha$ by using intervals for $\alpha$ and then applying the upper and lower limits.
We can also do exponential functions of the form $\alpha^{x}$, by considering intervals for $\alpha$ and combining them with intervals of $x$. For example, if we are considering $e^{\pi}$, then one interval of interest would be taking $2.71:2.72$ and $3.14:3.15$ and forming the rectangle whose base is $3.14:3.15$ while the wall is $2.71^{3.14}:2.72^{3.15}$. As we consider all such intervals containing $e$ and $\pi$, the walls will form the intervals of the oracle of $e^{\pi}$.
The final function to consider in this section is that of logarithms. By considering the compounding interest formula, $(1+ \frac{x}{n})^n \to e^x$, we can invert this to obtain $n (x^{1/n} - 1) \to \ln(x)$. While this is a slow convergence, it does suffice for a definition. For a fixed $n$, the function is monotonically increasing, just as the logarithm is. For fixed $x$, the sequence of values is monotonically decreasing to $\ln(x)$. Since they are all above the logarithm, we need a lower bound. One candidate is $n (x^{1/n} - 1) - \frac{x}{n} $ which does suffice but is not great as for large $x$, it becomes quite a poor lower bound.\footnote{An alternative bounding strategy can be found in Appendix \ref{app:e}.} It is below the natural logarithm of x for all $x > 0.41$. Since we can define the property $\ln(x^{-1}) = - \ln(x)$, we can focus on constructing the values of the logarithm for $x\geq 1$. We can therefore take bounding boxes using the lower bound and upper bound functions appropriately, with a distinct preference for the upper bound as an approximation.
\subsection{Function Oracles from Narrowing Operators}
Many functions are not, of course, monotonic. We want to expand the realm of function combinations to include all rational functions of $x$ as well as various arithmetic combinations of functions. We can do this by using the rational interval operators that have the narrowing property. See \cite{taylor23main} for a refresher.
Let $\mathcal{O}$ be a rational interval operator with the narrowing property and let $n$ be the input tuple size. We will denote the associated oracle operator as $\bar{\mathcal{O}}$. Then given an $n$-tuple of function oracles, $\vec{f}$, we can define a new function oracle $g$ by applying $\mathcal{O}$ to the walls of the Yes-rectangles of the components, all with the same base, to create a new rectangle whose wall is the output of $\mathcal{O}$.
We define the notation $\wall{\vec{R}}$ to represent the $n$-tuple of walls of the components of the $n$-tuple of rectangles $\vec{R}$. Namely, the $i$-th component is $\wall{R_i}$.
Given a base $a:b$, we say that the interval $c:d$ is $a:b$ $\mathcal{O}$-compatible with $\vec{f}$ if there exists $f_i$-Yes rectangles $R_i$ whose union of bases is $a:b$ and whose walls come together to form an interval $\mathcal{O}(\wall{\vec{R}}) = u:v$ such that $u:v$ is contained in $c:d$. The Yes rectangles of $g$ are precisely rectangles of the form $a:b \times c:d$ where $c:d$ is $a:b$ $\mathcal{O}$-compatible with $\vec{f}$.
We will prove that this is a function oracle. We will also prove that this is the same as the composition: $g(\alpha) = \bar{\mathcal{O}}(\vec{f}(\alpha))$ for all oracles $\alpha$ in the common domains of the components of $\vec{f}$.
Let us check the function oracle properties for $g$:
\begin{enumerate}
\item Elongating. This is immediate because the containing rectangle will still contain the output image interval which is the $u:v$ interval above.
\item Narrowing. This uses the existence of the narrowing property for all the $f_i$. Since we can narrow their bases to what ever interval we like without changing their walls, we will have the same wall for our narrowed yes rectangle.
\item Intersecting. Let $M$ and $N$ be two $g$-Yes rectangles that have a non-empty intersection, say $a:b$. Because $M$ and $N$ are $g$-Yes, there exist $f_i$-Yes rectangles $M_i$ and $N_i$ such that $\mathcal{O}(\wall{\vec{M}}) \subseteq \wall{M}$ and $\mathcal{O}(\wall{\vec{N}}) = N$ where the bases of $M_i$ are the same as the base of $M$ and the bases of $N_i$ are the same as the base of $N$. This means that their bases intersect and thus there is a common $f_i$-Yes rectangle that is contained in $M_i$ and $N_i$; let us call it $R_i$. Then define $R$ to be the rectangle whose base is $a:b$ and whose wall is $\mathcal{O}(\wall{\vec{R}})$. This is a $g$-Yes rectangle by definition. Its base is included in $M$ and $N$ as is its wall. Thus this is in the intersection of $M$ and $N$. The intersection is therefore an $f$-Yes rectangle by Elongation.
\item Separating. Let $\alpha$ be an oracle in the base of the $g$-Yes rectangle $M$ and let $r$ and $s$ be two rational numbers in the wall of $M$. We need to show that there exists a $g$-Yes rectangle $N$ that does not contain at least one of those numbers.
Because the $f_i$ are function oracles, we have oracles $\beta_i = f_i(\alpha)$. We can use the oracle operator to define the output oracle $\beta = \bar{\mathcal{O}}(\vec{\beta})$.
Let $L = |r-s|$. Choose $N$ such that $L > \frac{1}{N}$. If we can find a $g$-Yes rectangle whose base contains $\alpha$ such that the wall of the rectangle is less than $\frac{1}{N}$, then we are done as it will not be able to include both $r$ and $s$ in it.
By the definition of the narrowing property, there exist neighborly intervals $J_i$ that are $\beta_i$-Yes intervals and such that $\mathcal{O}(\vec{J})$ is a $\beta$-Yes interval and is less than $\frac{1}{N}$.
By Corollary \ref{cor:wallorac}, for each $i$, there exists a $f_i$-Yes rectangle, say $R_i$, whose base contains $\alpha$ and whose wall is $J_i$. This is because the $J_i$ have been chosen to strictly contain another $\beta_i$-Yes interval which is part of the assumption of the narrowing property. By design, $|\mathcal{O}(\wall{\vec{R_i}})| < \frac{1}{N}$.
Because $M$ is a $g$-Yes rectangle, there are $M_i$ $f_i$-Yes rectangles, with the same base as $M$ such that $\mathcal{O}(\wall{\vec{M}}) \subseteq \wall{M}$.
Since all the bases contain $\alpha$, their bases all intersect. By the intersecting property, $R_i$ and $M_i$ intersect in a $f$-Yes rectangle. We can extract an $n$-tuple $\vec{P}$ of $\vec{f}$-Yes rectangles being those intersections.
As all the bases contain $\alpha$, we can narrow them down to a common base, say $I$. As $\mathcal{O}$ is a narrowing operator, the image $K = \mathcal{O}(\wall{\vec{P}})$ will also be in the wall of $M$ while also having a length less than $\frac{1}{N}$.
The $g$-Yes rectangle is therefore $I \times K$ and will separate the given points.
\item Closed. If there is a rational point included in all the Yes rectangles, say $(p,q)$, then $\mathcal{O}(\vec{f}(p:p))$ must be equal to the singleton $q:q$. Thus, the rectangle $p:p \times q:q$ is a Yes rectangle.
\end{enumerate}
As for establishing $g(\alpha) = \bar{\mathcal{O}}(\vec{f}(\alpha))$, the proof of the Separating property establishes this as we showed that every $\alpha$-based $g$-Yes rectangle contains within its wall a $\bar{\mathcal{O}}(\vec{f}(\alpha))$-Yes interval and hence this is the fonsi of $g(\alpha)$.
All of the arithmetic operators can now be applied to combine function oracles in the customary ways.
We can also directly compose them into pointwise continuous functions. Note that our input intervals are always inclusive of the endpoints. We can also apply functions continuous on their domain, but whose domain is not the whole real line. The requirement is that every $g$-Yes rectangle contains a $g$-Yes rectangle whose wall does not contain the points of discontinuity. For example, we can have $1/x$ as a function oracle by taking the modified function oracle of $x$ where the modification is to remove all rectangles whose base contains 0.
As a questionable example, we can also apply this to the tangent function as it is continuous everywhere on its domain. When we consider the function rectangles, we simply need to ensure that the intervals do not include odd multiples of $\frac{\pi}{2}$. The questionable part of this is that we would need to have a reliably defined tangent function, but we put it here to illustrate that discontinuous functions at irrationals are not a problem if the function oracles are not defined at that irrational.
\subsection{Exponentials}
Because taking the root of a number is not representable with a rational operator, the above framework does not apply. What we want is to make the notion of $\alpha^{\beta}$ be explicitly defined. This is not inherently difficult, but we need to expand the notion of function oracle a little more.
An $n \closeto m$ function oracle is a rule that assigns Yes or No to rectangles whose base are $n$-tuples of rational intervals and whose walls are $m$-tuple of rational intervals. A point $(\vec{x}, \vec{y})$ is in the rectangle if each respective component is in that component's interval, i.e., $a_i \leq x_i \leq b_i$ and $c_j \leq y_j \leq d_j$ for all $i$ and $j$ where $a_i \lte b_i$ is the $i$-th component interval in the input and $c_j \lte d_j$ is the $j$-th component interval in the output. Containers and intersection of such rectangles generalize as one would expect, namely, we operate the containment and intersection component-wise.
Singleton intervals can be the components and a singleton rectangle is one in which each component of both the inputs and outputs are singleton intervals.
The properties that these generalized function oracles $F$ must satisfy are essentially the same:
\begin{enumerate}
\item Elongating Consistency. If each component of the wall of $M$ contains the respective component of the walls of the collection of Yes rectangles $\mathcal{N}$ with the union of the components of the bases of $\mathcal{N}$ being the same as the component bases of $M$, then $M$ is an $F$-Yes rectangle.
\item Narrowing Consistency. If each component of the base of $M$ contains the respective component of the base of rectangle $N$ with $N$ and $M$ sharing the same wall, then $N$ is an $F$-Yes rectangle if $M$ is.
\item Intersecting. If two $F$-Yes rectangles have each of the components in their bases respectively intersecting, then the two rectangles have non-empty intersection and that intersection is an $F$-Yes rectangle.
\item Separating. Given an $F$-Yes rectangle $M$, an $n$-tuple oracle $\vec{\alpha}$ contained in the base of $M$, and two output $m$-tuples $r$ and $s$ contained in the wall of $M$, then there exists an $F$-Yes rectangle not containing at least one of those values and whose base contains $\vec{\alpha}$.
\item Closed. If a rational $n\closeto m$-tuple $(\vec{u},\vec{v})$ is contained in every $F$-Yes rectangle that contains $\vec{u}$ in its base, then the singleton rectangle $\vec{u}:\vec{u} \times \vec{v}:\vec{v}$ is an $F$-Yes rectangle.
\end{enumerate}
We can repeat the various arguments above, but we want to use this machinery just to establish that the exponential operator is a $2\closeto 1$ function oracle. We define it as follows. The exponential oracle operator says Yes to the rectangle $(a\lte b \times \frac{p}{q} \lte \frac{r}{q}) \times c \lte d$ if $c\lte d$ contains an interval of the following form: $A^{ps} : B^{rs}$ where $A$ satisfies $A^{qs} \leq a$ and $B^{qs} \geq b$ for some positive integer $s$. That is, $A$ is a lower bound to an $a^{\frac{1}{qs}}$-Yes interval while $B$ is an upper bound to a $b^{\frac{1}{qs}}$-Yes interval. Given a rational interval as the second input, we can always scale the fractions to have the same denominator.
To establish this is a function oracle, we need to establish the properties above. Elongating follows because of the containing wall of $M$ will contain the intervals that the walls of $\mathcal{N}$ contains. For Narrowing, consider $a \lte c \lte d \lte b$ and $\frac{p}{q} \lte \frac{m}{s} \lte \frac{n}{s} \lte \frac{r}{q}$ where $a\lte b \times \frac{p}{q} \lte \frac{r}{q}$ is the base of $M$ while $c \lte d \times \frac{m}{s} \lte \frac{n}{s}$ is the base of $N$.
Let $A$ and $B$ be the rationals that make $M$ into a $F$-Yes rectangle. Let $t$ be such that $qt = s$, which we can do by scaling $s$ before taking the final form. We essentially want to just work in common denominators, but since $A$ and $B$ are defined in terms of a $q$ before the appearance of a narrowed interval, we should be explicit about that scaling.
Due to exponentiation preserving ordering relative to bases, conceptually there is no difficulty in the narrowing to working out. But the details do require a little working out. Roughly, we want to argue that we can use $A^{\frac{1}{t}}$ as a new $A$. Raising it to the right powers will still maintain what we want. One issue is that the $t$-th root is unlikely to be a rational. Because ordering is preserved by exponentiating and rooting, we have that the oracles $A^{\frac{1}{t}} \leq a^{\frac{1}{qt}}$ have a rational in between them, say $u$. This $u$ will satisfy $A < u$ and $u^{qt}< a$. We then will have $u^{pt} \leq a^p \leq b^r \leq B^r$. Similarly, we have a $v$ such that $b \leq v^{qt} \leq B^q $ and $b^r \leq v^{rt}$. Because of the narrowing, we have $pt \leq m \leq n \leq rt$. Thus, $u^{pt} \leq u^{m} \leq v^{m} \leq v^{n} \leq v^{rt}$. We also have that $u^s = u^{qt} \leq a \leq c$ and $v^= v^{qt} \geq b \geq d$. So we have a required interval that is included in the other. We can thus take a longer wall to satisfy the property if need be.
The Separating property uses this same argument. Let $r$, $s$, $M$, and $\vec{\alpha}= (\alpha, \beta)$ be given as in the statement of the property. The narrowing above can be made arbitrarily small. So given the above quantities, we can compute the length $L = |r-s|$ to be smaller than in order to exclude and then we can choose intervals for $\alpha$ and $\beta$ appropriately to ensure that narrowed in distance is satisfied within $M$.
As for intersecting bases, we can take the narrowed examples and construct a common wall contained in both. The Closed Property follows by arguing that if $\langle a, \frac{p}{q}\rangle, c)$ is included in every Yes rectangle, then $a^p = c^q$. If this is not true, let's say $a^p < c^q$, then there exists a $b$ such that $a^p < b^p < c^q$ and thus $a:b \times \frac{p}{q}:\frac{p}{q}$ does not include $c$.
We have sketched how the exponential operator, $\alpha^\beta$, is a $2\closeto 1$ function oracle. This completes the standard arithmetic operations we typically use with elementary functions. This also highlights how we can expand our usage of function oracles to arbitrary dimensional mappings.
\subsection{Rational Uniform Continuity}
Another way of defining function oracles is to have a function that is defined on rational numbers which satisfies a local uniform continuity condition. The simplest case is where this is a function from rationals to rationals, but this can also work with rationals to oracles. When we have uniform continuity, we can easily see what the values ought to be in the rational numbers.
....
This can also extend to uniform differentiability which also has many useful benefits, such as described in cite bridges.
Lipschitz conditions, monotonic functions, inverse function theorem.
Lipschitz below is a minimal Yes rectangle relative size (ratio of length to width) while from above is confirming that there does exist a rectangle of that relative size.
Derivative is the idea of saying the rectangle relative size is converging on it. So rectangles can be used for areas, but they are also the constraints that derivatives are talking about. No idea if this leads to something useful.
\section{The Calculus of Function Oracles}
We now investigate various properties of function oracles and how they compare to standard calculus topics.
\subsection{Almost Everywhere Continuous}
Function oracles are almost everywhere continuous on the domain. In particular, the only places where they can be defined and discontinuous are at the rationals. This is what we shall establish using Corollary \ref{cor:fshrink}
Note that in the notionally shrinking argument it is quite possible to have a rectangle whose base is a singleton. This is how Thomae's function obeys the corollary.
We will call an oracle $\alpha$ in the domain of the function oracle \textbf{mass-free} if we can find Yes rectangles containing $\alpha$ whose base's length is greater than 0 and whose wall is as small as please. That is, if we are given $\varepsilon > 0$, then there exists a Yes rectangle $M$ such that $|\base{M}| > 0$, $\alpha \in \base{M}$, and $|\wall{M}| < \varepsilon$.
A function oracle is mass-free if it is mass-free across its domain.
\begin{proposition}
Let $\alpha$ be in the domain of the function oracle $f$ and mass-free. Then $f$ is continuous at $\alpha$.
\end{proposition}
\begin{proof}
We need to establish that given an $\varepsilon > 0$, we can find a $\delta > 0$ such that $|f(x) - f(\alpha)| < \varepsilon$ whenever $0 < |x - \alpha| < \delta$. This is essentially a restatement of the mass-free definition where $\delta$ is taken to be $|\base{M}|$, perhaps shrunken to be centered on $\alpha$.
\end{proof}
We should note that all neighborly $\alpha$ (irrationals) in the domain of $f$ are mass-free since Corollary \ref{cor:fshrink} applies to give us our $M$ and we note that the base of $M$ cannot be a singleton since it contains $\alpha$ which is neighborly and cannot be contained in a singleton.
We have established:
\begin{theorem}
Function oracles are continuous at all irrational values on their domains and at mass-free rational points.
\end{theorem}
\begin{corollary}
If a function oracle is mass-free, then it is continuous on its domain.
\end{corollary}
\begin{corollary}
Given an $f$-Yes rectangle $M$, $f$ is Riemann integrable over the base of $M$.
\end{corollary}
This follows as all almost-everywhere continuous functions are Riemann-integrable over bounded intervals with bounded functions. We have a further discussion on integrals in Section \ref{sec:int}.
We also have that bounded functions continuous everywhere except at the rationals can be modelled by function oracles. For a given $f$, we say that the triple $(\alpha, \delta, \varepsilon)$ satisfies the continuity condition if $\alpha$ is in the domain of $f$, $\delta > 0$, $\varepsilon > 0$, and we have that for any $x$ that satisfies $|\alpha - x| \leq \delta$, we have $|f(\alpha) - f(x) | < \varepsilon$. We include equality for the base as the endpoints of intervals are included in the rectangle definitions.
This is slightly questionable in that we are now adopting the standard analytical framework and its results to take the pointwise defined functions to convert into function oracles, but it is a valuable exercise.
\begin{proposition}
If a pointwise defined bounded function $f$ is continuous everywhere on its domain except possibly at that rationals, then there exists a unique function oracle $F$ such that $F(\alpha) = f(\alpha)$ for all $\alpha$ in the domain of $f$.
\end{proposition}
\begin{proof}
For a given $(\alpha, \delta, \varepsilon)$ triple satisfying the continuity condition, we define the corresponding continuity rectangle as $\alpha-\delta : \alpha \delta \times f(\alpha)-\varepsilon: f(\alpha)+\varepsilon$. We also define rationally-based rectangles for rationals $q$ in the domain of the function as $q:q \times c:d$ where $c:d$ is any $f(q)$-Yes interval. We claim that this is a foundational set of rectangles.
We have to check three properties:
\begin{itemize}
\item Intersecting.
\item Separating.
\item Weak Narrowing. Given the rectangle $M$ in the foundational set, the interval $I$ in the base of $M$, and the oracle $\alpha$ in $I$, we let $\varepsilon > 0$ be chosen such that $f(\alpha)\pm \varepsilon$ will be contained in the wall of $M$.
\end{itemize}
Note that we can expand the base across any compact, closed intervals completely contained in the domain by specifying a larger $\varepsilon$. This follows from the usual topological story about compactness, finite covers, and being bounded which keeps the rational discontinuities from escaping to infinity in a given interval.
\end{proof}
\subsection{Composition}
A common operation with functions is composition. Two suitably compatible function oracles can be composed together. On the rectangle level, this is matching the wall of one rectangle with the base of the other. We will be trying to compose the walls of $f$ into the base of $g$.
The basic requirement is that the bases of $g$ appropriately includes the walls of $f$. That is, for any given oracle in the domain of $f$, we can find an $f$-Yes rectangle whose base contains that oracle but whose wall is entirely contained in a base of $g$. This is the customary the domain of the enclosing function including the range of the input function. But this is insufficient. We also need to be able narrow the walls, to separate potential outputs. This requires that for any massed points of $g$, the outputs of $f$ which correspond to that must have a singleton output for it. A sufficient, but not necessary requirement, is that $g$ is mass-free, i.e., continuous.
An example to keep in mind is Thomae's function, $T$. It can be composed with the function oracle modelling $2x$ and will behave perfectly fine as all rational outputs being produced by $2x$ will be fed as singletons into $T$ thus producing singletons and not having any difficulties in being shrunk. On the other hand, if we look at $\sqrt{2} x$, the only rationals that are produced by this come out in non-singleton fashion. Thus, the combining of the outputs of $\sqrt{2} x$ as inputs into $T$ leads to rectangles whose walls will not narrow beyond $0:\frac{1}{q}$ if we are looking at $x = \frac{p}{\sqrt{2} q}$. The composition therefore fails to be a function oracle.
The function oracle $f$ is \textbf{composable} into $g$ if $f(\alpha)$ is in the domain of $g$ for all $\alpha$ and for $\beta = g(f(\alpha))$, if, for any given $g$-Yes rectangle $R$ whose base contains $f(\alpha)$, we can find an $f$-Yes rectangle whose base contains $\alpha$ and whose wall is contained in the base of $R$.
Then we define the \textbf{composition} $h$ to be the function oracle defined by stating that a rectangle $R$ is an $h$-Yes rectangle if there exists an $f$-Yes rectangle $M$ and $g$-Yes rectangle $N$ such that $R = \base{M} \times \wall{N}$ and $\base{N} = \wall{M}$.\footnote{The base of $N$ need not necessarily be the same as the wall of $M$ for this composition to work out, but when ever the base of $N$ is larger, we can use the Narrowing property to find a rectangle that does satisfy this requirement.} We will refer to $R$ as the composition of $M$ with $N$.
We also need to add in the closed property. The need to do this is demonstrated by the composition of the square function oracle with the square root functional oracle. The square root of 2 will always require a non-singleton interval and its composition with a squaring will not lead to a singleton interval. Thus, we cannot have the $2:2 \times 2:2$ singleton which will be present in $(\sqrt{x})^2$.
The other properties of the function oracle can be established. The elongating property follows from $g$'s elongating property while the narrowing property follows from $f$'s narrowing property. For intersecting, the base intersection of the $h$-Yes rectangles translates to the base intersection of the $f$-Yes rectangles so that those rectangles have an intersection which is $f$-Yes. Its wall can the be mapped into the base of the $g$-Yes rectangle, possibly by narrowing, to yield a wall contained in the original. That is, we have the same $h$-Yes rectangle contained in both of the original $h$-Yes rectangles.
For the separating property, let $r$ and $s$ be given in the $h$-Yes rectangle $R$ with $R$'s base containing the given $\alpha$ of the property. Let $N$ be the $g$-Yes rectangle whose wall is $R$ and whose base contains $f(\alpha)$. As $g$ is a function oracle, we can find a $g$-Yes rectangle $P$ whose base contains $f(\alpha)$ and whose wall excludes at least one of either $r$ or $s$. By the composability assumption, there exists an $f$-Yes rectangle $N$ whose base contains $\alpha$ and whose wall is contained in the base of $P$. Possibly by narrowing $N$, the composed rectangle is then an $h$-Yes rectangle that separates $r$ and $s$ and is contained in $R$ and has $\alpha$ in its base.
The inverse of a function oracle, if it exists, can be identified as the function oracle whose base and walls are flipped. That is, if $M$ is an $f$-Yes rectangle, then $\wall{M} \times \base{M}$ is a $f^{-1}$-Yes rectangle. We can extend the Yes rectangles to satisfy the elongating, narrowing, and closing properties. Separating is almost immediate as one can easily break up the $f$-Yes bases to make other such rectangles.
It is the Intersecting property which breaks down. There is no reason to assume that intersecting walls of $M$ are coming from the same base. If we impose that condition on $f$, then the inverse exists and this procedure produces it.
\subsection{Taylor Polynomials}
Functions that can be written as Taylor polynomials can be modeled as function oracles. The setup is to have a family of polynomials with $x$-based error bars where any pair of polynomials has a relationship of one being wholly contained within the error envelope of the other. In addition, one should be able to find at least one polynomial with an error as small as one wants specified for a given $x$.
We can then define the function oracle as the collection of rectangles defined by each polynomial's rectangles with error bars extending the rectangles appropriately. One should be able to readily establish the function oracle properties and argue that the function value is indeed what one gets from the usual Taylor polynomial setup.
\subsection{Intermediate Value Theorem}
In what follows, we extend our notation of $a:b$ for rationals to include oracles as well, where $\alpha : \beta$ represents the interval $[\alpha,\beta]$ or $[\beta, \alpha]$, depending on the order relation of $\beta$ and $\alpha$. In dealing with the Intermediate Value Theorem, it is convenient to describe the interval between two numbers without having to specify which one is greater than the other since it does not actually matter. We could also use the notation $[\alpha]:[\beta]$ if we wanted to emphasize that these are oracles rather than rational numbers. This notation would hopefully help to recall that we are dealing with Yes-intervals as representatives of the oracles.
The usual Intermediate Value Theorem states that if a function $f$ is continuous, then for any $y$ in $f(a):f(b)$, there exists a $c$ in $a:b$ such that $f(c) = y$. We have a slightly different statement.
\begin{theorem}[Intermediate Value Theorem for Function Oracles]
Let $f$ be an oracle function. Given $a:b$ such that all oracles in $a:b$ are in the domain of $f$, then given an oracle $v$ satisfying $f(a):v:f(b)$, we can generate an oracle $c$ such that all neighborly $f$ rectangles $R$ whose base contains $c$ will have the property that $v$ is contained in the wall of $R$.
\end{theorem}
\begin{proof}
Take a rational number strictly between $a$ and $b$, say $m$. Look at $f(m)$. If it is $v$, then we are done. If not, then we have several cases:
\begin{enumerate}
\item $f(m):f(a):v:f(b)$. Choose $b:m$ for the next interval.
\item $f(a):f(m):v:f(b)$. Choose $b:m$ for the next interval.
\item $f(a):v:f(m):f(b)$. Choose $a:m$ for the next interval.
\item $f(a):v:f(b):f(m)$. Choose $a:m$ for the next interval.
\end{enumerate}
In all cases, we have chosen the interval so that $v$ is between the images of the endpoint.
We iterate this. If the lengths of the intervals go to zero, then we have a fonsi. We can ensure this by choosing the midpoint of each interval. Once we have a fonsi, then we have an Oracle, say $c$.
Now let us assume that $R$ is a neighborly $f$-Yes rectangle containing $c$. We need to show that $v$ is contained in its wall. Let $p:c:q$ be the base of $R$. By construction of $c$, $p:q$ contains a $c$-Yes interval $r:s$ such that $f(r):v:f(s)$. Since $f$-Yes rectangles include all the images of the base, we have $f(r):f(s)$ is contained in the wall of $R$ and thus it contains $v$ as well as was to be shown.
\end{proof}
A particular $m$ that we could choose is the mediant. We can also set it up so that we have a Farey pair as we can always enclose an interval in such a pair and choose the starting interval subinterval of the mediant if the mediant is not within the starting interval. In any event, by using the Farey construction, given an interval of interest to the oracle, say $u:v$, we can be assured that once the mediant denominator is past the denominator size of $u$ and $v$, then the narrowed interval will be either strictly inside or outside of $u:v$ and, hence, we will have an answer to our query.
\begin{corollary}[Intermediate Value Theorem for Continuous Functions]
If $f$ is mass-free on the interval $a:b$, then for each oracle $v$ in $f(a):f(b)$, we have an oracle $c$ in $a:b$ such that $f(c)=v$.
\end{corollary}
\begin{proof}
$c$ exists by the above theorem. Let's assume $d(f(c), v) = L > 0$. By being mass free, there exists an $f$-Yes rectangle $M$ such that $c$ is contained in $\base{M}$, $|\base{M}| > 0$ and $|\wall{M}| < L$. But that means $v$ cannot be in the wall of $M$ which contradicts the previous theorem.
\end{proof}
We should note that all neighborly oracles $c$ will automatically be mass-free.
\subsection{Derivatives}
Limits use notation $a:\cancel{0}:b$ to indicate an interval without, say $0$. Use something like $f_{a:\cancel{0}:b}$ to indicate the function image of the interval.
This viewpoint does not seem to offer anything particularly novel about derivatives, but it is useful to point out how it can go.
To define the derivative, we first need to expand our function oracle ideas to function oracles with two inputs. The basic idea is the same, creating base rectangles from pairings of Yes intervals, one from each of the two input oracles and then the wall representing the range of function values. The properties are essentially unchanged. A more thorough discussion of generalizations can be found in \cite{taylor23metric}.
Given a function oracle of one input, we can then form the difference quotient as a function of two variables as $g(\alpha, \beta) = \frac{ f(\alpha) - f(\beta) }{\alpha - \beta}$. This is an arithmetic of oracles and so it is perfectly well-defined as long as $\alpha \neq \beta$ and the representative intervals for $\alpha$ and $\beta$ are taken to be disjoint.
We can then define a proto-function oracle $f'(\alpha)$ as being formed by rectangles whose walls are the container of $g(\alpha, \beta)$-rectangles for $\beta$ in the base of the rectangle. The domain of the derivative would be any points which can be established to meet the criteria of function oracles.
It is not clear what this adds to the usual story, though it somewhat aligns with uniform differentiability as in \cite{BriStol} which replaces the mean value theorem with the law of bounded change, which basically says that if $f$ is uniformly differentiable and $A \leq f' \leq B$ on the interval $[a,b]$, then $A(b-a) \leq f(b)-f(a) \leq B(b-a)$.
\subsection{Integrals}\label{sec:int}
These functions seem to be very much in the spirit of integrable functions. We will pursue this angle from the point of view of Darboux integration, which is equivalent to Riemann integration. Darboux integration is taking a partition of the interval in question and then computing the upper and lower area sums of the function by taking the height of each rectangle as the supremum for the upper sum and as the infimum for the lower sum. As the partitions get smaller, if the upper and lower sums converge, the limiting value is the integral value. Here we consider bounded functions on a bounded interval.
It is tempting to assert that Darboux integrable functions are function oracles. Indeed, each partition is essentially giving the rectangle that the function oracles require. The ability to shrink the partitions and have it be integrable on arbitrary intervals strongly conforms to the spirit of function oracles. Unfortunately, the integrable functions allows for discontinuity at irrationals which function oracles do not tolerate.
Since we established previously that function oracles are continuous at any irrational point that they are defined on, they are Darboux / Riemann integrable on any interval for which they are bounded and defined on.
To do it from first principles, we need to discuss partitions of the domain, but once we have that sorted, the rectangles of the oracles provides the areas. We presumably would want to discuss the minimum rectangle covering an interval, perhaps with an $\varepsilon$ cut-off to avoid an infinite regress.
We can also include the singletons as a probability-style mass function if we wish. We could add them up as a discrete sum, assuming the sum converges.
This may also be a good point to mention that our function oracles are defined by their behavior on what is a set of measure zero, namely, the rationals. We cannot arbitrarily redefine these functions on rationals even though we do have some freedom thanks to singletons. But those changes are constrained on the infinite set of rationals.
Let us define the integral oracle. Given an $f$-Yes rectangle, $R$, a partition of $R$ is a finite set of $f$-Yes rectangles that cover the base of $R$ and intersect only at the endpoints of their bases. A lower sum of $R$ is a sum of the product of the minimum of the walls times the length of their bases for a partition of $R$ while an upper sum of $R$ is the same but considering the maximum of the walls. The integral oracle of $R$ is defined as the rule that a Yes interval is an interval whose lower endpoint is a lower sum and the upper endpoint is an upper sum. Any independent singleton will contribute 0 to this process though one could modify the process and conditions to giving singletons a weight as with probability mass functions.
We need to establish that this is an oracle. Closed was added in by definition. Elongating consistency follows from our ability to elongate the rectangles so that we can always make a lower sum less or an upper sum more. Narrowing consistency involves taking finer paritions. Existence is given by the interval $|\base{R}|*\wall{\underline{R}}: |\base{R}|*\wall{\overline{R}}$ where $|\base{R}|$ is the length of the base of $R$, $\wall{\underline{R}}$ is the minimum value in the wall of $R$, and $\wall{\overline{R}}$ is the maximum value of the wall of $R$.
For the other two properties, we will use the fonsi approach. The fact that they are overlapping intervals is easy to see as given two Yes intervals, each has their own partition. We can refine the partitions by taking intersections. These refined partitions will have a lower sum which is greater than or equal to the lower sums of the two coarser partitions while the upper sum will be less than or equal to the upper sums of the coarser partitions. Thus, the new interval is contained in both of the previous partitions and the Yes intervals intersect.
The hard part of the proof is to show that there exists an interval that is less than or equal to a given length. Let $\varepsilon > 0$ be given. Let $\delta = \frac{\varepsilon}{2|\wall{R}|}$. We want to have an almost partition of $R$ such that the bases have length at least $|\base{R}| - \delta$. We will have the length of the walls over those partitions be less than $m = \frac{\varepsilon}{2|\base{R}|}$. This would then mean that the lower and upper sum difference will be less than $\frac{\varepsilon}{2|\base{R}|} * |\base{R}| = \frac{\varepsilon}{2}$. The rest of the partition can be whatever and the sum difference will be bounded by $\delta * |\wall{R}| = \frac{\varepsilon}{2}$.
To argue for the existence of such a partition, we would like to pick a sequence of $\alpha_k$'s such that we have rectangles $R(k, m)$ whose walls have height less than $m$ and such that the bases $\base{R} (k, m)$ sum up to be at least $|\base{R}|-\delta$. Our approach will be to extract a finite cover from an infinite cover. We first need to exclude the uncooperative points.
Consider the set of rational points $q$ in $\base{R}$ such that there is no non-singleton rectangle whose base contains $q$ and whose height is less than $m$. Since these are rationals, we can enumerate them, e.g., by their ordering on the Stern-Brocot tree. Let $q_n$ denote the $n$-th one. Let $\alpha_n$ and $\beta_n$ be irrational oracles that satisfy $q_n - \frac{\delta}{2^{n+1}} \leq \alpha_n < q_n < \beta_n \leq q_n + \frac{\delta}{2^{n+1}}$ and are in $\base{R}$; if $q_n$ is an endpoint of $\base{R}$, then we just use the one side that is in $\base{R}$. Since the $\alpha_n$ are irrational oracles, there exists rectangles $A_n$ and $B_n$ whose base side contains $\alpha_n$ and $\beta_n$, respectively and whose heights are less than $\epsilon$. Let $r_n$ and $s_n$ be the upper and lower endpoints of the bases of $A_n$ and $B_n$, respectively. We have that $r_n < q_n < s_n$ is an open interval which contains $q_n$. If we take the union of such intervals, we get an open set whose length is less than $\sum_{i=0}^\infty \frac{\delta}{2^{n+1}} = \frac{\delta}{2} * 2 = \delta$ and, when we remove it from $\base{R}$, we are left with a closed and bounded set. In what remains, we can cover it with rectangles (the open interiors of the bases) all of whose height is less than $m$ since we have removed all points that could not be so covered. By the Heine-Borel Theorem, there is a finite cover of such rectangles. We then know that their upper and lower sum differences are bounded by $|\base{R}|*m < \frac{\varepsilon}{2}$. The other portion has rectangles bounded in height by $|\wall{R}|$ and the length is less than $\delta$. So those height differences are bounded by $|\wall{R}|*\delta = \frac{\varepsilon}{2}$. Because of the finite cover by the rectangles, the removed open set can be covered by the finite number of intervals in between the bases of the finite cover. We can thus cover that set with a finite number of rectangles with wall $\wall{R}$. Combined, the two sum to $\varepsilon$ and we have established that we have a finite partition whose upper and lower sums are within $\varepsilon$ of each other.
\medskip
\appendix
\section{Exponential and Logarithmic Functions}\label{app:e}
We can use this framework to inform the function oracle construction for the base $e$ exponential and natural logarithm. We will cheat a little in our informal analysis and use some calculus. Specifically, we will use Taylor's theorem in the form $\ln(1+x) = x - \frac{x^2}{2} + \frac{2u^3}{6}$ for $x$ strictly contained in $-1:1$ and for some $u$ in $x:0$. We will also use some properties of the logarithm.
The claim is that $(1+\frac{x}{n})^n \leq e^x \leq (1+\frac{x}{n})^{n+1}$ for $0 \leq x \leq 2$. Note that we established above that $x=1$ satisfies this. At $x=0$, all three become $1$.
In that inequality, we have the left one holds for all $x$. This is the same argument as the generalized AGM inequality, with $\frac{1}{n}$ replaced by $\frac{x}{n}$, showing that this is an increasing sequence. We do need to show that this converges to $e^x$ which means defining that. In the function oracle section, we did so by essentially defining $e^x$ as $(1+\frac{1}{n})^{nx}$. To show the limit is the same, we will just sketch the plausibility using the binomial theorem.
We make a small observation here that $$\frac{m^r(1 - \frac{r+1}{m})^r}{r!} = \frac{(m - (r+1))^r}{r!} \leq \binom{m}{r} \leq \frac{m^r}{r!}$$ This follows from $\binom{m}{r} = \frac{\prod_{i=0}^{r+1} (m-i)}{r!}$. For example, $m=15$ and $r=3$, becomes $\frac{3^3}{3!} \leq \binom{15}{3} \leq \frac{15^3}{3!}$ while $m=15$ and $r=13$, becomes $\frac{1^3}{13!} \leq \binom{15}{13} \leq \frac{15^3}{13!}$.
We are working with rational $x$ and so we take a fixed $x=\frac{a}{b}$ to consider. Take $n = kb$ where we can make $k$ as large as we like. We will first look into $(1+ \frac{a/b}{n})^n$. We will write down a bounding interval for the terms of the binomial expansion and show that they converge to each other as well as to the Taylor formula. Indeed,
$$\bigg(1+\frac{x}{n}\bigg)^n = \bigg(1+ \frac{a/b}{kb}\bigg)^{kb} = \sum_{r=0}^{kb} \binom{kb}{r} \bigg(\frac{a}{kb^2}\bigg)^r$$
Each term in the sum satisfies
$$\frac{(kb)^r}{r!} \bigg( 1 - \frac{r+1}{kb}\bigg)^r \bigg(\frac{a}{kb^2}\bigg)^r \leq \binom{kb}{r} \bigg(\frac{a}{kb^2}\bigg)^r \leq \frac{(kb)^r}{r!} \bigg(\frac{a}{kb^2}\bigg)^r$$
which then becomes
$$\bigg( 1 - \frac{r+1}{kb}\bigg)^r \frac{1}{r!} \bigg(\frac{a}{b}\bigg)^r \leq \binom{kb}{r} \bigg(\frac{a}{kb^2}\bigg)^r \leq \frac{1}{r!}\bigg(\frac{a}{b}\bigg)^r$$
For a fixed $r$, we can take $k$ larger and larger to show that the $r$-th term of the sum converges to $\frac{1}{r!}x^r$ which is the Taylor sum for the exponential.
We now turn our attention to $(1+\frac{1}{n})^{\frac{na}{b}}$ and come to a similar conclusion with $n= kb$. Since $n=kb$, we have that this is equivalent to $(1+\frac{1}{kb})^{ka}$ which has an integer exponent and we can therefore use the binomial expansion to obtain $\sum_{r=0}^{ka} \binom{ka}{r} (\frac{1}{kb})^r$. We again use the same bounding of binomial coefficients to come up with the term bounds
$$\frac{(ka)^r}{r!} \bigg( 1 - \frac{r+1}{ka}\bigg)^r \bigg(\frac{1}{kb}\bigg)^r \leq \binom{ka}{r} \bigg(\frac{1}{kb}\bigg)^r \leq \frac{(ka)^r}{r!} \bigg(\frac{1}{kb}\bigg)^r$$
which then becomes
$$\bigg( 1 - \frac{r+1}{ka}\bigg)^r \frac{1}{r!} \bigg(\frac{a}{b}\bigg)^r \leq \binom{ka}{r} \bigg(\frac{1}{kb}\bigg)^r \leq \frac{1}{r!}\bigg(\frac{a}{b}\bigg)^r $$
Just as before, if we fix $r$ and take $k$ to be sufficiently large, then the two sides of the inequality can be brought arbitrarily close together.
We can therefore conclude that as we let $k$ get large, the two sums are approximately the same and, indeed, approach the classic sum of $\sum_{i=0}^\infty \frac{x^i}{i!}$.
Another goal was to show that $(1 + \frac{x}{n})^{n+1}$ is an upper bound for $e^x$. Unfortunately, this is only true for $0 < x < 2$. To see why, consider the equation $e^x = (1+\frac{x}{n})^{n+1}$. Taking the natural logarithm and using the power rule, we have $x = (n+1) \ln (1 + \frac{x}{n} ) = (n+1) (\frac{x}{n} - \frac{x^2}{2n^2} + \frac{2u^3}{6})$; note $u$ is smaller than $\frac{x}{n}$. As we are looking for a non-zero solution, we can multiply both sides by $\frac{n}{x (n+1)}$ to get $1- \frac{1}{n} = 1 - \frac{x}{2n} + s$ where $s = \frac{2u^3 n}{6 x (n+1)}$. Solving for the main $x$, we get $x = 2 + 2n s$. This establishes that we are safe to use $x < 2$. The term $2n s$ is bounded by a factor of $\frac{1}{n^2}$ for moderate $x$.\footnote{$2ns = \frac{2n2n}{6x(n+1)} u^3 < \frac{4n^2}{6(n+1)x} \frac{x^3}{n^3} = \frac{4x^2}{6n(n+1)}$ where we used $u <\frac{x}{n}$. Also, recall that this presupposes $-n < x < n$. If we assume $x < 4$, then we can get the bound $\frac{64}{6n(n+1)} < \frac{11}{n^2}$. } As $n$ gets large, $2$ will become a sharp bound.
In any event, we have by the Intermediate Value Theorem, that $e^x < (1+\frac{x}{n})^{n+1}$ for $0 < x< 2$.
The interesting part of this is for using this to define bounds for the logarithm. If we have two monotonically increasing functions with one always larger than the other, then the inverses will satisfy the reverse inequality.\footnote{If $y = f(a)=g(b)$, and $f(x) < g(x)$ generally, then $f(a) < g(a)$ implies we must have $a > b$ for $g$ an increasing function. Explicitly, $g(b) = f(a) < g(a)$ which implies $b < a$ and, thus, $g^{-1} (y) < f^{-1} (y)$.} The inversion of the lesser one is $n(\sqrt[n]{ x }- 1)$ while the greater one inverts to $n(\sqrt[n+1]{x} - 1)$. We therefore have $n(\sqrt[n+1]{x} - 1) \leq \ln(x) \leq n (\sqrt[n]{x}-1)$ for $1 < x < e^2$. This gives us bounding rectangles. Because the $n (\sqrt[n+1]{x} - 1) = \ln(x)$ for $x$ slightly larger than $e^2$, the lower bound is the one that will typically be a better approximation. While the bounding only applies for a limited region, we can use the properties of the logarithm to compute any of its other values that we like. For example if a number is written in the form $x=a\times 10^b$ for $1 \leq a < 10$ and $b$ an integer, then $\ln(x) = 2 ( \ln( \sqrt{a} ) + b \ln(\sqrt{10}) )$ where both square roots will be between $1$ and $4< e^2$. We have already discussed bounding the square roots of numbers and so we can combine this with the bounds found above to produce a bounding rectangle for the logarithm for any given $x>0$.
Using the representation of $ n (\sqrt[n]{x}-1)$, we can compute the derivative of that expression and confirm that it also approaches the derivative of the logarithm. Indeed, $\frac{ n (\sqrt[n]{x}-1) - n (\sqrt[n]{y}-1)}{x-y} = n \frac{a-b}{a^n -b^n} = \frac{n}{\sum_{i=0}^{n-1} a^{n-1-i} b^i}$ where $x = a^n$ and $y = b^n$. For $a$ and $b$ near each other, that sum is basically $n a^{n-1}$ leading to the derivative being $x^{-1+1/n}$ which does indeed converge to $\frac{1}{x}$. We also have to deal with the shifting to the interval. The difference quotient for the logarithm at $x = a\times 10^b$ and $y = c \times 10^b$ is $2 \frac{\ln(\sqrt{a}) - \ln(\sqrt{c})}{(a-c)10^b} = \frac{2}{10^b(\sqrt{a}+\sqrt{c})} \frac{\ln \sqrt{a} - \ln \sqrt{c} }{\sqrt{a}- \sqrt{c}} $. As $a$ and $c$ become close, we end up with approximately $\frac{2}{10^b 2 \sqrt{a}} \frac{1}{\sqrt{a}} = \frac{1}{a\times 10^b} = \frac{1}{x}$.
\normalem %restoring normal emphasis in bibliography
\printbibliography
\end{document}