# Continuity of functions

Let $f\colon D\to\mathbb R,\ D\subseteq\mathbb R$ be a function of one variable, and $a\in D$ a point in its domain. The function is said to be continuous at $a$, if for any precision $\varepsilon>0$ the function is $\varepsilon$-constant (equal to its value $f(a)$) after restriction on a sufficiently short interval around $a$.

Formally, if we denote by $\bold I=\bold I^1$ the (open) interval, then the continuity means that $\forall \varepsilon>0\ \exists\delta>0\ f(a+\delta\bold I)\subseteq f(a)+\varepsilon\bold I$ (check that you understand the meaning of the notation $u+v\bold I$ for a subset of $\mathbb R$).

A function $f\colon D\to\mathbb R$ is said to be continuous on a subset $D'\subset D$, if it is continuous at all points $a\in D'$ of this subset. Usually we consider the cases where $D'=D$, that is, functions continuous on their domain of definition.

Remarks.
1. If $a$ is an isolated point of the domain $D$, then any function is automatically continuous at $a$ for a simple reason: for all sufficiently small $\delta>0$ the intersection $(a+\delta\bold I)\cap D$ consists of a single point $a$, so the image is a single point $f(a)$.

2. If $a\notin D$ but $\inf_{x\in D} |x-a|=0$ and there exists a limit $A=\lim_{x\to a}f(x)$, then one can extend $f$ on $a$ by letting $f(a)=A$ and obtain a function defined on $D\cup\{a\}$ which is continuous at $a$.

## Obvious properties of the continuity

The sum, difference and product of two functions continuous at a point $a$, is again continuous. The reciprocal of a continuous function $\frac1{f}$ is continuous at $a$, if $f(a)\ne 0$.

This is an obvious consequence of the rules of operations on “approximate numbers” (קירובים). When dealing with the sum/difference, one has to work with absolute approximations, when dealing with the product/ratio – with the relatice approximations, but ultimately it all boils down to the same argument: if two functions are almost constant on a sufficiently small interval around $a$, then application of the arithmetic operations is almost constant.

## Not-so-obvious property of continuity

When the continuity is compatible with transition to limit? More specifically, we consider the situation where there is an infinite number of functions $f_n\colon:D\to\mathbb R$ defined on the common domain $D$. Assume that for any $a\in D$ the values (numbers!) $f_n(a)\in\mathbb R$ form a converging sequence whose limit is denoted by $f_*(a)$ (it depends on $a$!). What can one say about the function $f_*\colon a\mapsto f_*(a)$?

Example.
Assume that $f_n(x)=x^n$ and $D=[0,1]$. All of them are continuous (why?). If $a<1$, then $\lim_{n\to\infty} a^n=0$. If $a=1$, then for any $n\ a^n=1$. Thus the limit $\lim_{n\to\infty}f_n(a)$ exists for all $a$, but as a function of $a\in[0,1]$ it is a discontinuous function. Thus without additional precautions a sequence of continuous functions can converge to a discontinuous one.

Distance between the functions.
The distance between real numbers $a,b\in\mathbb R$ is the nonnegative number $|a-b|$ which is zero if and only if $a=b$. Motivated by that, we introduce the distance $\|f-g\|$ between two functions $f,g\colon D\to \mathbb R$ as the expression $\sup_{a\in D}|f(a)-g(a)|$.

Exercise. Prove that any three functions $f,g,h$ defined on the common domain $D$, the “triangle inequality” $\|f-g\|\leqslant \|f-h\|+\|h-g\|$.

Definition. A sequence of functions $f_n\colon D\mathbb R$ is said to be uniformly converging to a function $f_*\colon D\to\mathbb R$, if $\lim_{n\to\infty}\|f_n-f_*\|=0$.

Theorem. If a sequence of continuous functions converges uniformly, then the limit is also a continuous function.

Indeed, denote by $g$ the limit function, $a\in D$ any point, and let $\varepsilon>0$ be any “resolution”. We need to construct a small interval around $a$ such that $g$ on this interval is $\varepsilon$-indistinguishable from the value $g(a)$. We split the resolution allowance into two halves. The first half we use to find $N$ such that $\|f_n-g\| < \frac\varepsilon2$ for all $n\ge N$. The second half we spend on the continuity: since $f_N$ is continuous, there exists a segment $a+\delta\bold I$ on which $f_N$ is $\frac\varepsilon2$-indistinguishable from $f_N(a)$. Collecting all inequalities we see that for any point $x\in a+\delta\bold I$ we have three inequalities: $|f_N(a)-g(a)|<\frac\varepsilon2, \ |f_N(x)-g(x)|<\frac\varepsilon2,\ |f_N(x)-g(x)|<\frac\varepsilon2$. By the triangle inequality, $|g(x)-g(a)|< \frac{3\varepsilon}2$. Ooops! we were heading for $\varepsilon$! One should rather divide our allowance into unequal parts, $\frac{2\varepsilon}3$ for the distance and $\frac\varepsilon3$ for the continuity of $f_N$ if we thought ahead of the computation! 😉 in any case, the outcome is the same.

