Real Function is Continuous at Point iff Oscillation is Zero

Theorem
Let $f$ be a real function defined on an open set.

Let $x$ be a point in the domain of $f$.

Let $\omega_f\left({x}\right)$ be the oscillation of $f$ at $x$, that is:


 * $\omega_f \left({x}\right) = \displaystyle \inf_I \left\{ \omega_f \left({I}\right): x \in I \right\}$

where every $I$ is taken to be an open interval, and:


 * $\omega_f \left({I}\right) = \displaystyle \sup_{y, z} \left\{{\vert f \left({y}\right) - f \left({z}\right) \vert: y, z \in I}\right\}$

Then $\omega_f \left({x}\right) = 0$ $f$ is continuous at $x$.

It is not strictly necessary for the intervals $I$ to be open, but $x$ must be a member of the open region of any interval $I$ (see below).

For simplicity, we have taken $I$ to be an open interval without loss of generality.

The point $x$ must be a member of the open region of any interval $I$ because without this requirement a discontinuous but right- or left-continuous point $x$ would have $\omega_f \left({x}\right)$ = 0.

Proof
Below, we take every interval $I$ to be open.

Necessary Condition
Suppose $\omega_f \left({x}\right) = 0$.

Let $\epsilon > 0$.

Suppose that $\forall I: x \in I, \omega_f \left({I} \right) \ge \epsilon$.

Then by definition, $\omega_f \left({x}\right) \ge \epsilon$.

This contradicts $\omega_f \left({x}\right) = 0$.

From this contradiction we deduce that:
 * $\exists I: x \in I, \omega_f \left({I}\right) < \epsilon$.

For this particular $I = (a,b)$, let $\delta \in \R$ such that:
 * $\delta = \min\left\{x-a, b-x\right\}$

$\delta > 0$ because $a < x < b$ by the openness of $I$.

So for our specific $x$, if $y$ satisfies:
 * $\left \vert {x - y} \right \vert < \delta$

then:
 * $y \in I$

and:
 * $\left \vert {f \left({x}\right) - f \left({y}\right)} \right \vert \leq \omega_f\left( I \right)$

Since $\omega_f\left( I \right) < \epsilon$ it follows by the definition of continuity that $f$ is continuous at $x$.

Sufficient Condition
Suppose $f$ is continuous at $x$.

Then $\forall \epsilon > 0: \exists \delta \in \R_{>0}$ such that:
 * $\left \vert x-y \right \vert < \delta \implies \left \vert f \left({x}\right)-f \left({y}\right) \right \vert < \epsilon$

Let the interval $I_\delta$ be defined as:
 * $I_\delta := \left({x - \delta \,.\,.\, x + \delta}\right)$

Recall that:


 * $\sup \left\{ {F} \right\} \le \sup \left\{ {G} \right\}$ if $F \le G$
 * $\sup \left\{ {F + G} \right\} \le \sup \left\{ {F} \right\} + \sup \left\{ {G} \right\}$ for any $F$, $G$

Then:

This gives:

This holds true for any value of $\epsilon$.

Thus $\omega_f \left({x}\right)$ must be $0$.

Hence the result.