Survey of Mathematics

4.5 Continuity between metric spaces

Replace the two absolute values in the epsilon-delta definition by two distances and you have continuity for maps between any metric spaces. It is the same as continuity along sequences, and the same as 'preimages of open sets are open', which needs no distance at all and is where topology begins. Several variables bring new failures (limits that depend on the path), and homeomorphisms say when two spaces have the same shape.

Taught in 375/376Beyond the courseRudin, Principles of Mathematical Analysis, ch. 4 (Thm 4.2, 4.8, 4.14 to 4.22)Abbott, Understanding Analysis, Sec. 4.2 to 4.3 and 3.2Apostol Vol. 2, Sec. 8.4 and 8.5Munkres, Topology, Sec. 18

The definition of continuity in 1.3 used the real line twice: once for the input, as the distance ∣x−a∣|x - a|, and once for the output, as ∣f(x)−f(a)∣|f(x) - f(a)|. Both are distances. The proofs used only the four properties of distance listed in 4.1, so the definition makes sense for a map from any metric space to any other: a map from the plane to the line, from the space of functions to the line (the integral), from bit strings to numbers. This chapter writes down that definition, proves it is the same as continuity along sequences, and then proves the surprising third form: a map is continuous exactly when preimages of open sets are open. The third form mentions no number ε\varepsilon or δ\delta and no distance, only open sets. That is the form topology (MATH 551) takes as the definition, and the reason 4.1 spent time on unions and finite intersections of open sets.

Before you start

1.3: continuity with ε\varepsilon and δ\delta and the order of the quantifiers. 4.1: open sets, balls, and that balls are open. 4.2: convergent sequences in a metric space. 4.3 and 4.4: compact and connected sets, which continuity preserves.

Quick checkIn the definition of continuity at aa, who chooses δ\delta and when?
Quick checkIs (1,4)∪(6,7)(1, 4) \cup (6, 7) an open subset of R\mathbb R?
Quick checkIn a metric space, what does xn→xx_n \to x mean?

The picture: preimages of open intervals

A map ff takes inputs to outputs. An open interval VV on the output axis is a region with room around each of its points. The set of all inputs that land in VV is the preimage of VV, drawn in orange on the input axis. Three things to do:

  1. Start with f(x)=x2f(x) = x^2 and slide the centre and radius of VV. The preimage is always one or two open intervals, never including an endpoint. An endpoint would be sent to the edge of VV, and VV has no edge points.
  2. Switch to the jump function and put VV around 11 only. The preimage is [0,∞)[0, \infty), which contains 00. But 00 has no room on its left. The jump has torn the line, and the preimage fails to be open.
  3. Put VV around −1-1 only. Now the preimage is (−∞,0)(-\infty, 0), open. A discontinuous function can have some good preimages. Continuity means ALL open sets have open preimages, and one bad VV is enough to fail.
Where this came from· Lipschitz, and a definition without numbers

In the 1800s Augustin-Louis Cauchy proved that the equation y′=f(x,y)y' = f(x, y) with a starting value has a solution, and Rudolf Lipschitz later isolated the condition on ff that makes the solution unique: the output changes by at most a fixed multiple of the change in yy. That condition, now called a Lipschitz condition, is a quantitative form of continuity, and the multiplier is the contraction constant that 4.2 used to prove the existence theorem. Separately, Felix Hausdorff’s 1914 book defined spaces by open sets alone, with no distance. In a space like that the ε\varepsilon-δ\delta definition is unavailable, and the only way to say that a map does not tear the space is that preimages of open sets are open. For metric spaces the two definitions agree, which is the first theorem below. The problem both solved was to say what continuous means without relying on the real line.

The idea, in words

Why· Three ways to say 'the map does not tear'
  1. With numbers (ε\varepsilon-δ\delta). Points that are close go to points that are close, with a recipe for how close. You can compute with this.
  2. With sequences. If a sequence of inputs converges to aa, the outputs converge to f(a)f(a). You can test with this: one bad sequence disproves continuity.
  3. With open sets. If you fence off an open region in the output, the inputs that land in it form an open region. You can prove with this: it works cleanly with unions, intersections and composition, and needs no distance.

The theorem of this chapter says the three are the same property. The first is the one you reach for to find a δ\delta. The second is the one that disproves continuity quickly. The third is the one that will carry over to spaces that have open sets and no distance.

Definitions and theorems

Definition B

Limit of a map between metric spaces

Let (X,dX)(X, d_X) and (Y,dY)(Y, d_Y) be metric spaces, A⊆XA \subseteq X, f:A→Yf : A \to Y, and let aa be a limit point of AA (a point of XX, which may or may not be in AA). Then L∈YL \in Y is the limit of ff as x→ax \to a, written lim⁡x→af(x)=L\lim_{x \to a} f(x) = L, if

∀ε>0  ∃δ>0  ∀x∈A:0<dX(x,a)<δ  ⟹  dY(f(x),L)<ε.\forall \varepsilon > 0\ \ \exists \delta > 0\ \ \forall x \in A:\quad 0 < d_X(x, a) < \delta \implies d_Y(f(x), L) < \varepsilon.

The condition 0<dX(x,a)0 < d_X(x, a) excludes x=ax = a, as in 1.3. Taking X=Y=RX = Y = \mathbb R recovers that definition.

In one linelim⁡x→af(x)=L\lim_{x \to a} f(x) = L if for every ε>0\varepsilon > 0 there is δ>0\delta > 0 such that dY(f(x),L)<εd_Y(f(x), L) < \varepsilon whenever 0<dX(x,a)<δ0 < d_X(x, a) < \delta.

Why it existsIt is the limit of 1.3 with ∣x−a∣|x - a| and ∣f(x)−L∣|f(x) - L| replaced by the distances of the two spaces, so it makes sense for maps from vectors, functions or bit strings.

Definition B

Continuous map between metric spaces

A map f:X→Yf : X \to Y between metric spaces is continuous at a∈Xa \in X if

∀ε>0  ∃δ>0  ∀x∈X:dX(x,a)<δ  ⟹  dY(f(x),f(a))<ε.\forall \varepsilon > 0\ \ \exists \delta > 0\ \ \forall x \in X:\quad d_X(x, a) < \delta \implies d_Y(f(x), f(a)) < \varepsilon.

It is continuous if it is continuous at every point of XX. In words of balls: for every ball BY(f(a),ε)B_Y(f(a), \varepsilon) there is a ball BX(a,δ)B_X(a, \delta) that ff sends inside it.

In one linef:X→Yf : X \to Y is continuous at aa if for every ε>0\varepsilon > 0 there is δ>0\delta > 0 such that dY(f(x),f(a))<εd_Y(f(x), f(a)) < \varepsilon whenever dX(x,a)<δd_X(x, a) < \delta; it is continuous if it is continuous at every point.

Why it existsIt says nearby inputs have nearby outputs, in whatever way each space measures nearness.

If aa is a limit point of XX, then ff is continuous at aa exactly when lim⁡x→af(x)=f(a)\lim_{x \to a} f(x) = f(a), as in 1.3. If aa is an isolated point (a ball B(a,δ)B(a, \delta) holds no other point of XX), continuity at aa is automatic: with that δ\delta the only xx allowed is aa itself. In particular every map out of a discrete metric space is continuous.

Theorem B Rudin Thm 4.2 and 4.8; Abbott Thm 4.3.2; Munkres Thm 18.1

Three faces of continuity

For a map f:X→Yf : X \to Y between metric spaces, the following are equivalent.

(a) ff is continuous (ε\varepsilon-δ\delta) at every point.

(b) For every a∈Xa \in X and every sequence xn→ax_n \to a in XX, f(xn)→f(a)f(x_n) \to f(a) in YY.

(c) For every open set W⊆YW \subseteq Y, the preimage f−1(W)f^{-1}(W) is open in XX.

(d) For every closed set F⊆YF \subseteq Y, the preimage f−1(F)f^{-1}(F) is closed in XX.

In one lineFor f:X→Yf : X \to Y between metric spaces: ff is continuous (with ε\varepsilon and δ\delta) iff xn→ax_n \to a implies f(xn)→f(a)f(x_n) \to f(a) iff the preimage of every open set is open iff the preimage of every closed set is closed.

Why it is trueSequences and numbers are linked by taking δ=1/n\delta = 1/n; numbers and open sets by replacing a ball in the target by a ball in the source; open and closed by taking complements.

ProofRudin 4.8; Munkres 18.1
The idea: (a)⇒(b) and (b)⇒(a): the sequential criterion of 1.3, with distances. (a)⇒(c): a ball around f(a) inside W pulls back to a ball around a. (c)⇒(a): apply (c) to the ball B(f(a), ε), which is open. (c)⇔(d): complements.
Assume (a). Let xn→ax_n \to a and ε>0\varepsilon > 0. Choose δ>0\delta > 0 with dY(f(x),f(a))<εd_Y(f(x), f(a)) < \varepsilon whenever dX(x,a)<δd_X(x, a) < \delta.
(a) ⇒ (b). Continuity at aa gives a δ\delta for each ε\varepsilon.
Choose NN with dX(xn,a)<δd_X(x_n, a) < \delta for n>Nn > N. Then dY(f(xn),f(a))<εd_Y(f(x_n), f(a)) < \varepsilon for n>Nn > N, so f(xn)→f(a)f(x_n) \to f(a).
xn→ax_n \to a with tolerance δ\delta.
Suppose ff is not continuous at aa. There is ε>0\varepsilon > 0 such that for every δ>0\delta > 0 some xx has dX(x,a)<δd_X(x, a) < \delta and dY(f(x),f(a))≥εd_Y(f(x), f(a)) \ge \varepsilon.
(b) ⇒ (a), by contrapositive. Negate the definition of continuity at aa: there is some ε>0\varepsilon > 0 that no δ\delta answers.
Choose xnx_n with dX(xn,a)<1nd_X(x_n, a) < \frac1n and dY(f(xn),f(a))≥εd_Y(f(x_n), f(a)) \ge \varepsilon. Then xn→ax_n \to a but f(xn)↛f(a)f(x_n) \not\to f(a), so (b) fails.
Use δ=1n\delta = \frac1n for each nn and pick the bad point xnx_n.
Assume (a). Choose ε>0\varepsilon > 0 with BY(f(a),ε)⊆WB_Y(f(a), \varepsilon) \subseteq W, then δ>0\delta > 0 from continuity at aa.
(a) ⇒ (c). Take WW open in YY and a point a∈f−1(W)a \in f^{-1}(W). Then f(a)∈Wf(a) \in W and WW is open, so a ball around f(a)f(a) lies in WW.
So BX(a,δ)⊆f−1(W)B_X(a, \delta) \subseteq f^{-1}(W). Every point of f−1(W)f^{-1}(W) has a ball inside it: f−1(W)f^{-1}(W) is open.
If dX(x,a)<δd_X(x, a) < \delta then dY(f(x),f(a))<εd_Y(f(x), f(a)) < \varepsilon, so f(x)∈Wf(x) \in W.
Assume (c). The preimage f−1(BY(f(a),ε))f^{-1}(B_Y(f(a), \varepsilon)) is open in XX and contains aa.
(c) ⇒ (a). Fix aa and ε>0\varepsilon > 0. The ball BY(f(a),ε)B_Y(f(a), \varepsilon) is open (4.1: open balls are open).
So there is δ>0\delta > 0 with BX(a,δ)⊆f−1(BY(f(a),ε))B_X(a, \delta) \subseteq f^{-1}(B_Y(f(a), \varepsilon)). That says dX(x,a)<δd_X(x, a) < \delta implies dY(f(x),f(a))<εd_Y(f(x), f(a)) < \varepsilon: (a) holds.
Definition of open: some ball around aa lies inside it.
So f−1(Y∖F)=X∖f−1(F)f^{-1}(Y \setminus F) = X \setminus f^{-1}(F).
(c) ⇔ (d). For any set F⊆YF \subseteq Y, a point xx is in f−1(Y∖F)f^{-1}(Y \setminus F) iff f(x)∉Ff(x) \notin F iff x∉f−1(F)x \notin f^{-1}(F).
Hence (c) and (d) are equivalent. ■\blacksquare
A set is closed iff its complement is open. If (c) holds and FF is closed, Y∖FY \setminus F is open, so f−1(Y∖F)f^{-1}(Y \setminus F) is open, so its complement f−1(F)f^{-1}(F) is closed. Conversely, the same with open and closed swapped.

