Search Knowledge

© 2026 LIBREUNI PROJECT

Calculus & Analysis / Overview

Limits and Continuity

Limits and Continuity

Calculus is built on the concept of change over zero. To make sense of “instantaneous” change, we need a way to talk about what a function does as it gets closer and closer to a point, even if it never actually reaches it. This is the Limit.

1. The Epsilon-Delta Definition

Intuition: A limit limxcf(x)=L\lim_{x \to c} f(x) = L means we can force f(x)f(x) to be as close to LL as we want (within ϵ\epsilon), just by making xx sufficiently close to cc (within δ\delta).

For every ϵ>0\epsilon > 0, there exists a δ>0\delta > 0 such that 0<xc<δ    f(x)L<ϵ0 < |x - c| < \delta \implies |f(x) - L| < \epsilon.

Let’s vizualize this. If f(x)=2xf(x) = 2x, and we want to be within ϵ=0.1\epsilon = 0.1 of the output L=4L=4 at x=2x=2, how close must xx be?

python
1import numpy as np
2import matplotlib.pyplot as plt
3 
4def f(x): return 2 * x
5 
6c, L = 2, 4
7epsilon = 0.1
8delta = epsilon / 2 # For f(x)=2x, delta is exactly epsilon/2
9 
10x = np.linspace(c - 2*delta, c + 2*delta, 500)
11y = f(x)
12 
13plt.plot(x, y, label='f(x)=2x')
14plt.axhline(L + epsilon, color='r', linestyle='--', label='L + ε')
15plt.axhline(L - epsilon, color='r', linestyle='--', label='L - ε')
16plt.axvline(c + delta, color='g', linestyle='--', label='c + δ')
17plt.axvline(c - delta, color='g', linestyle='--', label='c - δ')
18 
19plt.fill_between([c-delta, c+delta], L-epsilon, L+epsilon, color='yellow', alpha=0.3, label='Safe Zone')
20plt.legend()
21plt.title("The Epsilon-Delta Game")
22plt.show()

2. When Limits Fail

A limit only exists if it matches from both directions. If the “safe zone” can’t be established because the function jumps or oscillates, the limit does not exist.

Consider f(x) = sin(1/x) near x=0. Why does the limit as x -> 0 DNE?

3. Continuity: The Glue of Calculus

A function is continuous at cc if the limit exists and exactly matches the function’s value: limxcf(x)=f(c)\lim_{x \to c} f(x) = f(c).

Let’s test for a “Broken” function: f(x)={x2x<12x=1xx>1f(x) = \begin{cases} x^2 & x < 1 \\ 2 & x = 1 \\ x & x > 1 \end{cases}

python
1import numpy as np
2 
3def f(x):
4 if x < 1: return x**2
5 if x == 1: return 2
6 return x
7 
8# Check limit from left and right
9left_lim = f(0.999999)
10right_lim = f(1.000001)
11value = f(1.0)
12 
13print(f"Limit from left: {left_lim}")
14print(f"Limit from right: {right_lim}")
15print(f"Actual value at 1: {value}")
16 
17is_continuous = np.isclose(left_lim, right_lim) and np.isclose(left_lim, value)
18print(f"Is continuous? {is_continuous}")

4. The Intermediate Value Theorem (IVT)

If ff is continuous on [a,b][a, b], it must hit every value between f(a)f(a) and f(b)f(b). This is why we can use the Bisection Method to find roots.

If f(x) is continuous and f(1) = -5 and f(2) = 5, must there be a zero in (1, 2)?

5. Summary Check

Which is a 'stronger' condition (if A holds, B must hold)?

Previous Module Laplace Transforms