• mathematics

Defining a Limit Formally

After building the intuitive idea of what a limit is, you may be dissatisfied with the lack of rigor in how the concept is defined. Guessing the value of a limit like limx2(x+5)(x2)(x2)=7\lim\limits_{x \to 2} \frac{(x +5 )(x - 2)}{(x - 2)} = 7 is straightforward if you have an image of its graph, but how could you prove it? You could say “as xx approaches 22, output values get closer to 77”, but what does “closer” mean here? Do output values have to be strictly closing distance toward 77? What if the output values trend towards 77 but oscillate back and forth as xx approaches 22?

Formalizing intuition

In order to prove that the limit equals 77, we need to specify what a limit is. In the previous chapter, we looked at tables of xx and yy values, and if from both sides, as the xx value approached some given constant, the yy values appeared to converge somewhere, we concluded that the limit was at that point of convergence. The question that naturally appears is “How close to our posited point of convergence do we have to get in order to define the limit there?”

Let’s think back to our intuitive idea of the limit and see how we can apply it. Take f(x)f(x) as the signum function, which returns an output of 1-1 for all negative inputs, 00 for an input of 00, and 11 for all positive inputs. We want to test if limx0f(x)=0\lim_{x \to 0} f(x) = 0 is true. As shown in Fig. 1, if you go any distance left or right of x=0x = 0, you jump to y=1y = -1 or y=1y = 1. Even just by looking, this is uncontroversially a limit that does not exist, because the y-values are never “approaching” y=0y = 0.

1980-01-01T00:00:00+00:00 image/svg+xml Matplotlib v3.11.0, https://matplotlib.org/
Fig. 1: Signum function

What would make this limit exist? Well, it might look like Fig. 2, where we smoothly curve the breakpoints into each other. By making it possible to go left/right of (0,0)(0, 0) by some infinitesimally small distance and not jump directly to y=±1y = \pm 1, the function becomes continuous. Therefore, in order to weed out these jumps, let’s create tiny distances from y=0y = 0. If the limit exists, there should be a small window around the value our xx approaches where every single corresponding output is within that distance to y=0y = 0. Otherwise, there would be a clear jump of output values immediately to the left or right of x=0x = 0, just like with the signum function.

Since we’re still using the phrase “tiny distances”, let’s formalize that into a symmetric window around y=0y = 0, as shown in Fig. 2 by the dashed lines. Call ε\varepsilon (pronounced “epsilon”) the distance from the center to the top/bottom line, so in our case, we’d have a window created by the lines y=0εy = 0 - \varepsilon and y=0+εy = 0 + \varepsilon. Next, we need to make an appropriate window on the x-axis for any ε\varepsilon value. Use the variable δ\delta (pronounced “delta”) to make a window from x=0δx = 0 - \delta to x=0+δx = 0 + \delta. The criteria for a valid δ\delta is that any xx you choose within that window will correspond to a yy within the window on the y-axis.

For an existent limit, this means that there’s a maximum δ\delta value you could choose, as illustrated by the vertical lines in Fig. 2. If you try going higher than this value, one of the x-values near the edge of the window will correspond to a y-value outside our defined ϵ\epsilon window. Anything lower will be valid, since it’d correspond to an output interval that’s a subset of our ϵ\epsilon defined one. However, δ\delta is never zero. Since the point of a limit is to see what the value approaches without actually taking into account the value itself, we exclude the x-value we’re approaching from the horizontal window test.

1980-01-01T00:00:00+00:00 image/svg+xml Matplotlib v3.11.0, https://matplotlib.org/
Fig. 2: Epsilon and maximum delta

Let’s try to generalize this process for any function. We’ll use the generic form of limxaf(x)=L\lim_{x \to a} f(x) = L. There’s ε>0\varepsilon > 0 for the vertical window, and we need a corresponding δ>0\delta > 0 such that if the distance of the xx value to aa is under δ\delta but not zero (which can be notated as 0<xa<δ0 < |x - a| < \delta), then the distance from the output value to LL is less than ε\varepsilon (notated as f(x)L<ε|f(x) - L| < \varepsilon). If we can show that a valid δ\delta exists for any ε>0\varepsilon > 0, then limxaf(x)=L\lim_{x \to a} f(x) = L has been proven true.

Proving a limit statement

With our rigorous definition of a limit, let’s try proving limit statements. Remember that the goal is simply to prove that if 0<xa<δ0 < |x - a| < \delta, then f(x)L<ε|f(x) - L| < \varepsilon. If we can express δ\delta in terms of ε\varepsilon, we can translate the right side of xa<δ|x - a| < \delta to something involving ε\varepsilon.

We’ll try to prove limx22x=4\lim_{x \to 2} 2x = 4. Although 2x2x is defined at x=2x = 2, we’ll use this to get familiar with the structure of what an epsilon-delta proof looks like. Start by orienting ourselves with the goal: If ε\varepsilon is a given positive number, find a δ\delta such that if 0<x2<δ0 < |x - 2| < \delta, then 2x4<ε|2x - 4| < \varepsilon. We factor 2x4|2x - 4| to 2x22|x - 2|. This changes our goal to proving x2<ε/2|x - 2| < \varepsilon / 2.