In the picture: (a) is the window of inputs in the first visualizer, (c) is the orange set with its open ends. For the jump function with VV around 11, the orange set is [0,∞)[0, \infty), so (c) fails, and (b) fails too: the sequence xn=−1n→0x_n = -\frac1n \to 0 has f(xn)=−1f(x_n) = -1, not tending to f(0)=1f(0) = 1.

Proof workshopRebuild (c) implies (a): open preimages give epsilon-delta

Tap the lines in the order a proof would write them. Each line can only use what is already above it.

    Worked example
    Show that if f:R→Rf : \mathbb R \to \mathbb R is continuous and f(q)=0f(q) = 0 for every rational qq, then f(x)=0f(x) = 0 for every real xx.

    Solution.

    1. Take any real xx. We must show f(x)=0f(x) = 0. We know ff only on the rationals, so we reach xx through them.
    2. Approach xx by rationals. Choose rationals qnq_n with ∣qn−x∣<1n|q_n - x| < \frac1n. Then qn→xq_n \to x. Every interval contains a rational number (density of Q\mathbb Q).
    3. Use the sequence form of continuity. By form (b) of the three-faces theorem, f(qn)→f(x)f(q_n) \to f(x). Continuity at xx sends convergent sequences to convergent sequences.
    4. Read off the limit. Every f(qn)=0f(q_n) = 0, so the sequence f(qn)f(q_n) is constantly 00, and its limit is 00. Limits are unique, so f(x)=0f(x) = 0. A constant sequence converges to that constant, and a sequence has only one limit (4.2).

    Answer. ff is zero everywhere. The same argument shows that two continuous functions that agree on a dense set agree everywhere. ■\blacksquare

    Quick checkLet f(x)=x2f(x) = x^2 as a map R→R\mathbb R \to \mathbb R. Which of these sets is NOT open?
    Theorem B Rudin Thm 4.7 and 4.9, 4.10; Apostol Sec. 8.4 to 8.5; MATH 375 Lecture 19

    Building continuous maps

    (a) If f:X→Yf : X \to Y and g:Y→Zg : Y \to Z are continuous, so is g∘fg \circ f.

    (b) If f,g:X→Rf, g : X \to \mathbb R are continuous and c∈Rc \in \mathbb R, then f+gf + g, cfcf and fgfg are continuous, and f/gf/g is continuous on the set where g≠0g \ne 0.

    (c) A map F=(F1,…,Fm):X→RmF = (F_1, \dots, F_m) : X \to \mathbb R^m is continuous iff each Fi:X→RF_i : X \to \mathbb R is. The projection πi:Rn→R\pi_i : \mathbb R^n \to \mathbb R, πi(x)=xi\pi_i(x) = x_i, is continuous.

    In one lineCompositions of continuous maps are continuous; sums, multiples, products and quotients (with non-zero denominator) of continuous real functions are continuous; a map into Rm\mathbb R^m is continuous iff each of its mm coordinate functions is; coordinate projections are continuous.

    Why it is trueComposition: preimages of open sets pull back twice. Algebra: pass through sequences and use the limit laws of 1.2. Coordinates: convergence in Rm\mathbb R^m is coordinatewise (4.2).

    ProofRudin 4.7 to 4.10
    The idea: (a) with open sets. (b) with sequences, since 1.2 proved the limit laws. (c) with sequences, since convergence in R^m is coordinatewise.
    (a) (g∘f)−1(W)=f−1(g−1(W))(g \circ f)^{-1}(W) = f^{-1}(g^{-1}(W)).
    Use form (c) of the previous theorem. For WW open in ZZ, g−1(W)g^{-1}(W) is open in YY because gg is continuous.
    Hence g∘fg \circ f is continuous. Compare the ε\varepsilon-δ\delta proof, which needs two nested choices of δ\delta.
    Then f−1f^{-1} of that open set is open in XX because ff is continuous. So the preimage of every open WW is open.
    By the algebraic limit laws of 1.2, f(xn)+g(xn)→f(a)+g(a)f(x_n) + g(x_n) \to f(a) + g(a), cf(xn)→cf(a)c f(x_n) \to c f(a) and f(xn)g(xn)→f(a)g(a)f(x_n)g(x_n) \to f(a)g(a).
    (b) Let xn→ax_n \to a in XX. By form (b) of the previous theorem, f(xn)→f(a)f(x_n) \to f(a) and g(xn)→g(a)g(x_n) \to g(a).
    The same for f(xn)/g(xn)→f(a)/g(a)f(x_n)/g(x_n) \to f(a)/g(a) when g(a)≠0g(a) \ne 0. By form (b) again, the sums, products and quotients are continuous.
    The quotient law of 1.2 requires g(a)≠0g(a) \ne 0 and then g(xn)≠0g(x_n) \ne 0 eventually; on the set {g≠0}\{g \ne 0\} we use that set as the space.
    So FF satisfies (b) of the previous theorem iff each FiF_i does.
    (c) By the coordinatewise theorem of 4.2, F(xn)→F(a)F(x_n) \to F(a) in Rm\mathbb R^m iff Fi(xn)→Fi(a)F_i(x_n) \to F_i(a) for every ii.
    The projection πi\pi_i is continuous. ■\blacksquare
    ∣πi(x)−πi(y)∣=∣xi−yi∣≤∥x−y∥∞≤∥x−y∥2|\pi_i(x) - \pi_i(y)| = |x_i - y_i| \le \lVert x - y \rVert_\infty \le \lVert x - y \rVert_2 (the comparison theorem of 4.1), so δ=ε\delta = \varepsilon works.

    Together these say: every polynomial in the coordinates is continuous on Rn\mathbb R^n (built from projections, sums and products), every rational function is continuous where its denominator is non-zero, and every composition of such with sin⁡\sin, exp⁡\exp, log⁡\log and the other functions of 1.3 is continuous on the set where it is defined. In JEE you “knew” this. Here it is a theorem with a proof.

    Worked example MATH 375 HW 11 (Apostol 8.5 #1 b, f, j)
    Find the set where each function is continuous: (a) log⁡(x2+y2)\log(x^2 + y^2). (b) arcsin⁡xx2+y2\arcsin\dfrac{x}{\sqrt{x^2 + y^2}}. (c) arccos⁡x/y\arccos\sqrt{x/y}.

    Solution.

    1. (a) Find the domain, then compose. x2+y2x^2 + y^2 is a polynomial, continuous everywhere, and positive except at the origin. log⁡\log is continuous on (0,∞)(0, \infty). By the composition rule, log⁡(x2+y2)\log(x^2 + y^2) is continuous at every point where it is defined, the set R2∖{(0,0)}\mathbb R^2 \setminus \{(0, 0)\}.
    2. (b) The inner function. u(x,y)=x/x2+y2u(x, y) = x/\sqrt{x^2 + y^2} is a quotient of continuous functions with non-zero denominator, so it is continuous on R2∖{(0,0)}\mathbb R^2 \setminus \{(0, 0)\}. Its values satisfy ∣u∣≤1|u| \le 1 because ∣x∣≤x2+y2|x| \le \sqrt{x^2 + y^2}. The domain of the whole function is where the inner function is defined, which is everywhere except the origin; arcsin⁡\arcsin needs its input in [−1,1][-1, 1], and that always holds.
    3. (b) The outer function. arcsin⁡\arcsin is continuous on the CLOSED interval [−1,1][-1, 1], including the endpoints ±1\pm 1. So the composite is continuous at every point except the origin, including the points (x,0)(x, 0) with x≠0x \ne 0, where u=±1u = \pm 1 and the value is ±π2\pm\frac\pi2. A tempting answer, “discontinuous along y=0y = 0”, is wrong: arcsin⁡\arcsin has no jump at ±1\pm 1.
    4. (c) The domain. x/y\sqrt{x/y} needs y≠0y \ne 0 and x/y≥0x/y \ge 0, and arccos⁡\arccos needs x/y≤1\sqrt{x/y} \le 1, that is x/y≤1x/y \le 1. So the domain is {y≠0, 0≤x/y≤1}\{y \ne 0,\ 0 \le x/y \le 1\}. We find where the function is defined before asking where it is continuous.
    5. (c) Continuity on the domain. x/yx/y is continuous for y≠0y \ne 0;  \sqrt{\ } is continuous on [0,∞)[0, \infty); arccos⁡\arccos is continuous on [−1,1][-1, 1]. So the function is continuous at every point of its domain, including the boundary cases x=0x = 0 and x=yx = y. Again the outer functions are continuous on closed intervals, so no extra points are lost.

    Answer. (a) Continuous on R2∖{0}\mathbb R^2 \setminus \{0\}, its whole domain. (b) Continuous on R2∖{0}\mathbb R^2 \setminus \{0\}, its whole domain. (c) Continuous on its whole domain {y≠0, 0≤x/y≤1}\{y \ne 0,\ 0 \le x/y \le 1\}. ■\blacksquare

    Worked example MATH 375 HW 11 (Apostol 8.3 #1c, #2m)
    Show that S={(x,y):(x2+y2−1)(4−x2−y2)>0}S = \{(x, y) : (x^2 + y^2 - 1)(4 - x^2 - y^2) > 0\} is open, and describe it. Show that each level set {(x,y):cos⁡(x+y)=c}\{(x, y) : \cos(x + y) = c\} is closed.

    Solution.

    1. Write SS as a preimage. Let F(x,y)=(x2+y2−1)(4−x2−y2)F(x, y) = (x^2 + y^2 - 1)(4 - x^2 - y^2), a polynomial, so continuous on R2\mathbb R^2. Then S=F−1((0,∞))S = F^{-1}((0, \infty)). SS is the set of inputs whose output lies in the open interval (0,∞)(0, \infty).
    2. Apply the theorem. (0,∞)(0, \infty) is open in R\mathbb R, so SS is open in R2\mathbb R^2 by form (c). This replaces a ball-by-ball argument at every point of SS.
    3. Describe SS. A product is positive when both factors are positive or both negative. Both positive: x2+y2>1x^2 + y^2 > 1 and x2+y2<4x^2 + y^2 < 4, that is 1<r<21 < r < 2 with rr the distance from the origin. Both negative: x2+y2<1x^2 + y^2 < 1 and x2+y2>4x^2 + y^2 > 4, impossible. So SS is the open annulus between the circles of radius 11 and 22 about the origin. (The posted key sketched two overlapping discs of unequal size, which does not match this FF.)
    4. The boundary. ∂S\partial S is the two circles r=1r = 1 and r=2r = 2, where F=0F = 0. Points where F=0F = 0 are in the closure of SS but not in SS.
    5. Level sets. g(x,y)=cos⁡(x+y)g(x, y) = \cos(x + y) is continuous, and {c}\{c\} is closed in R\mathbb R, so g−1({c})g^{-1}(\{c\}) is closed by form (d). Since cos⁡(x+y)\cos(x + y) depends only on x+yx + y, the level set is a family of parallel lines x+y=constantx + y = \text{constant} of slope −1-1, for example x+y=π2+mπx + y = \frac\pi2 + m\pi for c=0c = 0.

    Answer. SS is the open annulus 1<x2+y2<41 < x^2 + y^2 < 4, which is open, with boundary the two circles. Every level set of cos⁡(x+y)\cos(x + y) is closed (a family of parallel lines). ■\blacksquare The rule: a set defined by strict inequalities between continuous functions is open, and by non-strict inequalities or equations is closed.

    Worked example MATH 375 Lecture 19; Apostol 8.3
    Show that a product of open sets is open: if A1,A2⊆RA_1, A_2 \subseteq \mathbb R are open, so is A1×A2⊆R2A_1 \times A_2 \subseteq \mathbb R^2.

    Solution.

    1. Write the product with projections. A1×A2=π1−1(A1)∩π2−1(A2)A_1 \times A_2 = \pi_1^{-1}(A_1) \cap \pi_2^{-1}(A_2). A point (x,y)(x, y) is in the product iff x∈A1x \in A_1 and y∈A2y \in A_2, which is the same as π1(x,y)∈A1\pi_1(x, y) \in A_1 and π2(x,y)∈A2\pi_2(x, y) \in A_2.
    2. Each piece is open. The projections are continuous, and A1A_1, A2A_2 are open, so π1−1(A1)\pi_1^{-1}(A_1) and π2−1(A2)\pi_2^{-1}(A_2) are open (form (c)). These are strips: A1×RA_1 \times \mathbb R and R×A2\mathbb R \times A_2.
    3. A finite intersection of open sets is open. So A1×A2A_1 \times A_2 is open. The theorem of 4.1.

    Answer. A1×A2A_1 \times A_2 is open. ■\blacksquare The proof in Spagnolie’s lecture gets the same result by hand: take r1,r2r_1, r_2 with Br1(a1)⊆A1B_{r_1}(a_1) \subseteq A_1 and Br2(a2)⊆A2B_{r_2}(a_2) \subseteq A_2, let r=min⁡(r1,r2)r = \min(r_1, r_2); a point of the disc Br(a)B_r(a) has ∣x−a1∣<r≤r1|x - a_1| < r \le r_1 and ∣y−a2∣<r≤r2|y - a_2| < r \le r_2, so it is in A1×A2A_1 \times A_2. The minimum is the finite-intersection step of 4.1 again.

    Lipschitz maps

    Definition B

    Lipschitz map

    A map f:X→Yf : X \to Y between metric spaces is Lipschitz if there is a constant L≥0L \ge 0 with dY(f(x),f(y))≤L dX(x,y)d_Y(f(x), f(y)) \le L\,d_X(x, y) for all x,y∈Xx, y \in X. The smallest such LL is the Lipschitz constant of ff. A Lipschitz map with L<1L < 1 is a contraction in the sense of 4.2.

    In one linef:X→Yf : X \to Y is Lipschitz with constant LL if dY(f(x),f(y))≤L dX(x,y)d_Y(f(x), f(y)) \le L\,d_X(x, y) for all x,yx, y: the output distance is at most LL times the input distance.

    Why it existsIt is continuity with an explicit recipe, δ=ε/L\delta = \varepsilon / L, valid at every point at once.

    Theorem B standard

    Lipschitz implies uniformly continuous

    If f:X→Yf : X \to Y is Lipschitz with constant LL, then ff is uniformly continuous: for every ε>0\varepsilon > 0, δ=ε/(L+1)\delta = \varepsilon / (L + 1) satisfies dX(x,y)<δ  ⟹  dY(f(x),f(y))<εd_X(x, y) < \delta \implies d_Y(f(x), f(y)) < \varepsilon for all x,yx, y.

    In one lineA Lipschitz map is uniformly continuous, hence continuous.

    Why it is trueIf distances are multiplied by at most LL, the tolerance δ=ε/L\delta = \varepsilon / L works at every point of the space.

    Proofstandard
    The idea: Multiply the input distance by L; choose δ so the result is below ε. The +1 only avoids dividing by zero when L = 0.
    Let ε>0\varepsilon > 0 and δ=ε/(L+1)\delta = \varepsilon / (L + 1).
    Arbitrary tolerance; δ\delta depends on ε\varepsilon and LL but not on xx or yy.
    If dX(x,y)<δd_X(x, y) < \delta then dY(f(x),f(y))≤L dX(x,y)≤Lδ<εd_Y(f(x), f(y)) \le L\,d_X(x, y) \le L\delta < \varepsilon. ■\blacksquare
    The Lipschitz inequality, then δ(L)<ε\delta (L) < \varepsilon since L/(L+1)<1L/(L+1) < 1.
    Worked example links to 3.5
    Norms, projections and distance-from-a-point are 1-Lipschitz; a matrix is Lipschitz with constant its operator norm. For A=[3045]A = \begin{bmatrix} 3 & 0 \\ 4 & 5 \end{bmatrix} find the constant and a δ\delta for ε=0.1\varepsilon = 0.1.

    Solution.

    1. A norm. By the triangle inequality ∥x∥≤∥x−y∥+∥y∥\lVert x \rVert \le \lVert x - y \rVert + \lVert y \rVert, so ∥x∥−∥y∥≤∥x−y∥\lVert x \rVert - \lVert y \rVert \le \lVert x - y \rVert; swapping xx and yy gives ∣∥x∥−∥y∥∣≤∥x−y∥|\lVert x \rVert - \lVert y \rVert| \le \lVert x - y \rVert. This reverse triangle inequality says the norm, as a map V→RV \to \mathbb R, is Lipschitz with L=1L = 1.
    2. The same for distance from a point. For fixed pp, h(x)=d(x,p)h(x) = d(x, p) has ∣h(x)−h(y)∣≤d(x,y)|h(x) - h(y)| \le d(x, y). The reverse triangle inequality of 4.1: d(x,p)≤d(x,y)+d(y,p)d(x, p) \le d(x, y) + d(y, p), and symmetric.
    3. A projection. ∣πi(x)−πi(y)∣=∣xi−yi∣≤∥x−y∥2|\pi_i(x) - \pi_i(y)| = |x_i - y_i| \le \lVert x - y \rVert_2. One coordinate is at most the 2-norm (4.1).
    4. A matrix. For T(x)=AxT(x) = Ax on R2\mathbb R^2 with the usual length, ∥Ax−Ay∥=∥A(x−y)∥≤∥A∥ ∥x−y∥\lVert Ax - Ay \rVert = \lVert A(x - y) \rVert \le \lVert A \rVert\,\lVert x - y \rVert. The defining property of the operator norm of 3.5, applied to the vector x−yx - y and the linearity of AA.
    5. Compute ∥A∥\lVert A \rVert. ATA=[25202025]A^{\mathsf T}A = \begin{bmatrix} 25 & 20 \\ 20 & 25 \end{bmatrix} has eigenvalues 4545 and 55, so σ1=45=35≈6.708\sigma_1 = \sqrt{45} = 3\sqrt5 \approx 6.708. The operator norm is the largest singular value, the square root of the largest eigenvalue of ATAA^{\mathsf T}A.
    6. Find δ\delta. δ=ε/∥A∥=0.1/6.708≈0.0149\delta = \varepsilon / \lVert A \rVert = 0.1 / 6.708 \approx 0.0149. Then ∥x−y∥<δ\lVert x - y \rVert < \delta gives ∥Ax−Ay∥<∥A∥δ=0.1\lVert Ax - Ay \rVert < \lVert A \rVert \delta = 0.1, at every pair of points at once.

    Answer. L=35L = 3\sqrt5 and δ≈0.0149\delta \approx 0.0149 work for the whole plane. ■\blacksquare

    Your answerWhat is the Lipschitz constant (operator norm) of T(x)=AxT(x) = Ax for A=[3045]A = \begin{bmatrix} 3 & 0 \\ 4 & 5 \end{bmatrix} with the usual length? (Give a decimal.)
    Quick checkWhich of these maps R→R\mathbb R \to \mathbb R is NOT Lipschitz?

    Uniform continuity between metric spaces

    Uniform continuity was defined in 1.3 for functions on the line. The same definition, with distances, makes sense for maps between metric spaces. We do not define a new term; we state the general version and its main facts.

    Theorem B Rudin Thm 4.19 and Ex. 4.13; Abbott Sec. 4.4; standard

    Uniform continuity between metric spaces

    Let f:X→Yf : X \to Y be a map between metric spaces. It is uniformly continuous if

    ∀ε>0  ∃δ>0  ∀x,y∈X:dX(x,y)<δ  ⟹  dY(f(x),f(y))<ε.\forall \varepsilon > 0\ \ \exists \delta > 0\ \ \forall x, y \in X:\quad d_X(x, y) < \delta \implies d_Y(f(x), f(y)) < \varepsilon.

    Then:

    (a) Lipschitz implies uniformly continuous, and uniformly continuous implies continuous.

    (b) If (xn)(x_n) is Cauchy in XX and ff is uniformly continuous, then (f(xn))(f(x_n)) is Cauchy in YY.

    (c) If XX is compact and ff is continuous, then ff is uniformly continuous (4.3).

    In one lineA map f:X→Yf : X \to Y is uniformly continuous when for every ε>0\varepsilon > 0 one δ>0\delta > 0 works for all pairs of points. Lipschitz maps are uniformly continuous; uniformly continuous maps are continuous and send Cauchy sequences to Cauchy sequences; a continuous map on a compact space is uniformly continuous.

    Why it is trueA single δ\delta lets two points that are close in XX have close images, and 'close to each other' is exactly what a Cauchy sequence says; continuity at one point gives no such statement about two moving points.

    ProofRudin 4.19
    The idea: (a) The first part is the previous theorem; the second takes y = a in the definition. (b) Feed the uniform δ to the Cauchy condition. (c) is proved in 4.3.
    (a) Uniformly continuous implies continuous at every aa, with the same δ\delta. Lipschitz implies uniformly continuous by the previous theorem.
    Put y=ay = a in the definition: the δ\delta that works for all pairs works in particular for the pairs (x,a)(x, a).
    There is NN with dX(xm,xn)<δd_X(x_m, x_n) < \delta for all m,n>Nm, n > N, because (xn)(x_n) is Cauchy.
    (b) Let ε>0\varepsilon > 0 and take the δ\delta from uniform continuity.
    So dY(f(xm),f(xn))<εd_Y(f(x_m), f(x_n)) < \varepsilon for m,n>Nm, n > N: (f(xn))(f(x_n)) is Cauchy.
    Uniform continuity applied to the pair (xm,xn)(x_m, x_n).
    (c) is the theorem “Continuous on a compact set implies uniformly continuous”. ■\blacksquare
    (c) Proved in 4.3 with the Lebesgue number.

    Part (b) gives a quick way to see that a continuous map is not uniformly continuous. The function f(x)=1xf(x) = \frac1x on (0,1](0, 1] is continuous. The sequence xn=1nx_n = \frac1n is Cauchy in (0,1](0, 1], but f(xn)=nf(x_n) = n is not Cauchy. So ff is not uniformly continuous, matching the example in 1.3 by a different route.

    Worked example
    Show that f(x)=xf(x) = \sqrt x is uniformly continuous on [0,∞)[0, \infty) but not Lipschitz there.

    Solution.

    1. A key inequality. For x≥y≥0x \ge y \ge 0, (x−y)2≤(x−y)(x+y)=x−y(\sqrt x - \sqrt y)^2 \le (\sqrt x - \sqrt y)(\sqrt x + \sqrt y) = x - y. So ∣x−y∣≤∣x−y∣|\sqrt x - \sqrt y| \le \sqrt{|x - y|}. The first step holds because 0≤x−y≤x+y0 \le \sqrt x - \sqrt y \le \sqrt x + \sqrt y. The product of the two brackets is the difference of squares.
    2. Choose δ\delta. Given ε>0\varepsilon > 0, take δ=ε2\delta = \varepsilon^2. If ∣x−y∣<δ|x - y| < \delta then ∣x−y∣<δ=ε|\sqrt x - \sqrt y| < \sqrt\delta = \varepsilon. The same δ\delta works for every pair, which is uniform continuity.
    3. Suppose it were Lipschitz. Then ∣x−0∣≤L ∣x−0∣|\sqrt x - \sqrt 0| \le L\,|x - 0| for some L>0L > 0 and all x≥0x \ge 0, that is x≤Lx\sqrt x \le Lx, so 1≤Lx1 \le L\sqrt x for x>0x > 0. Divide by x\sqrt x.
    4. Contradiction. For 0<x<1L20 < x < \frac1{L^2} we get Lx<1L\sqrt x < 1. So no constant LL works near 00, where the graph is vertical.

    Answer. x\sqrt x is uniformly continuous but not Lipschitz. So the arrow Lipschitz ⇒\Rightarrow uniformly continuous cannot be reversed. ■\blacksquare

    Beyond the course: for understanding· Extending a uniformly continuous map to the closure (B)

    Suppose DD is a dense subset of a metric space XX (every ball of XX meets DD), YY is complete, and f:D→Yf : D \to Y is uniformly continuous. Then ff extends to a unique continuous map F:X→YF : X \to Y, which is also uniformly continuous. Sketch: for x∈Xx \in X pick dn∈Dd_n \in D with dn→xd_n \to x; then (dn)(d_n) is Cauchy, so (f(dn))(f(d_n)) is Cauchy by (b), and converges in YY by completeness; call the limit F(x)F(x). Interleaving two sequences tending to xx shows the limit does not depend on the choice. This is how axa^x for irrational xx is defined from rational exponents, and how an integral of a function on [a,b][a, b] extends from step functions. If ff is only continuous, not uniformly, the extension can fail: sin⁡1x\sin\frac1x on (0,1](0, 1] cannot be extended continuously to 00.

    Quick checkA student says: 'The map f:(0,1]→Rf : (0, 1] \to \mathbb R, f(x)=1xf(x) = \frac1x, is continuous, and (0,1](0, 1] is bounded, so ff must be uniformly continuous.' Where is the error?

    Several variables: where the new danger is

    For F:Rn→RmF : \mathbb R^n \to \mathbb R^m the definition is the same, and the new difficulty is that "x→ax \to a" can happen along infinitely many different paths. The definition of the limit requires the SAME value LL for every approach, so a function can have a value along every line and still have no limit.

    Worked example MATH 375 Lecture 19
    Show that f(x,y)=x−yx+yf(x, y) = \dfrac{x - y}{x + y} has no limit at the origin.

    Solution.

    1. Approach along a line. Put y=mxy = mx and let x→0x \to 0 with x≠0x \ne 0. Then f(x,mx)=x(1−m)x(1+m)=1−m1+mf(x, mx) = \dfrac{x(1 - m)}{x(1 + m)} = \dfrac{1 - m}{1 + m} (for m≠−1m \ne -1). The factor xx cancels, so along each line the value is constant, and the limit along that line is that constant.
    2. The limit depends on the line. m=0m = 0 gives 11, m=1m = 1 gives 00, m=3m = 3 gives −12-\frac12. Different lines give different limits.
    3. Turn it into a sequence argument. The sequences (1n,0)(\frac1n, 0) and (1n,1n)(\frac1n, \frac1n) both tend to the origin, but ff along them is constantly 11 and constantly 00. By the sequential form of the limit, a limit LL would need f(pn)→Lf(p_n) \to L for every sequence pn→(0,0)p_n \to (0, 0); two sequences with different limits disprove it.

    Answer. lim⁡(x,y)→(0,0)x−yx+y\lim_{(x, y) \to (0, 0)} \frac{x - y}{x + y} does not exist. ■\blacksquare (The function is not defined on the line y=−xy = -x, and the surface is torn along it.)

    Your answerFor f(x,y)=x−yx+yf(x, y) = \frac{x - y}{x + y}, what value does ff approach as (x,y)→(0,0)(x, y) \to (0, 0) along the line y=3xy = 3x?
    Python labApproach the origin along different paths
    import numpy as np
    
    fs = {
      "(x-y)/(x+y)":        lambda x, y: (x - y) / (x + y),
      "x*y^2/(x^2+y^4)":    lambda x, y: x * y**2 / (x**2 + y**4),
      "x*y/(x^2+y^2)":      lambda x, y: x * y / (x**2 + y**2),
    }
    paths = {
      "y = 0":    lambda t: (t, 0.0 * t),
      "y = x":    lambda t: (t, t),
      "y = 3x":   lambda t: (t, 3 * t),
      "x = y^2":  lambda t: (t**2, t),
      "x = -y^2": lambda t: (-t**2, t),
    }
    for name, f in fs.items():
        print(name)
        for pname, p in paths.items():
            vals = []
            for t in (1e-1, 1e-3, 1e-5):
                x, y = p(t)
                with np.errstate(all="ignore"):
                    vals.append(float(f(x, y)))
            print("  along", pname.ljust(9), [round(v, 4) for v in vals])

    Try this. Run it. The first function has a different limit on each line through the origin. The second, f(x, y) = x*y2/(x2 + y4), goes to 0 along every straight line but not along the parabola x = y2, where the value is always 1/2. Try the path (t3, t) and (-t2, t) as well. Then try the third function x*y/(x2 + y2) and find a line along which it approaches 0.5.

    Worked example MATH 375 Piazza, Nov 21 (@105)
    Show that f(x,y)=xy2x2+y4f(x, y) = \dfrac{x y^2}{x^2 + y^4} (with f(0,0)=0f(0, 0) = 0) is not continuous at the origin, although its limit along every straight line through the origin is 00.

    Solution.

    1. Along a line y=mxy = mx. f(x,mx)=m2x3x2+m4x4=m2x1+m4x2→0f(x, mx) = \dfrac{m^2 x^3}{x^2 + m^4 x^4} = \dfrac{m^2 x}{1 + m^4 x^2} \to 0 as x→0x \to 0. The numerator has one factor of xx left, the denominator tends to 11. The vertical line x=0x = 0 gives f=0f = 0 directly.
    2. Along the parabola x=y2x = y^2. f(y2,y)=y2⋅y2y4+y4=12f(y^2, y) = \dfrac{y^2 \cdot y^2}{y^4 + y^4} = \dfrac12 for every y≠0y \ne 0. The numerator and denominator are both of order y4y^4 on this curve, so the ratio is constant.
    3. Conclude. The sequence pn=(1n2,1n)→(0,0)p_n = (\frac1{n^2}, \frac1n) \to (0, 0) has f(pn)=12↛0=f(0,0)f(p_n) = \frac12 \not\to 0 = f(0, 0). By form (b) of the three-faces theorem, ff is not continuous at 00. One sequence whose images stay away is enough. Checking all lines is not checking all paths.

    Answer. ff is not continuous at the origin. ■\blacksquare (Piazza’s remark: an ε\varepsilon-δ\delta argument is needed for rigour. The sequence argument above is one.)

    Worked example MATH 375 Piazza @119 and HW 11 (Apostol 8.5)
    A function can be continuous in each variable separately and still not be continuous: f(x,y)=xyx2+y2f(x, y) = \dfrac{xy}{x^2 + y^2}, f(0,0)=0f(0, 0) = 0.

    Solution.

    1. Separately continuous. Fix y0y_0. If y0≠0y_0 \ne 0, x↦xy0x2+y02x \mapsto \frac{x y_0}{x^2 + y_0^2} is a quotient of polynomials with non-zero denominator, so continuous. If y0=0y_0 = 0, x↦f(x,0)=0x \mapsto f(x, 0) = 0 is constant. The same holds with the roles of xx and yy swapped. Each one-variable slice is a continuous function of one variable.
    2. Not jointly continuous. Along y=mxy = mx the value is m1+m2\dfrac{m}{1 + m^2}, which is 12\frac12 for m=1m = 1. So f(1n,1n)=12↛0=f(0,0)f(\frac1n, \frac1n) = \frac12 \not\to 0 = f(0, 0). The sequence (1n,1n)→(0,0)(\frac1n, \frac1n) \to (0, 0), and the outputs stay at 12\frac12.

    Answer. ff is continuous in each variable separately and discontinuous at (0,0)(0, 0). ■\blacksquare Piazza @119 corrected a student’s “proof” that separate continuity implies joint continuity: it used the extreme value theorem on a function that was never shown to be continuous. Always check what the hypotheses of a theorem are before applying it.

    Worked example MATH 375 HW 11 (Apostol 8.5 #5)
    Let f(x,y)=xsin⁡1yf(x, y) = x \sin\frac1y for y≠0y \ne 0, f(x,0)=0f(x, 0) = 0. Show f→0f \to 0 at the origin, but that one of the two iterated limits does not exist.

    Solution.

    1. Squeeze. ∣sin⁡1y∣≤1|\sin\frac1y| \le 1, so ∣f(x,y)∣≤∣x∣|f(x, y)| \le |x| for y≠0y \ne 0, and f(x,0)=0≤∣x∣f(x, 0) = 0 \le |x|. So ∣f(x,y)−0∣≤∣x∣≤∥(x,y)∥2|f(x, y) - 0| \le |x| \le \lVert (x, y) \rVert_2. Given ε\varepsilon, take δ=ε\delta = \varepsilon: if ∥(x,y)∥<δ\lVert (x, y) \rVert < \delta then ∣f(x,y)∣<ε|f(x, y)| < \varepsilon. (The posted key wrote −x≤f≤x-x \le f \le x, which is only correct for x≥0x \ge 0; the absolute value fixes it.)
    2. First iterated limit. lim⁡y→0[lim⁡x→0f(x,y)]\lim_{y \to 0}\bigl[\lim_{x \to 0} f(x, y)\bigr]: for each fixed y≠0y \ne 0 the inner limit is 0⋅sin⁡1y=00 \cdot \sin\frac1y = 0. So the outer limit is 00. Take the inner limit in xx first, with yy fixed.
    3. Second iterated limit. For fixed x≠0x \ne 0, lim⁡y→0xsin⁡1y\lim_{y \to 0} x \sin\frac1y does not exist, because sin⁡1y\sin\frac1y oscillates between −1-1 and 11 infinitely often near 00. The inner limit is already undefined, so the iterated limit lim⁡x→0[lim⁡y→0f(x,y)]\lim_{x \to 0}\bigl[\lim_{y \to 0} f(x, y)\bigr] makes no sense.

    Answer. The limit at the origin is 00, and one iterated limit exists while the other does not. A limit in two variables does not imply that an iterated limit exists, as this example shows. The converse also fails: for xyx2+y2\frac{xy}{x^2 + y^2} (the previous example) both iterated limits are 00, yet there is no limit at the origin. ■\blacksquare

    Quick checkA function f(x,y)f(x, y) has limit 00 at the origin along every straight line through the origin. What can you conclude?

    Homeomorphisms

    Definition B

    Homeomorphism

    A homeomorphism between metric spaces XX and YY is a bijection f:X→Yf : X \to Y such that ff and its inverse f−1:Y→Xf^{-1} : Y \to X are both continuous. If one exists, XX and YY are homeomorphic.

    In one lineA homeomorphism is a bijection f:X→Yf : X \to Y such that both ff and f−1f^{-1} are continuous: a one-to-one correspondence that tears and glues nothing, in either direction.

    Why it existsIt is the equivalence of topology: two spaces related by one have the same open sets, the same convergent sequences, the same compact and connected subsets, though possibly different distances.

    By form (c) of the three-faces theorem, a bijection ff is a homeomorphism exactly when UU is open in XX iff f(U)f(U) is open in YY (the preimage under f−1f^{-1} of UU is f(U)f(U)). So it matches up the open sets of the two spaces. An isometry (a bijection preserving distances) is a homeomorphism with L=1L = 1 both ways. More generally a bijection with both ff and f−1f^{-1} Lipschitz is a homeomorphism; the identity map between two equivalent norms is one.

    Worked example
    Show that (−1,1)(-1, 1) and R\mathbb R are homeomorphic, and that [0,2π)→S1[0, 2\pi) \to S^1, t↦(cos⁡t,sin⁡t)t \mapsto (\cos t, \sin t) is a continuous bijection but not a homeomorphism.

    Solution.

    1. A candidate. f(x)=x1−∣x∣f(x) = \dfrac{x}{1 - |x|} from (−1,1)(-1, 1) to R\mathbb R, with inverse g(y)=y1+∣y∣g(y) = \dfrac{y}{1 + |y|}. ff stretches the ends of the interval out to infinity.
    2. They are inverse to each other. For x≥0x \ge 0: g(f(x))=x/(1−x)1+x/(1−x)=x/(1−x)1/(1−x)=xg(f(x)) = \dfrac{x/(1-x)}{1 + x/(1-x)} = \dfrac{x/(1-x)}{1/(1-x)} = x; the case x<0x < 0 is the same by symmetry. And f(g(y))=yf(g(y)) = y similarly. So both are bijections.
    3. Both are continuous. ff is a quotient of continuous functions with denominator 1−∣x∣>01 - |x| > 0 on (−1,1)(-1, 1), and gg has denominator 1+∣y∣≥11 + |y| \ge 1. The building theorem: quotients and the continuity of ∣⋅∣|\cdot|.
    4. So they are homeomorphic. An open interval and the whole line have the same topology, though one is bounded and the other not, and one is complete and the other not. Boundedness and completeness belong to the distance, not to the topology.
    5. The circle map is a continuous bijection. t↦(cos⁡t,sin⁡t)t \mapsto (\cos t, \sin t) is continuous on [0,2π)[0, 2\pi) (shown in 4.4: Lipschitz with L=1L = 1) and takes each point of the circle exactly once. One angle in [0,2π)[0, 2\pi) for each point.
    6. Its inverse is not continuous. Take pn=(cos⁡(−1n),sin⁡(−1n))→(1,0)p_n = (\cos(-\frac1n), \sin(-\frac1n)) \to (1, 0). The angle of pnp_n in [0,2π)[0, 2\pi) is 2π−1n→2π2\pi - \frac1n \to 2\pi, but the angle of (1,0)(1, 0) is 00. Sequential continuity of the inverse fails at (1,0)(1, 0): nearby points on the circle have very different angles when the circle is cut open at t=0t = 0.

    Answer. (−1,1)≅R(-1, 1) \cong \mathbb R. The map [0,2π)→S1[0, 2\pi) \to S^1 is a continuous bijection whose inverse is not continuous, so not a homeomorphism. ■\blacksquare

    Theorem B Rudin Thm 4.14 and 4.22; Munkres Sec. 18 and 26

    Properties preserved by homeomorphisms

    Let h:X→Yh : X \to Y be a homeomorphism. Then UU is open in XX iff h(U)h(U) is open in YY; xn→xx_n \to x iff h(xn)→h(x)h(x_n) \to h(x); KK is compact iff h(K)h(K) is; CC is connected iff h(C)h(C) is. Completeness and boundedness are NOT preserved.

    In one lineA homeomorphism sends open sets to open sets, convergent sequences to convergent sequences, compact sets to compact sets and connected sets to connected sets, in both directions.

    Why it is trueEach of these properties was shown to be preserved by continuous maps, and a homeomorphism is continuous both ways.

    Proofstandard
    The idea: Apply the three-faces theorem and the preservation theorems of 4.3 and 4.4 to h and to h inverse.
    Open sets: UU open implies h(U)h(U) open (continuity of h−1h^{-1}), and h(U)h(U) open implies UU open (continuity of hh).
    h(U)=(h−1)−1(U)h(U) = (h^{-1})^{-1}(U) is the preimage of UU under the continuous map h−1h^{-1}, and U=h−1(h(U))U = h^{-1}(h(U)) is the preimage of h(U)h(U) under hh.
    Sequences: xn→xx_n \to x implies h(xn)→h(x)h(x_n) \to h(x), and conversely using h−1h^{-1}.
    Form (b) of the three-faces theorem for hh and for h−1h^{-1}.
    Compact and connected sets: likewise, by the compact image theorem and the connected image theorem.
    The continuous image of a compact set is compact (4.3), and of a connected set is connected (4.4), applied to hh and to h−1h^{-1}.
    So completeness and boundedness are properties of the distance, not of the shape. ■\blacksquare
    The example above: (−1,1)(-1, 1) is not complete and R\mathbb R is; (−1,1)(-1, 1) is bounded and R\mathbb R is not; ff is a homeomorphism between them.
    Proposition B Rudin Thm 4.17; Munkres Thm 26.6

    A continuous bijection from a compact space is a homeomorphism

    If KK is a compact metric space and f:K→Yf : K \to Y is a continuous bijection onto a metric space YY, then f−1f^{-1} is continuous.

    In one lineIf KK is compact and f:K→Yf : K \to Y is a continuous bijection onto a metric space, then f−1f^{-1} is continuous, so ff is a homeomorphism.

    Why it is trueA closed subset of KK is compact, its image is compact hence closed, and 'sends closed sets to closed sets' is exactly 'the inverse pulls closed sets back to closed sets'.

    ProofRudin 4.17
    The idea: Show that f sends closed sets to closed sets; then (f inverse) pulls closed sets back to closed sets, which is form (d).
    Let F⊆KF \subseteq K be closed. Then FF is compact.
    A closed subset of a compact set is compact (4.3).
    So f(F)f(F) is compact in YY.
    The continuous image of a compact set is compact (4.3).
    So f(F)f(F) is closed in YY.
    Compact sets are closed (4.3).
    So the preimage under f−1f^{-1} of every closed set is closed: f−1f^{-1} is continuous. ■\blacksquare
    Since ff is a bijection, (f−1)−1(F)=f(F)(f^{-1})^{-1}(F) = f(F).

    This explains the circle example: [0,2π)[0, 2\pi) is not compact, so the proposition does not apply, and its conclusion indeed fails. (The map [0,2π]→S1[0, 2\pi] \to S^1 has a compact domain, but it is not a bijection, because both ends go to (1,0)(1, 0). Gluing the two ends of the interval together is the idea of a quotient space, which MATH 551 studies.)

    Worked example
    Show that R\mathbb R and R2\mathbb R^2 are not homeomorphic, and that [0,1][0, 1] and (0,1)(0, 1) are not homeomorphic.

    Solution.

    1. Suppose h:R→R2h : \mathbb R \to \mathbb R^2 is a homeomorphism. Let p=h(0)p = h(0). We look for a property that distinguishes them after one point is removed.
    2. Restrict. hh maps R∖{0}\mathbb R \setminus \{0\} onto R2∖{p}\mathbb R^2 \setminus \{p\}, and this restriction is still continuous with a continuous inverse. Restricting a map to a subset, and its inverse to the image, keeps continuity with the same δ\delta.
    3. Compare connectedness. R∖{0}\mathbb R \setminus \{0\} is not connected (it is not an interval). R2∖{p}\mathbb R^2 \setminus \{p\} is path-connected, hence connected (the punctured plane, 4.4; translating pp to the origin does not change this). A homeomorphism preserves connectedness in both directions, but one space is connected and the other is not.
    4. Contradiction. So R≇R2\mathbb R \not\cong \mathbb R^2. This is a small case of the invariance of dimension; the general statement for Rn\mathbb R^n and Rm\mathbb R^m is much harder and is a MATH 551 theorem.
    5. The interval. [0,1][0, 1] is compact and (0,1)(0, 1) is not (4.3), and a homeomorphism preserves compactness. (0,1)(0, 1) is not closed, so not compact.

    Answer. Neither pair is homeomorphic. ■\blacksquare

    Quick checkIs the continuous bijection f:[0,2π)→S1f : [0, 2\pi) \to S^1, f(t)=(cos⁡t,sin⁡t)f(t) = (\cos t, \sin t), a homeomorphism?

    Equivalent norms again, and all norms on R^n

    4.1 defined equivalent norms and proved that equivalent norms have the same open sets. Now we can say more and settle the question 4.1 left open.

    Proposition B standard

    Equivalent norms give the same continuous maps

    If m ∥x∥a≤∥x∥b≤M ∥x∥am\,\lVert x \rVert_a \le \lVert x \rVert_b \le M\,\lVert x \rVert_a for all x∈Vx \in V, then the identity map (V,∥⋅∥a)→(V,∥⋅∥b)(V, \lVert \cdot \rVert_a) \to (V, \lVert \cdot \rVert_b) is Lipschitz with constant MM, its inverse is Lipschitz with constant 1/m1/m, and so both are continuous. Hence a map f:X→Vf : X \to V is continuous into (V,∥⋅∥a)(V, \lVert \cdot \rVert_a) iff it is continuous into (V,∥⋅∥b)(V, \lVert \cdot \rVert_b), and likewise for maps out of VV.

    In one lineIf two norms on VV are equivalent, the identity map between the two normed spaces is a bi-Lipschitz homeomorphism, so a map into or out of VV is continuous for one norm iff it is for the other.

    Why it is trueThe defining inequalities m∥x∥a≤∥x∥b≤M∥x∥am\lVert x \rVert_a \le \lVert x \rVert_b \le M\lVert x \rVert_a say that the identity is Lipschitz with constant MM one way and 1/m1/m the other.

    Proofstandard
    The idea: The two inequalities are Lipschitz inequalities for the identity map. Composition of continuous maps does the rest.
    ∥x−y∥b≤M ∥x−y∥a\lVert x - y \rVert_b \le M\,\lVert x - y \rVert_a: the identity is MM-Lipschitz from aa to bb.
    Apply the right inequality to the vector x−yx - y.
    ∥x−y∥a≤1m∥x−y∥b\lVert x - y \rVert_a \le \frac1m \lVert x - y \rVert_b: its inverse is 1m\frac1m-Lipschitz.
    Apply the left inequality to x−yx - y.
    So ff continuous into aa gives id∘f\mathrm{id} \circ f continuous into bb, and conversely. ■\blacksquare
    Lipschitz maps are continuous. A map ff into (V,a)(V, a) followed by the continuous identity is a map into (V,b)(V, b); the composition of continuous maps is continuous. The reverse direction uses the inverse.
    Theorem B standard

    All norms on R^n are equivalent

    Let ∥⋅∥\lVert \cdot \rVert be any norm on Rn\mathbb R^n. Then it is equivalent to ∥⋅∥1\lVert \cdot \rVert_1, and so any two norms on Rn\mathbb R^n are equivalent. In particular they have the same open sets, convergent sequences, Cauchy sequences, and continuous maps.

    In one lineFor any norm ∥⋅∥\lVert \cdot \rVert on Rn\mathbb R^n there are constants 0<m≤M0 < m \le M with m∥x∥1≤∥x∥≤M∥x∥1m\lVert x \rVert_1 \le \lVert x \rVert \le M\lVert x \rVert_1 for all xx.

    Why it is trueThe norm is a continuous function on the compact 'unit sphere' of the 1-norm, so it has a positive minimum and a finite maximum there; scaling extends the bounds to every vector.

    Proofstandard
    The idea: Upper bound by the triangle inequality on the standard basis. That makes the norm Lipschitz for the 1-norm, so continuous. The unit sphere of the 1-norm is compact (Heine–Borel), so the norm attains a minimum m there, which is positive because the norm of a non-zero vector is positive. Scale.
    Let M=max⁡i∥ei∥M = \max_i \lVert e_i \rVert. Then ∥x∥≤∑∣xi∣ ∥ei∥≤M ∥x∥1\lVert x \rVert \le \sum |x_i|\,\lVert e_i \rVert \le M\,\lVert x \rVert_1.
    Write x=∑xieix = \sum x_i e_i and apply the triangle inequality (N3) repeatedly and homogeneity (N2).
    So ∣∥x∥−∥y∥∣≤∥x−y∥≤M ∥x−y∥1|\lVert x \rVert - \lVert y \rVert| \le \lVert x - y \rVert \le M\,\lVert x - y \rVert_1: the function x↦∥x∥x \mapsto \lVert x \rVert is Lipschitz, hence continuous, on (Rn,∥⋅∥1)(\mathbb R^n, \lVert \cdot \rVert_1).
    Reverse triangle inequality for the norm, then the bound proved in the previous step applied to x−yx - y.
    The sphere S={x:∥x∥1=1}S = \{x : \lVert x \rVert_1 = 1\} is compact.
    It is closed (the 1-norm is continuous and the sphere is the preimage of the closed set {1}\{1\}) and bounded (each ∣xi∣≤1|x_i| \le 1). Heine–Borel applies to Rn\mathbb R^n with the 1-distance, by the equivalence of the 1-, 2- and max-norms in 4.1.
    So there is x0∈Sx_0 \in S with ∥x0∥=m=min⁡S∥x∥\lVert x_0 \rVert = m = \min_S \lVert x \rVert.
    The extreme value theorem on a compact set (4.3), applied to the continuous function ∥⋅∥\lVert \cdot \rVert on SS; SS is non-empty.
    So m>0m > 0.
    x0≠Ox_0 \ne O since ∥x0∥1=1\lVert x_0 \rVert_1 = 1, and a norm is positive on non-zero vectors (N1).
    So m ∥x∥1≤∥x∥≤M ∥x∥1m\,\lVert x \rVert_1 \le \lVert x \rVert \le M\,\lVert x \rVert_1 for all xx.
    For x≠Ox \ne O the vector x/∥x∥1x/\lVert x \rVert_1 lies on SS, so ∥x/∥x∥1∥≥m\lVert x/\lVert x \rVert_1 \rVert \ge m. Homogeneity (N2) gives ∥x∥≥m ∥x∥1\lVert x \rVert \ge m\,\lVert x \rVert_1. For x=Ox = O both sides are 00.
    Any two norms are equivalent to ∥⋅∥1\lVert \cdot \rVert_1, hence to each other. ■\blacksquare
    Equivalence is symmetric and transitive: if a∼1a \sim 1 and b∼1b \sim 1 then a∼ba \sim b, multiplying constants.

    In the picture of 4.1 (diamond, disc and square) this says every other norm’s unit ball is also squeezed between two scaled copies of the diamond. A consequence: every linear map T:Rn→RmT : \mathbb R^n \to \mathbb R^m is continuous whichever norms are used, since it is Lipschitz for the 2-norms (the operator norm) and norms are equivalent.

    Beyond the course: for understanding· In infinite dimensions linear maps can be discontinuous (B)

    Let C1[0,1]C^1[0, 1] be the continuously differentiable functions with the sup norm ∥f∥∞\lVert f \rVert_\infty, and Df=f′D f = f' the derivative, mapping into C[0,1]C[0, 1] with the sup norm. DD is linear. Take fn(x)=xn/nf_n(x) = x^n / n. Then ∥fn∥∞=1n→0\lVert f_n \rVert_\infty = \frac1n \to 0, so fn→0f_n \to 0, but Dfn=xn−1D f_n = x^{n-1} has ∥Dfn∥∞=1\lVert D f_n \rVert_\infty = 1, which does not tend to ∥D0∥=0\lVert D 0 \rVert = 0. So DD is not continuous at 00. In finite dimensions every linear map is continuous (the theorem above); in infinite dimensions the choice of norm decides, and differentiation is the standard example of an unbounded operator. This is part of why analysis on function spaces needs care.

    Where it is used

    Used inside maths· Inside maths: the doorway to topology, and to derivatives in several variables

    Form (c) of the three-faces theorem is the definition of continuity in topology: a topological space is a set with a collection of “open” sets satisfying the rules proved in 4.1 (the empty set and the whole space, arbitrary unions, finite intersections), and a map is continuous when preimages of open sets are open. Everything in this chapter that was proved from form (c) alone, compositions, preservation of compact and connected sets, homeomorphisms, carries over. What does not: Cauchy sequences, completeness, boundedness, uniform continuity, which use the distance. That is the dividing line between analysis (MATH 521) and topology (MATH 551). In Unit 5 the derivative of F:Rn→RmF : \mathbb R^n \to \mathbb R^m at a point aa is defined as the linear map TT with ∥F(a+h)−F(a)−Th∥/∥h∥→0\lVert F(a + h) - F(a) - T h \rVert / \lVert h \rVert \to 0; that needs the limit of a map between metric spaces, defined here, and an interior point, from 4.1, so that a+ha + h makes sense in every direction.

    Used in the real world· Robustness of neural networks: Lipschitz constants as certificates

    An image classifier is a map f:Rn→Rkf : \mathbb R^n \to \mathbb R^k from pixels to class scores. If ff is Lipschitz with constant LL for the usual length, then changing the input by a vector of length ε\varepsilon changes the score vector by length at most LεL\varepsilon. The score of class ii minus the score of class jj is (ei−ej)⋅f(x)(e_i - e_j) \cdot f(x), and ∥ei−ej∥2=2\lVert e_i - e_j \rVert_2 = \sqrt2, so by Cauchy–Schwarz this difference changes by at most 2 Lε\sqrt2\,L\varepsilon. Hence if the winning class beats every other by a margin μ\mu, the prediction cannot change for any input within distance μ/(2L)\mu / (\sqrt2 L). This is a certificate: no attack of that size can succeed.

    A network x↦W2 ReLU(W1x)x \mapsto W_2\,\mathrm{ReLU}(W_1 x) is a composition. A matrix multiplication is Lipschitz with constant its operator norm (the largest singular value, 3.5). ReLU applied to each entry is 1-Lipschitz, since ∣max⁡(a,0)−max⁡(b,0)∣≤∣a−b∣|\max(a, 0) - \max(b, 0)| \le |a - b|. Compositions multiply Lipschitz constants, so L≤∥W2∥ ∥W1∥L \le \lVert W_2 \rVert\,\lVert W_1 \rVert. For the two-layer network in the lab below, ∥W1∥≈1.513\lVert W_1 \rVert \approx 1.513 and ∥W2∥≈1.208\lVert W_2 \rVert \approx 1.208, so L≤1.828L \le 1.828. At the input (1,−0.5)(1, -0.5) the margin is 1.7051.705, so the certified radius is 1.7052⋅1.828≈0.659\frac{1.705}{\sqrt2 \cdot 1.828} \approx 0.659. The lab then searches for the true distance to the decision boundary and finds about 0.90.9. The certificate is correct and conservative: the product of norms overestimates how much a real network can stretch a particular input. Computing the exact Lipschitz constant of a ReLU network is NP-hard even for two layers (Virmaux and Scaman, 2018), which is why a product of layer norms is the standard cheap bound.

    Your answerA network has layer operator norms 2.02.0 and 1.51.5, so L≤3L \le 3. At an input, the winning class beats the runner-up by a margin of 33. What is the certified radius μ/(2 L)\mu / (\sqrt2\,L)? (Give a decimal.)
    Python labCertify a tiny network, then look for the true boundary
    import numpy as np
    
    W1 = np.array([[1.2, -0.7], [0.4, 0.9], [-0.5, 0.3]])
    W2 = np.array([[0.8, -0.6, 0.2], [-0.3, 0.5, 0.9]])
    f = lambda x: W2 @ np.maximum(W1 @ x, 0)
    
    L = np.linalg.norm(W1, 2) * np.linalg.norm(W2, 2)     # product of operator norms
    x0 = np.array([1.0, -0.5])
    out = f(x0)
    margin = abs(out[0] - out[1])
    radius = margin / (np.sqrt(2) * L)
    print("L <=", round(L, 3), " margin =", round(margin, 3), " certified radius =", round(radius, 3))
    
    top = np.sign(out[0] - out[1])
    best = np.inf
    for a in np.linspace(0, 2 * np.pi, 720, endpoint=False):
        d = np.array([np.cos(a), np.sin(a)])
        for r in np.linspace(0.005, 4, 800):
            o = f(x0 + r * d)
            if np.sign(o[0] - o[1]) != top:
                best = min(best, r)
                break
    print("true distance to the nearest class change is about", round(best, 3))

    Try this. Run it. The certified radius is guaranteed and the true distance to a class change is larger. Change x0 to [0.5, 1.5] or [2.0, -1.0] and compare the gap between the certified and the true distance. Then scale W1 by 3 (W1 = 3 * W1): L multiplies by 3, the margin also grows, but the certified radius stays about the same because both scale together. Why does multiplying the weights by 3 not help robustness at all?

    Used in the real world· Topology in data analysis (a light touch): counting pieces at every scale

    Given a cloud of data points in Rn\mathbb R^n, one can ask how many separate clusters it has. The answer depends on the scale ε\varepsilon at which you look. Replace each point by an open ball of radius ε/2\varepsilon/2; two balls overlap exactly when the points are closer than ε\varepsilon to each other. The union of balls has some number of connected pieces (4.4). Plot that number against ε\varepsilon: for the points 0,1,2.5,10,110, 1, 2.5, 10, 11 on a line, at ε=0.5\varepsilon = 0.5 there are 5 pieces, at ε=1.4\varepsilon = 1.4 there are 3 ({0,1}\{0, 1\}, {2.5}\{2.5\}, {10,11}\{10, 11\}), at ε=1.6\varepsilon = 1.6 there are 2 (the point 2.52.5 joins 11), and at ε=8\varepsilon = 8 there is 1. The scales at which the count changes record the gaps in the data, and a long stretch of ε\varepsilon with the same count signals a real cluster structure. This count of components over all scales is the zero-dimensional part of persistent homology, a method used on shape data, protein structures and neural activity. It is a stability statement too: moving every point by less than δ\delta changes the scales at which components merge by at most 2δ2\delta, which is a Lipschitz property of the whole procedure.

    Your answerFor the points 0,1,2.5,10,110, 1, 2.5, 10, 11 on a line, two points are joined when they are closer than ε=1.4\varepsilon = 1.4 to each other. How many connected pieces are there?

    Traps

    Watch out· Limits along every line do not give a limit

    The function xy2/(x2+y4)xy^2/(x^2 + y^4) tends to 00 along every straight line through the origin and has value 12\frac12 along the parabola x=y2x = y^2. To show a two-variable limit exists, bound ∣f(x,y)−L∣|f(x, y) - L| by something that tends to 00 as ∥(x,y)∥→0\lVert (x, y) \rVert \to 0 (the squeeze), or convert to polar form. To show it does not exist, exhibit two paths or sequences with different limits.

    Watch out· Separately continuous is not jointly continuous

    xy/(x2+y2)xy/(x^2 + y^2) is continuous in xx for each fixed yy and in yy for each fixed xx, and is discontinuous at the origin. Continuity of F:R2→RF : \mathbb R^2 \to \mathbb R is a statement about nearby points in the plane, not only nearby points on the two coordinate lines. A proof that uses only the two one-variable slices has proved nothing about FF.

    Watch out· Continuous maps pull open sets back; they do not push them forward

    f(x)=x2f(x) = x^2 sends (−1,1)(-1, 1) to [0,1)[0, 1), and a constant map sends every open set to a point. The theorem is about preimages: f−1(open)f^{-1}(\text{open}) is open. A map for which images of open sets are open is called an open map, a stronger and different property.

    Watch out· A continuous bijection need not have a continuous inverse

    [0,2π)→S1[0, 2\pi) \to S^1 is the standard example. To prove a map is a homeomorphism, show that both directions are continuous, or that the domain is compact and the target is a metric space (the compact-domain proposition above).

    Watch out· Continuity depends only on the open sets; uniform continuity and completeness depend on the distance

    The identity map from ((0,∞),∣x−y∣)((0, \infty), |x - y|) to ((0,∞),∣1x−1y∣)((0, \infty), |\frac1x - \frac1y|) is a homeomorphism (the open sets agree), but it is not uniformly continuous: the sequence 1n\frac1n is Cauchy in the first space, and its image nn is not Cauchy in the second (∣1m−1n∣|\frac1m - \frac1n| becomes ∣m−n∣|m - n| after the map). So a property that is invariant under homeomorphism, such as compactness or connectedness, is different from one that is not, such as Cauchy sequences, completeness and uniform continuity.

    Watch out· Do not forget the domain: arcsin and arccos are continuous on closed intervals

    When finding where arcsin⁡(u(x,y))\arcsin(u(x, y)) is continuous, first find where uu is defined and continuous, and note ∣u∣≤1|u| \le 1 there. Then arcsin⁡\arcsin is continuous on [−1,1][-1, 1], ends included. A frequent mistake (it appeared in a posted solution key) is to drop the boundary points where ∣u∣=1|u| = 1, which are perfectly good points of continuity.

    Problems

    check

    Is f(x)=⌊x⌋f(x) = \lfloor x \rfloor (the greatest integer at most xx) continuous as a map R→R\mathbb R \to \mathbb R? As a map Z→R\mathbb Z \to \mathbb R (with ∣x−y∣|x - y| on Z\mathbb Z)? Where does it fail on R\mathbb R?

    Solution

    On R\mathbb R it is discontinuous at every integer: at nn, the sequence n−1k→nn - \frac1k \to n has f=n−1↛nf = n - 1 \not\to n. As a map out of Z\mathbb Z it is continuous (it is the inclusion Z→R\mathbb Z \to \mathbb R, since ⌊n⌋=n\lfloor n \rfloor = n): every point of Z\mathbb Z is isolated, since B(n,12)={n}B(n, \frac12) = \{n\}, and continuity at an isolated point is automatic.

    check

    For f(x)=x2f(x) = x^2, describe f−1((1,4))f^{-1}((1, 4)) and f−1([1,4])f^{-1}([1, 4]). Which is open, which closed?

    Solution

    f−1((1,4))=(−2,−1)∪(1,2)f^{-1}((1, 4)) = (-2, -1) \cup (1, 2), open. f−1([1,4])=[−2,−1]∪[1,2]f^{-1}([1, 4]) = [-2, -1] \cup [1, 2], closed. This is the pattern: open preimage of an open set, closed preimage of a closed set.

    check

    Use a sequence to show that f(x,y)=xyx2+y2f(x, y) = \dfrac{x y}{x^2 + y^2} (with f(0,0)=0f(0,0) = 0) is not continuous at the origin.

    Solution

    The points (1n,1n)→(0,0)(\frac1n, \frac1n) \to (0, 0), but f(1n,1n)=1/n22/n2=12↛0=f(0,0)f(\frac1n, \frac1n) = \frac{1/n^2}{2/n^2} = \frac12 \not\to 0 = f(0, 0). By the sequential form of continuity, ff is not continuous at the origin.

    check

    Which of ∣x∣|x|, x2x^2, ∣x∣\sqrt{|x|} and sin⁡x\sin x are Lipschitz on R\mathbb R?

    Solution

    ∣x∣|x| (constant 11) and sin⁡x\sin x (constant 11, since ∣cos⁡∣≤1|\cos| \le 1 and the mean value theorem). Not x2x^2 (the slope 2x2x is unbounded) and not ∣x∣\sqrt{|x|} (near 00, ∣h−0∣=h|\sqrt h - \sqrt 0| = \sqrt h is not at most LhL h for small hh).

    useMATH 375 HW 11 (Apostol 8.5 #1j) with correction

    Find the set where f(x,y)=arccos⁡x/yf(x, y) = \arccos\sqrt{x/y} is defined and show it is continuous on all of that set.

    Solution

    Defined iff y≠0y \ne 0 and 0≤x/y≤10 \le x/y \le 1. On this set, x/yx/y is continuous,  \sqrt{\ } is continuous on [0,∞)[0, \infty) and arccos⁡\arccos is continuous on [−1,1][-1, 1], so the composition is continuous on the whole domain. This includes the points x=0x = 0 (value π2\frac\pi2) and x=y≠0x = y \ne 0 (value 00). The posted key kept only the strict inequalities.

    useMATH 375 HW 11 (Apostol 8.3 #2 style)

    Sketch S={(x,y):xy>1}S = \{(x, y) : xy > 1\}, show that it is open, and find its boundary and its closure.

    Solution

    S=F−1((1,∞))S = F^{-1}((1, \infty)) for the continuous F(x,y)=xyF(x, y) = xy, so SS is open. It is the region above the branch of the hyperbola xy=1xy = 1 in the first quadrant and below the branch in the third quadrant (two pieces: x,y>0x, y > 0 with y>1/xy > 1/x, and x,y<0x, y < 0 with y<1/xy < 1/x). The boundary is the hyperbola {xy=1}\{xy = 1\} (two branches), and the closure is {xy≥1}\{xy \ge 1\}.

    use

    Show that lim⁡(x,y)→(0,0)x2−y2x2+y2\lim_{(x, y) \to (0, 0)} \dfrac{x^2 - y^2}{x^2 + y^2} does not exist.

    Solution

    Along y=mxy = mx the value is 1−m21+m2\frac{1 - m^2}{1 + m^2}, which is 11 for m=0m = 0 and 00 for m=1m = 1. Two paths, two limits, so no limit.

    use

    Does x2yx2+y2\dfrac{x^2 y}{x^2 + y^2} (value 00 at the origin) have limit 00 at the origin? Prove it.

    Solution

    Yes. ∣x2y∣≤(x2+y2) ∣y∣|x^2 y| \le (x^2 + y^2)\,|y| because x2≤x2+y2x^2 \le x^2 + y^2, so ∣x2yx2+y2∣≤∣y∣≤∥(x,y)∥\left| \frac{x^2 y}{x^2 + y^2} \right| \le |y| \le \lVert (x, y) \rVert. Given ε\varepsilon, δ=ε\delta = \varepsilon works. So the function is continuous at the origin.

    prove

    Prove that a map f:X→Yf : X \to Y is continuous iff f(A‾)⊆f(A)‾f(\overline A) \subseteq \overline{f(A)} for every A⊆XA \subseteq X.

    Solution

    Plan. Use sequences and the description of the closure by sequences (4.2).

    (⇒\Rightarrow) If x∈A‾x \in \overline A there are an∈Aa_n \in A with an→xa_n \to x (4.2). By continuity f(an)→f(x)f(a_n) \to f(x), so f(x)f(x) is a limit of points of f(A)f(A), hence in f(A)‾\overline{f(A)}.

    (⇐\Leftarrow) Let F⊆YF \subseteq Y be closed, and A=f−1(F)A = f^{-1}(F). Then f(A)⊆Ff(A) \subseteq F, so f(A)‾⊆F\overline{f(A)} \subseteq F (FF is closed). By hypothesis f(A‾)⊆f(A)‾⊆Ff(\overline A) \subseteq \overline{f(A)} \subseteq F, so A‾⊆f−1(F)=A\overline A \subseteq f^{-1}(F) = A. So AA is closed. By form (d), ff is continuous. ■\blacksquare

    prove

    Prove that if f,g:X→Rf, g : X \to \mathbb R are continuous, then max⁡(f,g)\max(f, g) is continuous.

    Solution

    Plan. Write the maximum with absolute values.

    max⁡(f,g)=12(f+g+∣f−g∣)\max(f, g) = \frac12(f + g + |f - g|). The map f−gf - g is continuous (building theorem), ∣⋅∣:R→R|\cdot| : \mathbb R \to \mathbb R is 1-Lipschitz hence continuous, so ∣f−g∣|f - g| is a composition of continuous maps, hence continuous; the sum and the multiple by 12\frac12 are continuous. ■\blacksquare

    prove

    Prove that if f:X→Yf : X \to Y and g:Y→Zg : Y \to Z are uniformly continuous, then g∘fg \circ f is uniformly continuous.

    Solution

    Plan. Work backwards from the tolerance in ZZ: first the δ\delta of gg, then the δ\delta of ff for that tolerance.

    Let ε>0\varepsilon > 0. Uniform continuity of gg gives η>0\eta > 0 with dZ(g(u),g(v))<εd_Z(g(u), g(v)) < \varepsilon whenever dY(u,v)<ηd_Y(u, v) < \eta, for all u,v∈Yu, v \in Y. Uniform continuity of ff, with tolerance η\eta, gives δ>0\delta > 0 with dY(f(x),f(x′))<ηd_Y(f(x), f(x')) < \eta whenever dX(x,x′)<δd_X(x, x') < \delta, for all x,x′∈Xx, x' \in X. If dX(x,x′)<δd_X(x, x') < \delta, then dY(f(x),f(x′))<ηd_Y(f(x), f(x')) < \eta, so dZ(g(f(x)),g(f(x′)))<εd_Z(g(f(x)), g(f(x'))) < \varepsilon. The number δ\delta depends only on ε\varepsilon, not on the points. ■\blacksquare

    prove

    Prove that [0,1)[0, 1) and (0,1)(0, 1) are not homeomorphic.

    Solution

    Plan. Remove a point and compare connectedness.

    Suppose h:[0,1)→(0,1)h : [0, 1) \to (0, 1) is a homeomorphism and put p=h(0)p = h(0). Then hh restricts to a homeomorphism from [0,1)∖{0}=(0,1)[0, 1) \setminus \{0\} = (0, 1) onto (0,1)∖{p}(0, 1) \setminus \{p\}. The first is an interval, hence connected. The second is (0,p)∪(p,1)(0, p) \cup (p, 1), which is not an interval, hence not connected. Connectedness is preserved by homeomorphisms, a contradiction. ■\blacksquare

    prove

    Prove that a linear map T:V→WT : V \to W between normed spaces is continuous iff it is bounded: ∥Tx∥≤C∥x∥\lVert Tx \rVert \le C\lVert x \rVert for some constant CC and all xx.

    Solution

    Plan. Bounded gives Lipschitz. For the converse use continuity at OO with ε=1\varepsilon = 1, and scale.

    If ∥Tx∥≤C∥x∥\lVert Tx \rVert \le C\lVert x \rVert, then ∥Tx−Ty∥=∥T(x−y)∥≤C∥x−y∥\lVert Tx - Ty \rVert = \lVert T(x - y) \rVert \le C\lVert x - y \rVert: Lipschitz, so continuous. Conversely, suppose TT is continuous at OO. Take ε=1\varepsilon = 1: there is δ>0\delta > 0 with ∥Tz∥<1\lVert Tz \rVert < 1 whenever ∥z∥<δ\lVert z \rVert < \delta. For x≠Ox \ne O put z=δ2∥x∥xz = \frac{\delta}{2\lVert x \rVert}x, so ∥z∥=δ2<δ\lVert z \rVert = \frac\delta2 < \delta. Then ∥Tz∥=δ2∥x∥∥Tx∥<1\lVert Tz \rVert = \frac{\delta}{2\lVert x \rVert}\lVert Tx \rVert < 1, so ∥Tx∥<2δ∥x∥\lVert Tx \rVert < \frac2\delta \lVert x \rVert. Take C=2δC = \frac2\delta. ■\blacksquare

    stretch

    Prove the extension theorem in the box above: a uniformly continuous f:D→Yf : D \to Y on a dense subset D⊆XD \subseteq X, with YY complete, extends to a continuous F:X→YF : X \to Y.

    Solution

    Plan. Define F(x)F(x) as the limit of f(dn)f(d_n) along any sequence dn→xd_n \to x in DD, and check it is well defined.

    Let x∈Xx \in X. By density, pick dn∈Dd_n \in D with dn→xd_n \to x. The sequence (dn)(d_n) is Cauchy, so (f(dn))(f(d_n)) is Cauchy (part (b) of the uniform continuity theorem), and converges in YY since YY is complete. If dn′→xd_n' \to x is another sequence, the interleaved sequence d1,d1′,d2,d2′,…d_1, d_1', d_2, d_2', \dots also tends to xx, so its image is Cauchy and converges, so the limits of f(dn)f(d_n) and f(dn′)f(d_n') agree. Define F(x)F(x) to be this limit. For x∈Dx \in D, the constant sequence gives F(x)=f(x)F(x) = f(x). For uniform continuity of FF: given ε\varepsilon, take δ\delta for ε3\frac\varepsilon3 from ff. If dX(x,x′)<δ3d_X(x, x') < \frac\delta3, choose d,d′∈Dd, d' \in D with dX(d,x)d_X(d, x), dX(d′,x′)<δ3d_X(d', x') < \frac\delta3 and dY(f(d),F(x))d_Y(f(d), F(x)), dY(f(d′),F(x′))<ε3d_Y(f(d'), F(x')) < \frac\varepsilon3 (possible by the definition of FF with sequences). Then dX(d,d′)<δd_X(d, d') < \delta, so dY(F(x),F(x′))<ε3+ε3+ε3=εd_Y(F(x), F(x')) < \frac\varepsilon3 + \frac\varepsilon3 + \frac\varepsilon3 = \varepsilon. Uniqueness: a continuous extension is determined on the dense set. ■\blacksquare

    stretch

    Prove that every norm on Rn\mathbb R^n gives a complete metric space.

    Solution

    Plan. Equivalence of norms moves Cauchy sequences and limits between the given norm and the 1-norm, where completeness is known (4.2).

    Let ∥⋅∥\lVert \cdot \rVert be a norm, with m∥x∥1≤∥x∥≤M∥x∥1m\lVert x \rVert_1 \le \lVert x \rVert \le M\lVert x \rVert_1. Let (xk)(x_k) be Cauchy for ∥⋅∥\lVert \cdot \rVert. Then ∥xk−xl∥1≤1m∥xk−xl∥\lVert x_k - x_l \rVert_1 \le \frac1m \lVert x_k - x_l \rVert, so (xk)(x_k) is Cauchy for the 1-norm. Rn\mathbb R^n is complete for the 1-distance (4.2), so ∥xk−x∥1→0\lVert x_k - x \rVert_1 \to 0 for some xx. Then ∥xk−x∥≤M∥xk−x∥1→0\lVert x_k - x \rVert \le M\lVert x_k - x \rVert_1 \to 0, so xk→xx_k \to x in the given norm. ■\blacksquare

    Summary

    • A map f:X→Yf : X \to Y between metric spaces is continuous when the ε\varepsilon-δ\delta condition of 1.3 holds with the distances dXd_X and dYd_Y. The limit of a map between metric spaces is defined the same way with 0<dX(x,a)0 < d_X(x, a).
    • Three equivalent forms. ε\varepsilon-δ\delta at every point; xn→ax_n \to a implies f(xn)→f(a)f(x_n) \to f(a); the preimage of every open set is open (and equivalently of every closed set is closed). The last needs no distance, which is where topology begins.
    • Continuous maps are closed under composition, sums, products, quotients and combination into coordinates; projections and norms are continuous. This proves continuity for polynomials, rational functions and elementary compositions on their domains.
    • A Lipschitz map (d(f(x),f(y))≤L d(x,y)d(f(x), f(y)) \le L\,d(x, y)) is uniformly continuous; a matrix is Lipschitz with constant its operator norm. Uniformly continuous maps send Cauchy sequences to Cauchy sequences, and continuous maps on compact spaces are uniformly continuous.
    • In several variables a limit must be the same along every path. Different lines giving different limits, or a parabola giving a different limit from the lines, disproves it. Separate continuity does not give joint continuity.
    • A homeomorphism is a bijection continuous in both directions. It preserves open sets, sequences, compactness and connectedness, not completeness or boundedness. A continuous bijection from a compact space is automatically a homeomorphism. R\mathbb R and R2\mathbb R^2 are not homeomorphic.
    • All norms on Rn\mathbb R^n are equivalent, proved with compactness of the unit sphere, so they give the same open sets and the same continuous maps. In infinite dimensions this fails, and linear maps can be discontinuous.
    • A product of layer Lipschitz constants bounds a neural network’s sensitivity and gives a certified robustness radius.

    Where this sits

    Comes from
    4.1 Metric and normed spaces; open and closed sets
    4.2 Convergence, completeness and the contraction mapping theorem
    4.3 Compactness
    4.4 Connectedness and path-connectedness
    1.3 Limits and continuity with epsilon and delta
    3.5 Matrix norms, conditioning, and why numerics fail
    Leads to
    5.1 Scalar and vector fields, limits and continuity
    Same idea elsewhere
    MATH 375: Lecture 19 and Apostol 8.4 to 8.5 define limits and continuity for $F : \mathbb R^n \to \mathbb R^m$ with the lengths in both spaces, show that continuity is componentwise, that sums, products and compositions are continuous, and give the path-dependent limit $(x - y)/(x + y)$. This chapter proves the same statements for any metric space, so the 375 proofs are special cases.
    MATH 521: 521 proves the equivalence of the three forms of continuity in its first weeks on metric spaces, then uses the open-set form to prove that compactness and connectedness are preserved. Everything in sections 1 to 3 here is that lecture.
    MATH 551: A topological space is a set with a collection of 'open' sets obeying the rules proved in 4.1, and a map is continuous when preimages of open sets are open. The theorem of this chapter says that for metric spaces this agrees with the definition you already know. Homeomorphisms are the isomorphisms of topology.
    CS 532 / AI: A neural network is a composition of maps, and its Lipschitz constant is bounded by the product of the constants of its layers. A small Lipschitz constant is a certificate that small input changes cannot flip the output.