# Curves

The notion of continuity, the distance between functions etc. can be generalized from functions of one variable to other classes of functions.

For instance, functions of the form $\gamma\colon [0,1]\to\mathbb R^2$ can be called (parametrized) curves. Here the argument $x\in[0,1]$ can be naturally associated with time, so the $\gamma(t)$ is the position of the moving point at the moment $t$. We can draw the image $\gamma([0,1])$: this drawing does not reflect the timing: to indicate it, we can additionally mark the images, say, $\gamma (\frac k{10}),\ k=0,1,\dots,10$.

To define continuity for curves, denote by $\bold I^2$ the unit square $\{|x|<1,\ |y|<1\}$. A curve $\gamma$ is continuous at a point $a\in [0,1]$ if $\forall\varepsilon >0 \ \exists \delta>0$ such that $\gamma (a+\delta\bold I^1)\subseteq \gamma(a)+\varepsilon \bold I^2$. (Do you understand this formula? 😉 )

The distance between two points $a=(a_1,a_2),\ b=(b_1,b_2)\in\mathbb R^2$ is usually defined as $\sqrt{(a_1-b_1)^2+(a_2-b_2)^2}$, but this difference is not very much different from the expression $|a-b|=\max_{i=1,2}|a_i-b_i|$ (this definition can be immediately generalized for spaces $\mathbb R^n$ of any finite dimension $n=3,4,\dots$. The distance between two curves has a very similar form: $\|f-g\|=\sup_{x\in [0,1]}|f(x)-g(x)|$.

Remark. If the functions $f,g$ are continuous, we can replace the supremum by maximum (which is always achieved).

# Koch snowflake revisited

Now we can return to one of the examples we discussed on Lecture 1, the Koch snowflake. In contrast with that time, we now have an appropriate language to deal with it.

The process of constructing the curve actually produces a sequence of closed curves. The image of the first curve is an equilateral triangular, the second one gives the Star of David, the third one has no canonical name.

In all cases the new curve $\gamma_{n+1}$ is obtained by taking the previous curve $\gamma_n$ and modifying it on a subset of its domain: instead of traversing a line segment with constant speed, one takes a middle third of this segment and forces $\gamma_{n+1}$ to detour. This requires increasing the speed, but we don’t care as long as the trajectory remains continuous. The distance between $\gamma_n$ and $\gamma_{n+1}$ is $\frac{\sqrt3}2$ times the size of the size of the segment $\frac1{3^n}$.

This observation guarantees that $\|\gamma_n-\gamma_{n+1}\|< C(1/3)^n$. This implies that the sequence of maps $\gamma_n\colon [0,1]\to\mathbb R^2$ converges uniformly. The result is continuous curve $\gamma_*\colon[0,1]\to\mathbb R^2$ which has "infinite length" (in fact, it has no length at all).

## Continuation of continuity

Let $f\colon [0,1]\times[\alpha,\beta]\to\mathbb R^2$ be a continuous function defined on the closed rectangle $[0,1]\times[\alpha,\beta]$. Then the functions $f_a(x)=f(x,a)$ are all defined on the segment $[0,1]$ and “converge” to $f_{a_*}(x)$ as $a\to a_*\in[\alpha,\beta]$. If $a_1,a_2,\dots, a_n,\dots$ is a sequence of values of $a$ converging to $a_*$, $\lim a_n=a_*$, then we have a sequence of functions $f_n=f_{a_n}\colon[-1,1]\to\mathbb R$, all defined on the same segment, which also “converges” to the limit $f_*=f_{a_*}$

The meaning of the “convergence of functions” is not yet defined.

Problem. Prove that in the above notations, for any point $x\in[0,1]$ the sequence of numbers $f_n(x)$ converges to the number $f_*(x)$. This type of convergence is called pointwise convergence (התכנסות נקודתית).

Example. Prove that the functions $f_n(x)=x^n,~n=1,2,\dots$, converge pointwise to a certain limit function $f_*\colon[0,1]\to\mathbb R$. Find this function.

Example. Let $\phi(x)=\frac1{1+x^2}$ be the function defined on the entire axis $\mathbb R$, and denote $f_n(x)=\phi(x-n)\colon\mathbb R\to\mathbb R$ (translation to the right by $n$). The same question: does a limit exist?

Formally, the pointwise convergence is defined by the following formula: $\lim f_n=f_*$, if $\forall x\in [0,1],~\forall \varepsilon >0,~\exists N=N(x,\varepsilon),~\forall n\ge N,~|f_n(x)-f_*(x)|<\varepsilon$. Clearly, this is the same as the formula

$\forall \varepsilon >0,~\forall x\in [0,1],~\exists N=N(x,\varepsilon),~\forall n\ge N,~|f_n(x)-f_*(x)|<\varepsilon.$

However, the “convergence” which comes from the continuity in two variables, is stronger.

Theorem. If $f(x,y)$ is a continuous function on the rectangle, as above, then for any $\varepsilon>0$ there exists a positive $\delta>0$ such that for any $a$ with $|a-a_*|<\delta$, the functions $f_a$ and $f_{a_*}$ differ at most by $\varepsilon$ on the entire segment $[0,1]$: $\forall x\in[0,1],~|f_a(x)-f_{a_*}(x)|<\varepsilon$.

Corollary. In the above notation, $f_n$ converges to $f_*$ “simultaneously” (uniformly, במידה שווה):

$\forall\varepsilon>0,~\exists N=N(\varepsilon):~\forall x\in[0,1],~\forall n\ge N,~|f_n(x)-f_*(x)|<\varepsilon.$

### Functions as “points” (vectors)

Continuous functions defined on the same interval, can be added, subtracted, multiplied by constants etc, which makes them similar to vectors in $\mathbb R^3$. We can also define the “distance” between the functions as follows, $d(f_1,f_2)=\max_{x\in[0,1]}|f_1(x)-f_2(x)|$. This number is always non-negative and finite:

1. $d(f_1,f_2)=0\iff f_1=f_2$;
2. $d(f_1,f_2)=d(f_2,f_1)$ (symmetry);
3. $d(f_1,f_3)\le d(f_1,f_2)+d(f_2,f_3)$ (the triangle inequality).

Proposition/Definition. The sequence of functions $\{f_n\}$ converges uniformly to $f_*$, if $d(f_n,f_*)\to0$.

Question. In which of the examples above the convergence is uniform?

### Can a limit of continuous functions be disconjugate?

A sequence of pointwise converging continuous functions may converge to a discontinuous function (see the first example above).

Theorem. The limit of uniformly converging on a closed sequence continuous functions is again continuous.

Example. The snowflake is a continuous closed curve of “infinite length”.

### Peano (plane-filling) curve

This is a continuous map $\gamma\colon [0,1]\to \mathbb R^2$ which fills completely (i.e., passes through each point of) the unit square. There are many examples of such curves, below is the example constructed by D. Hilbert. Giuseppe Peano was an Italian mathematician

### Sketch of the justification

In both cases the “malicious” curve is obtained as the limit of an infinite sequence of planar polygonal (hence continuous) curves $\gamma_n\colon [0,1]\to\mathbb R^2$. By construction, each next curve $\gamma_{n+1}$ differs from its predecessor $\gamma_n$ by an explicitly limited “modification”. In the example with the Peano curve, we subdivide the initial unit square into for small squares of the “first level” and draw the curve crossing each of the four squares in the specified order. Then each 1st level square is again subdivided into 4 tiny sub-squares of the “second level” and each segment of the curve is modified so as it (1) remains inside the same 1st level square, yet (2) crosses each of the four 2nd level squares as plotted. Hence the curve $\gamma_2$ differs from  the curve $\gamma_2$ by no more than $\sqrt 2$. In the same way $\|\gamma_3-\gamma_2\|\le \sqrt 2/2$$\|\gamma_4-\gamma_3\|\le \sqrt 2/2^2$ etc.

Thus it is clear that for any $t\in[0,1]$ the limit $\lim_{n\to\infty}\gamma_n(t)$ exists, and $|\gamma_n(t)-\gamma_*(t)|\le \sqrt{2}/2^{n-3}$. Thus the convergence of the functions is uniform, and therefore the limit is also a continuous function.

How to show that it indeed passes through each point of the unit square? Note that the curve $\gamma_n$ passes through centers of all squares of the $n$th level. Any point $a_*$ of the initial square can be approximated by centers of the squares of sufficiently high level. There exists an infinite sequence of points $a_n\in\gamma_n([0,1])$  which converges to $a_*$, i.e., the infinite sequence of moments $t_n\in[0,1]$ such that $\lim_{n\to\infty}\gamma_n(t_n)=a$. Passing to a subsequence if necessary, we can assume (since the segment [0,1] is compact) that the sequence $\{t_n\}$ converges to a limit $t_*$. One can easily check that because of the uniform continuity, $\gamma_*(t_*)=a_*$.

Problem. Write the detailed accurate exposition of this proof.

Blog at WordPress.com.