III.2 · Calculus
When does the value at a point agree with its neighbours?
Adjust two pieces until they meet, move a single value away, delete it, or meet a pole and an endpoint — and test the three conditions of continuity at each step.
Test the three conditions of continuity
Continuity of f(x) = x² + c (x < 1), m·x (x > 1) at a = 1
Graph of f(x) = x² + c (x < 1), m·x (x > 1) with c = 0, m = 2. At a = 1: f(a) 2, left limit 1, right limit 2. Discontinuities in view at x = 1.
- Point
- 1
- Value at a
- 2
- Left limit
- 1
- Right limit
- 2
- f(a) exists
- yes
- The two-sided limit exists
- noThe one-sided limits are not one finite number.
- The limit equals f(a)
- noNeeds (i) and (ii).
- Discontinuities in view
- at 1 (jump)
Exact values use =; binary64 approximations use ≈. Undefined values state their reason.
Exceptional case: A jump: the one-sided limits 1 and 2 differ, so condition (ii) fails. Make 1 + c equal m to join the pieces.
(i) Is f(a) defined?
Yes: f(1) = 2.
from −2 to 2, up to 2 decimal places
from −2 to 3, up to 2 decimal places
from −2.5 to 2.5, up to 2 decimal places
The opening function jumps at : the left piece arrives at and the right piece leaves from . Raise to and the pieces meet. Then choose v and drag the open value at : the limit stays while moves, so the function is no longer continuous although its graph has only a single misplaced point.
Intuition: no break where you look
A continuous function can be drawn through the point without lifting the pen. That picture needs three separate things: there must be a point to draw, the curve must arrive at one height from both sides, and that height must be the point itself. Each can fail on its own, and the explorer lets you break each one.
Definition
A function is continuous at when
- is defined;
- exists (both one-sided limits exist, are finite and agree);
- .
If is an endpoint of the domain, only the side inside the domain is used: is continuous from the right at when . A function is continuous on an interval when it is continuous at every point of it.
Mechanics: what the explorer checks
The opening function is for and for , with taken from the left piece, the right piece, a custom value , or left undefined. The inspector shows the three conditions as yes/no rows derived from the exact one-sided limits and the exact value; the verdict names the kind of discontinuity. The global row lists every discontinuity inside the view, so you can compare a statement at one point with a statement about the whole function.
Derivation: when the pieces join
At the left piece approaches and the right piece approaches . Condition 2 holds exactly when
Condition 3 then requires to equal this common value. With the right-piece value , continuity holds exactly when . With a custom value , it also needs .
Worked example
Take , and set . The left limit is and the right limit is , so the two-sided limit is . But : condition 3 fails. This is a removable discontinuity: redefining repairs it without changing any other value.
Replay the worked derivation
(i) Is f(a) defined?
Yes: f(1) = 0.
Kinds of discontinuity
- Removable: the limit exists but is missing or different. Redefine one value to repair it.
- Jump: both one-sided limits exist but differ. No single value can repair it.
- Infinite: at least one side is unbounded, as for at .
- Oscillating: no one-sided limit exists, as for at (III.1).
At an endpoint, such as at , the missing left side is not a failure: is continuous from the right there.
Executable reference code
The reference checks the three conditions with exact Fraction limits of polynomial pieces. The NumPy version scans many values of at once and measures the jump size , which is zero only on the continuous configuration.
"""The three conditions of continuity, decided exactly for two polynomial pieces meeting at x = 1 (III.2)."""
from fractions import Fraction as F
def check(c, m, value_at_1):
"""Left piece x**2 + c (x < 1), right piece m*x (x > 1), f(1) = value_at_1 (None = undefined)."""
left_limit = 1 + c # polynomial pieces: the one-sided limit is the piece evaluated at 1
right_limit = m
defined = value_at_1 is not None
limit_exists = left_limit == right_limit
agrees = defined and limit_exists and value_at_1 == left_limit
return defined, limit_exists, agrees
assert check(F(1), F(2), F(2)) == (True, True, True) # joined
assert check(F(0), F(2), F(2)) == (True, False, False) # jump
assert check(F(1), F(2), F(0)) == (True, True, False) # removable: limit 2, value 0
assert check(F(1), F(2), None) == (False, True, False) # value missing"""Scan many configurations at once: the jump |1 + c - m| vanishes only where the pieces join (III.2)."""
import numpy as np
c = np.linspace(-2, 2, 17) # steps of 0.25: exactly representable
m = 2.0
jump = np.abs(1 + c - m)
assert np.count_nonzero(jump == 0) == 1 and c[jump == 0][0] == 1.0
# Endpoint: sqrt is continuous from the right at 0; there is no left side in the real domain.
h = np.logspace(-1, -12, 12)
assert np.all(np.diff(np.sqrt(h)) < 0) and np.sqrt(h[-1]) < 1e-5
with np.errstate(invalid="ignore"):
assert np.isnan(np.sqrt(-h)).all()Explore
Choose Elsewhere: a = −1 while the pieces still jump: the function is continuous at yet discontinuous at . Set and find the that joins the pieces. On f(1) undefined, notice that only condition 1 fails. On the endpoint preset, move to a negative number and read why the function is not defined there.
Common mistakes
A graph that “looks connected” at screen resolution can hide a missing or moved point. Continuity is a property at a point; one break does not make a function discontinuous everywhere, and one continuous point does not make it continuous everywhere. A function is not discontinuous at points outside its domain — it is simply not defined there; is continuous on its whole domain.
Numerical considerations
A floating-point test such as abs(f(a+h) - f(a)) < tol cannot certify continuity: a jump smaller than the tolerance passes, and steep continuous functions fail. The explorer uses exact one-sided limits of rational pieces; for sampled data, continuity is a modelling assumption, not something measurements prove.
Engineering and ML connections
Many algorithms assume continuity: bisection (finding a root between a sign change), interpolation, and gradient methods all rely on values that do not jump. Piecewise models — ReLU networks, decision thresholds, clipping — are continuous or discontinuous by design, and that choice affects whether small input changes can produce large output changes.
Exercises
Summary and checkpoints
Continuity at needs a value, a limit and their equality. Removable, jump, infinite and oscillating discontinuities fail in different ways. At an endpoint only one side counts. Next, III.3 asks a finer question about the same neighbourhood: how steeply does the function change there?