Let’s set δ=ε/2\delta = \varepsilon / 2 since our given was that 0<x2<δ0 < |x - 2| < \delta and prove this works no matter what ε\varepsilon was given. 2x4=2x2<2δ|2x - 4| = 2|x - 2| < 2\delta just by doubling our given inequality. 2δ=ε2\delta = \varepsilon because of the δ\delta we chose, so now we have 2x4<ε|2x - 4| < \varepsilon. By taking our given conditions, we’ve proven the desired inequality, so limx22x=4\lim_{x \to 2} 2x = 4.

Our proof requires that we first express δ\delta in terms of ε\varepsilon, because we are first given ε\varepsilon and need to find a valid δ\delta that works under those conditions. By finding a function with δ\delta as the dependent variable, we can make it work for any ε\varepsilon that exists. If you were wondering why we set δ=ε/2\delta = \varepsilon / 2, it’s because we were reverse-engineering the desired result. We wanted 2x4<ε|2x - 4| < \varepsilon, which algebraically can be manipulated to x2<ε/2|x - 2| < \varepsilon / 2. Since we already had x2<δ|x - 2| < \delta from the original given, we wanted to make δ\delta (a variable which we control) equal to ε/2\varepsilon / 2, since the proof becomes trivial after that step.

Since δ\delta can be made smaller and still satisfy being in the ε\varepsilon window (just a smaller subset of it), our proof still works if we tried setting δ=ε/3\delta = \varepsilon / 3. Start with x2<δ|x - 2| < \delta, then we have x2<ε/3|x - 2| < \varepsilon / 3, so 2x2=2x42|x - 2| = |2x - 4| is less than 2ε/32\varepsilon / 3, which still satisfies our original desired result of being less than ε\varepsilon.

Higher complexity

I designed the limit we just proved to be as straightforward as possible with delta-epsilon. We started by working backwards from the inequality we wanted to prove, then got the left side to be the same as the given inequality. After expressing δ\delta in some form of ε\varepsilon, the proof could be finished simply by manipulating our given inequality into the desired inequality with clever substitution.

This is the extent of delta-epsilon you’d probably encounter in an introductory calculus course, but non-contrived limits are still provable. To finish off this chapter, let’s work through limx2x3=8\lim_{x \to 2} x^3 = 8 and find a more general pattern. We want to prove for every positive ε\varepsilon, there is a δ\delta such that if 0<x2<δ0 < |x - 2| < \delta, then x38<ε|x^3 - 8| < \varepsilon.

Start by factoring x38=(x2)(x2+2x+4)x^3 - 8 = (x - 2)(x^2 + 2x + 4), which gets us x38=x2x2+2x+4|x^3 - 8| = |x - 2| \cdot |x^2 + 2x + 4|. This is where we branch off from the previous example, because x2+2x+4|x^2 + 2x + 4| has a variable inside it, so we can’t divide ε\varepsilon by it. We’re going to try to constrain δ\delta two different ways. We can set δ1\delta \leq 1, then the quadratic reaches max at x=3x = 3, giving us x2+2x+4<19|x^2 + 2x + 4| < 19 for that defined δ\delta. Still with δ1\delta \leq 1, x2x2+2x+4<x219|x - 2| \cdot |x^2 + 2x + 4| < |x - 2| \cdot 19, and our desired inequality has this less than ε\varepsilon, so we do x2<ε/19|x - 2| < \varepsilon / 19.

In order for this to work, we needed both δ1\delta \leq 1 for x2+2x+4<19|x^2 + 2x + 4| < 19 and δε/19\delta \leq \varepsilon / 19 to get us to our desired inequality. Both will be satisfied if we just choose the smaller one, so use δ=min(1,ε/19)\delta = \min(1, \varepsilon / 19). Now we’re at a familiar place, and the strategy you should remember for this general case is restricting δ\delta one way and using its result to restrict it another way.

To finish off, we started with a given ε>0\varepsilon > 0, 0<x2<δ0 < |x - 2| < \delta, and we’ve defined δ=min(1,ε/19)\delta = \min(1, \varepsilon / 19). We have x2<1|x - 2| < 1, and the δ1\delta \leq 1 gives us x2+2x+4<19|x^2 + 2x + 4| < 19. With our definition of δ\delta, we also get x2<ε/19|x - 2| < \varepsilon / 19. Now, x38|x^3 - 8| which becomes x2x2+2x+4|x - 2| \cdot |x^2 + 2x + 4| is less than ε/1919=ε\varepsilon / 19 \cdot 19 = \varepsilon, which proves the limit.

Now that we’ve formalized the limit, we can start becoming comfortable manipulating and composing limits, which is exactly what we’ll do in the next chapter. That is all for the epsilon-delta definition of limits, and until next time, I am out.