Condition for Continuity on Interval

Theorem
Let $f$ be a real function defined on an interval $\mathbb I$.

Then $f$ is continuous on $\mathbb I$ iff:
 * $\forall x \in \mathbb I: \forall \epsilon > 0: \exists \delta > 0: y \in \mathbb I \wedge \left|{x - y}\right| < \delta \implies \left|{f \left({x}\right) - f \left({y}\right)}\right| < \epsilon$

Proof
Let $x \in \mathbb I$ such that $x$ is not an end point.

Then the condition $y \in \mathbb I \wedge \left|{x - y}\right| < \delta$ is the same as $\left|{x - y}\right| < \delta$ provided $\delta$ is small enough.

The criterion given therefore becomes the same as the statement $\displaystyle \lim_{y \to x} f \left({y}\right) = f \left({x}\right)$, that is, that $f$ is continuous at $x$.

Now suppose $x \in \mathbb I$ and $x$ is a left hand end point of $\mathbb I$.

Then the condition $y \in \mathbb I \wedge \left|{x - y}\right| < \delta$ reduces to $x \le y < x + \delta$ provided $\delta$ is small enough.

The criterion given therefore becomes the same as the statement $\displaystyle \lim_{y \to x^+} f \left({y}\right) = f \left({x}\right)$, that is, that $f$ is continuous on the right at $x$.

Similarly, if $x \in \mathbb I$ and $x$ is a left hand end point of $\mathbb I$, then the criterion reduces to the statement that $f$ is continuous on the left at $x$.

Thus the assertions are equivalent to the statement that $f$ is continuous at all points in $\mathbb I$, that is, that $f$ is continuous on $\mathbb I$.