Skip to main content

20 - Functions - limits and continuity

Functions in arbitrary metric spaces

What is the deal with functions in arbitrary metric spaces? What is a function? What does it mean for a function to have a limit? And what does it mean for a function to be continuous?

  • Functions: Throughout the lecture, we will imagine we are dealing with two metric spaces, XX and YY. So let XX and YY be metric spaces. So each of them has some metric or some notion of distance on them. We might think of XX and YY in the following way:

    A function is going to be an assignment, and we actually defined this at the very beginning of the class. The function will be an assignment of a point in XX to a unique point in YY. We may even have a whole line of things being mapped to another line in YY:

    There are, of course, many ways to think of functions. Separating a function into its domain and codomain is a very mathematical way of looking at functions, but you've also seen throughout your education that you can visualize functions as graphs. So in the picture above, we have a mapping, but we could also think about ff as a graph. Of course, if we are trying to look at ff as a graph, then we would try to put these things on the same diagram where we place XX and YY as follows:

    With the mapping representation of the faces, the domain and codomain were both 2-dimensional, and so on the XX-axis you would have two dimensions and on the YY axis you would have two dimensions. It is fairly easy to see that the graph quickly becomes intractable when the dimensions get bigger than 3 because the graph of a function from 2 dimensions to 2 dimensions will be 4-dimensional. This is why often it's a better picture to think about the oval mapping of elements from one set to another set than the strict graph interpretation.

  • Limits: What does it mean to talk about the limit of a function? That's the question we want to grapple with. We've already talked about what it means to take limits of sequences. We know what this means: limnxn=x\lim_{n\to\infty} x_n=x. It means that for every ϵ>0\epsilon>0 there is an integer NN such that for all nNn\geq N we have d(xn,x)<ϵd(x_n,x)<\epsilon or xnx<ϵ|x_n-x|<\epsilon using the usual metric, but what we want to grapple with is the following question: Does it make any sense whatsoever to talk about the limit of a function:

    limxpf(x)=q.\lim_{x\to p}f(x)=q.

    What does this mean? Can we make sense of this? So let's just look at some examples.

  • Example 1: So maybe we draw the graph of a particular function. It might look something like this:

    So what we've depicted is four points in the domain XX that go to some four points in the range, and we've just graphed them here. This is at least part of a function. Maybe we haven't defined the whole function, but does it make any sense to say that f(x)f(x) goes to some qq as xx goes to some pp? Here, of course, we only have 4 points, but you could imagine we have a whole interval of points in the domain and we know where they go in the codomain. So maybe the picture would look like the following if we showed all of the points:

    And then we could begin to ask if a bunch of points down on the XX-axis converge to pp, then what does that mean? Can we say that their images converge to some qq in YY? That's kind of the question we are asking:

  • Example 2: Maybe our graph of a function looks something like this:

    So we have a point pp and a bunch of xx's going to pp, and now the question is can we talk about the limit of the f(x)f(x)'s. Are these points doing something? That's the question. How do we make sense of this?

  • Example 3: What we should first notice is that the statement about the limit of a sequence is actually a statement about a function since a sequence is a function is it not? How is a sequence a function? It takes in an index and spits out a number. So that's a function that looks something like this, where it's defined only on the integer points, and if it was converging to some kind of limit, then really what we are saying is that, as we go further and further out, the graphed points approach a limiting value (indicated by the dashed line below):

    What's different about limxpf(x)=q\lim_{x\to p}f(x)=q as opposed to limnxn=x\lim_{n\to\infty} x_n=x is that we are allowing ourselves to look at points that do not go off to infinity but maybe get closer and closer to pp, and we are asking ourselves something about what f(x)f(x) is doing. This should hopefully motivate our definition of limits. Let's see if we can make a precise definition below.

  • Limit (definition from Su based on Rudin): Let XX and YY be metric spaces where EXE\subset X, and let pp be a limit point of EE. Let f ⁣:EYf\colon E\to Y. So we have a space XX and a space YY, and we're only interested, perhaps, in some subset EE of the domain XX, and a function from this subset to YY perhaps:

    We have our set EE above, and we are going to be picking pp, a point that is a limit point of EE so it should be possible to converge or get closer and closer to pp in EE. And now we're asking does a particular limit exists? What does that mean intuitively from the picture above?

    We'll say our function has a limit, and we'll call it qq, if whenever we have a bunch of points getting closer and closer to pp then their images are getting closer and closer to qq:

    The way this potential definition has been described has largely been done almost as a sequence of points. That's one way to describe this limit, but let's first do this in terms of distances. We will develop a criterion that looks something like the convergence criterion for sequences. As a side note, we should observe that pp does not have to be in EE (it could be on the boundary), and there's no relationship between pp and qq necessarily other than the fact that as points get closer and closer to pp, the images of these points must be getting closer and closer to qq, but it need not be the case that qq is the image of pp.

    To say "f(x)qf(x)\to q as xpx\to p" or "limxpf(x)=q\lim_{x\to p}f(x)=q" means there exists qYq\in Y such that what? We know from previous calculus work, perhaps, that we will have something like "for every ϵ>0\epsilon>0 there exists a δ>0\delta>0 such that \ldots." Here we will have the same basic idea, but we will be dealing with an ϵ\epsilon-ball around qYq\in Y and a δ\delta-ball around pXp\in X where it is the δ\delta-ball that is in EE:

    Before, when we talked about sequences, we said that for any ϵ>0\epsilon>0 there is a point in the sequence beyond which you're close enough. Here we are going to say for ϵ>0\epsilon>0 there is a radius around pp for which if you're close in EXE\subset X then you're close in YY. This radius we will call δ\delta, and this is a δ\delta-ball, and it is the δ\delta-ball that is contained in EE.

    More precisely now, to say "f(x)qf(x)\to q as xpx\to p" or "limxpf(x)=q\lim_{x\to p}f(x)=q" means there exists qYq\in Y such that for all ϵ>0\epsilon>0 there exists δ>0\delta>0 such that for all xEx\in E, we have that 0<dX(x,p)<δ0<d_X(x,p)<\delta implies that dY(f(x),q)<ϵd_Y(f(x),q)<\epsilon. We should note that dXd_X and dYd_Y denote the metrics on XX and YY, respectively. If we were dealing with the real numbers with the usual metric, then we'd be dealing with absolute values or normed differences. A curious thing about this definition is that we've said we're not looking at all things in the δ\delta-ball. There's one point that we're not allowing ourselves to look at, namely the point x=px=p. The condition 0<dX(x,p)<δ0<d_X(x,p)<\delta excludes the possibility of having x=px=p. So we're allowing the image of pp to do whatever the heck it wants to do.

  • Limit (definition in [17]): Let XX and YY be metric spaces; suppose EXE\subset X, ff maps EE into YY, and pp is a limit point of EE. We write f(x)qf(x)\to q as xpx\to p, or

    limxpf(x)=q\lim_{x\to p}f(x)=q

    if there is a point qYq\in Y with the following property: For every ϵ>0\epsilon>0 there exists a δ>0\delta>0 such that

    dY(f(x),q)<ϵd_Y(f(x),q)<\epsilon

    for all points xEx\in E for which

    0<dX(x,p)<δ.0<d_X(x,p)<\delta.

    The symbols dXd_X and dYd_Y refer to the distances in XX and YY, respectively.

  • Classic example: We don't care what's happening at pp, only what's going on around it; that is, we should have f(x)qf(x)\to q as xpx\to p. And, of course, this should be from both directions in both cases:

    The above figure is the graph picture while

    is the mapping picture.

  • Example: We will consider an example where the limit does not exist:

    If xpx\to p, then is there are qq for which if you're close enough to pp then you're close enough to qq? No. We're converging to two different values from either direction. So there's no qq that will satisfy our definition.

  • Example: We don't require EE to contain pp. So maybe EE is an open interval and pp is an endpoint. The only thing we require is that pp be a limit point of EE. We want to be able to talk about a situation where maybe we have a function defined only on EE, and it still makes sense to talk about convergence to some qq:

    This is just pointing out all of the features of our limit definition.

  • Remarks: So if you want to show convergence of a sequence, for every ϵ>0\epsilon>0 you have to find an NN, an index. If you want to talk about convergence of a function, then for every ϵ>0\epsilon>0 you have to find a δ>0\delta>0. So your job to show convergence, given an ϵ>0\epsilon>0, is to find a δ>0\delta>0 that satisfies our definition.

  • Remark about convergence: We used balls in the picture

    to talk about convergence, but you could think about convergence in terms of points that are getting closer and closer to pp and their images getting closer and closer to qq. And so this brings up our first theorem about convergence of functions to limits of functions and that is it's equivalent to think of either way.

    So we could say limxpf(x)=q\lim_{x\to p}f(x)=q if and only if for all sequences {pn}E\{p_n\}\in E, where pnpp_n\neq p, and pnpp_n\to p, we have f(pn)qf(p_n)\to q, where the latter part of this biconditional is the sequence characterization of function limits. The picture you should have is the following:

    Let's see why this equivalence is true. Let's prove this. How are we going to prove this? Just go to the definitions! This is how we prove anything. To summarize, here is the biconditional we are trying to prove:

    limxpf(x)=q    ({pn}E)[(pnp)(pnp)    f(pn)q]((1))\lim_{x\to p}f(x)=q\iff (\forall \{p_n\}\in E)[(p_n\neq p)\land (p_n\to p)\implies f(p_n)\to q] \tag{(1)}

    It should be noted that the long proof that follows is succinctly given in [17].

  • Proof of forward direction: Given ϵ>0\epsilon>0, our goal is to find an NN that works. That is, we want to find a point in the sequence beyond which all of the f(pn)f(p_n) terms are within ϵ\epsilon of qq:

    When will it be the case that all of the f(pn)f(p_n) will be in the ϵ\epsilon-ball? For the ϵ\epsilon-ball pictured in the figure above, there must exist a corresponding δ\delta-ball that satisfies the limxpf(x)=q\lim_{x\to p}f(x)=q definition:

    So what point of the sequence f(pn)f(p_n) should we look at? The images of the points that are in the δ\delta-ball. That's the whole idea of the proof right there. We cab now write this up more precisely.

    Given ϵ>0\epsilon>0, there exists δ>0\delta>0 such that 0<dX(x,p)<δ0<d_X(x,p)<\delta implies that dY(f(x),q)<ϵd_Y(f(x),q)<\epsilon. For a given sequence {pn}\{p_n\} that satisfies the conditions just listed, there exists NN such that 0<dX(pn,p)<δ0<d_X(p_n,p)<\delta. Thus, nNn\geq N implies that dY(f(pn),q)<ϵd_Y(f(p_n),q)<\epsilon due to the fact that 0<dX(x,p)<δ0<d_X(x,p)<\delta implies that dY(f(x),q)<ϵd_Y(f(x),q)<\epsilon.

  • Proof of backward direction: Suppose for all sequences {pn}\{p_n\} in EE, where pnpp_n\neq p and pnpp_n\to p, we have f(pn)qf(p_n)\to q. We want to show that limxpf(x)=q\lim_{x\to p}f(x)=q. How can we do this? Instead of proving this directly, it might be easier to prove the contrapositive. Let's try that. So suppose that limxpf(x)q\lim_{x\to p}f(x)\neq q. We need to show that there exists {pn}\{p_n\} inEE, where pnpp_n\neq p and pnpp_n\to p, but f(pn)↛pf(p_n)\not\to p.

    To say that limxpf(x)=q\lim_{x\to p}f(x)=q is to say that

    (ϵ>0)(δ>0)(xE)(0<dX(x,p)<δ    dY(f(x),q)<ϵ).(\forall\epsilon>0)(\exists\delta>0)(\forall x\in E)(0<d_X(x,p)<\delta\implies d_Y(f(x),q)<\epsilon).

    Thus, to say that limxpf(x)q\lim_{x\to p}f(x)\neq q is to say that

    (ϵ>0)(δ>0)(xE)(0<dX(x,p)<δdY(f(x),q)ϵ).(\exists\epsilon>0)(\forall\delta>0)(\exists x\in E)(0<d_X(x,p)<\delta\land d_Y(f(x),q)\geq\epsilon).

    So, for the backward direction, assume that limxpf(x)q\lim_{x\to p}f(x)\neq q. That is, there exists ϵ>0\epsilon>0 such that for all δ>0\delta>0 there exists xEx\in E such that 0<dX(x,p)<δ0<d_X(x,p)<\delta and dY(f(x),q)ϵd_Y(f(x),q)\geq\epsilon. What does this mean? It means there is an ϵ\epsilon-ball around qq such that no matter what δ\delta-ball you give me around pp then you can find a point in EE such that the distance between pp and xx is smaller than δ\delta but the distance between their images is bigger than ϵ\epsilon.

    Can we use this information to construct a sequence that cannot converge to qq? Consider the following picture:

    We can see an ϵ\epsilon-ball around qq which should work:

    We will have problems landing in that ϵ\epsilon-ball, particular as xx approaches pp from the left. Now, we don't care which δ\delta is furnished. Suppose we have the following δ\delta-ball added to the picture:

    This δ\delta-ball is huge. We could make it very small. It doesn't matter. There will be a point xx in this δ\delta-ball which is close to pp but whose image is not ϵ\epsilon-close to qq; that is, there will exists a point xx such that 0<dX(x,p)<δ0<d_X(x,p)<\delta but dY(f(x),q)ϵd_Y(f(x),q)\geq\epsilon:

    So let's use this to find a sequence. What sequence should we construct that will approach pp but whose image will not approach qq? How about smaller and smaller δ\delta's? We propose such a bad sequence. Use δn=1n\delta_n=\frac{1}{n} (these δ\delta's get smaller and smaller) and choose xnx_n according to

    (ϵ>0)(δ>0)(xE)(0<dX(x,p)<δdY(f(x),q)ϵ).(\exists\epsilon>0)(\forall\delta>0)(\exists x\in E)(0<d_X(x,p)<\delta\land d_Y(f(x),q)\geq\epsilon).

    Then xnpx_n\to p, but dY(f(xn),q)ϵd_Y(f(x_n),q)\geq\epsilon by the condition above. Thus, f(xn)↛qf(x_n)\not\to q, thus concluding the proof.

  • Recap about sequence characterization versus ϵ\epsilon-δ\delta characterization: It doesn't matter if you want to talk about the sequence characterization or the ϵ\epsilon-δ\delta characterization. They are two ways of saying the same thing. They are equivalent. The nice thing about the sequence characterization is that we've already proved many theorems about sequences. And they all carry over now to limits of functions. So, for instance, what do you know about sequences? Limits of sequences are unique. So limits of functions will be as well. Let's list a few things out concerning theorems we know about sequences that will carry over to functions (below we should note that Y=RY=\R; otherwise, the results would not make sense unless YY were a greater Euclidean space where you could prove similar theorems as well):

    • Limits are unique.
    • Limits of sums are sums of limits.
    • Limits of products are products of limits.
  • Recap: So what do we have? We have described what it means for a function to have a limit. One of the places where this will be very important is to describe what it means for a function to be continuous.

Function continuity

How is continuity of functions defined, what are its uses, and what are some results?

  • Motivation: One of the most important concepts in analysis is the concept of a continuous function. This is a central concept of analysis, and we now have the machinery necessary to define what it means for a function to be continuous. First let's build some intuition. If I draw the graph of a function, what would you say is true about a continuous function? Is the following function continuous (where it's defined)?

    Is the following functions continuous where it's defined (just two points):

    Should the above function be called continuous? Maybe we take a look at a function that seems like it should clearly not be called continuous:

    Why would we say the above function is not continuous? The issue above is that as xpx\to p we have f(x)↛f(p)f(x)\not\to f(p) from the left:

    Even the following function is not continuous:

    The limit exists now, but we have the same problem as before. Here we have points converging to pp from both sides, and their images are converging too, but f(p)f(p) is something completely different from what their images are converging to. So, what does it mean for a function to be continuous? It means the function value at every point is what its limit suggests. That's the intuitive way to think about it. Let's make a definition now.

  • Continuity (definition from Su): Let XX and YY be metric spaces, and now are going to consider some subset EE of XX, but this time we will demand that pp be an element of the subset: pEXp\in E\subset X. So let XX and YY be metric spaces, where pEXp\in E\subset X, and f ⁣:EYf\colon E\to Y. We say ff is continuous at pp if for every ϵ>0\epsilon>0 there exists δ>0\delta>0 such that for all xEx\in E we have dX(x,p)<δd_X(x,p)<\delta implies that dY(f(x),f(p))<ϵd_Y(f(x),f(p))<\epsilon. More concisely, given metric spaces XX and YY, where pEXp\in E\subset X and f ⁣:EYf\colon E\to Y, we say ff is continuous given the following:

    (ϵ>0)(δ>0)(xE)(dX(x,p)<δ    dY(f(x),f(p))<ϵ).(\forall\epsilon>0)(\exists\delta>0)(\forall x\in E)(d_X(x,p)<\delta\implies d_Y(f(x),f(p))<\epsilon).

    Note that the limit condition 0<dX(x,p)<δ0<d_X(x,p)<\delta has been changed to dX(x,p)<δd_X(x,p)<\delta here because we may have x=px=p.

  • Continuity (definition in [17]): Suppose XX and YY are metric spaces, EXE\subset X, pEp\in E, and ff maps EE into YY. Then ff is said to be continuous at pp if for every ϵ>0\epsilon>0 there exists a δ>0\delta>0 such that

    dY(f(x),f(p))<ϵd_Y(f(x),f(p))<\epsilon

    for all points xEx\in E for which dX(x,p)<δd_X(x,p)<\delta. If ff is continuous at every point of EE, then ff is said to be continuous on EE.

  • Theorem (see [17]): If pp is a limit point of EE, then ff continuous at pp then this is equivalent to limxpf(x)=f(p)\lim_{x\to p}f(x)=f(p). Now, recall the sequence characterization in (1). So here's really what we are saying with this theorem: Suppose we look at the sequence characterization. What we're saying with

    limxpf(x)=f(p)\lim_{x\to p}f(x)=f(p)

    is that if you take a sequence converging to pp, then the limit of ff of the sequence is ff of the limit of the sequence. That is, if {xn}\{x_n\} is a convergent sequence, then ff continuous is equivalent to say limnf(xn)=f(limnxn)\lim_{n\to\infty}f(x_n)=f(\lim_{n\to\infty} x_n). In other words, for continuous functions, you can switch continuous functions and limits. It doesn't matter which order you apply them. That's a very important property. The limiting operation and the function operation commute when dealing with continuous functions.

  • Revisitation: Let's revisit an earlier figure:

    Is this function continuous? Well, there are only two points for which to check continuity. It doesn't matter. Let's just consider the point on the right:

    Is it true that ff is continuous at pp? Is it true that for every ϵ\epsilon you name there is a δ\delta around which as long as you're within some δ\delta of pp then you're within some ϵ\epsilon of f(p)f(p). So let's consider any ϵ\epsilon-ball around f(p)f(p), say the following:

    Can we find a δ\delta-ball around pp so that everything in the δ\delta-ball that is in EE also lands in the ϵ\epsilon-ball around f(p)f(p)? Sure:

    So is this function continuous? Yes! The δ\delta-ball has nothing else in it other than one point. This is a rather interesting example. This example actually illustrates something that holds in general: If you take a function from a discrete metric space to any other metric space, then your function will automatically be continuous, and this should make some intuitive sense because all of the points are separated in a discrete metric space. So you vacuously cannot approach points and the conditions for continuity hold in a rather trivial way.

  • Corollary for continuous functions: Sums, differences, products, and quotients for continuous functions are continuous as well, where it is clear our metric space Y=RY=\R in this case and also that g0g\neq0 when dealing with a quotient of the form fg\frac{f}{g}. This corollary is due to the "limit laws" we established as well as the limit point theorem we proved above.

  • Corollary (see [17]): Suppose we have vector-valued functions and we map a metric space into a vector. So let f,g ⁣:XRkf,g\colon X\to\R^k such that f=(f1,,fk)\bm{f}=(f_1,\ldots,f_k) and g=(g1,,gk)\bm{g}=(g_1,\ldots,g_k). Then we have the following:

    1. f\bm{f} is continuous if and only if each fif_i are continuous

    Proof. Why is this rule true? We just have to do some bounding. In one case we are trying to make the distance between two points small, namely the distance between f(x)f(x) and f(p)f(p). We want to make that distance small in one case. In the other case, we are trying to make the distance between fi(x)f_i(x) and fi(p)f_i(p) small. So if I have that one is small, can I show that the other is small? Is fi(x)fi(p)|f_i(x)-f_i(p)| somehow related to f(x)f(y)||f(x)-f(y)||? Yes, we also have components we are dealing with when looking at f(x)f(y))||f(x)-f(y))||. We always have the bound

    fi(x)fi(p)f(x)f(y).|f_i(x)-f_i(p)|\leq ||f(x)-f(y)||.

    We use this fact. If we make f(x)f(y)||f(x)-f(y)|| smaller than ϵ\epsilon for some δ\delta, then fi(x)fi(p)|f_i(x)-f_i(p)| will automatically be smaller than ϵ\epsilon for the same δ\delta.

    Now, what if we need to make f(x)f(y)||f(x)-f(y)|| small and we know fi(x)fi(p)|f_i(x)-f_i(p)| is always small? Well, if we know all fi(x)fi(p)|f_i(x)-f_i(p)| are small, then isn't f(x)f(y)||f(x)-f(y)|| just some combination of all of these; that is, f(x)f(y)=i=1kfi(x)fi(p)2||f(x)-f(y)||=\sqrt{\sum_{i=1}^k|f_i(x)-f_i(p)|^2}?

    1. f+g\bm{f}+\bm{g}, fg\bm{f}\cdot\bm{g} are continuous

    Proof. Use components from the first part. It follows from that.

  • Recap: What do we know so far? Well, we know what it means for a function to be continuous. We have two different characterizations of continuity (functions and sequences, one involving ϵ\epsilon's and δ\delta's and the other involving ϵ\epsilon's and a choice of NN). It turns out there is another characterization of continuity, and this one is, perhaps, not at all obvious.

  • Another characterization of continuity: There is a characterization of continuity in terms of open sets.

  • Continuity in terms of open sets (theorem; see [17]): The function f ⁣:XYf\colon X\to Y is continuous if and only if for all open sets UU in YY we have f1(U)f^{-1}(U) is open in XX. What does this have to do with continuity? What are we saying? Let's draw a picture:

    The claim is that ff will be continuous if for any open set UU we pick in YY, then it will have an inverse image f1(U)f^{-1}(U) in XX that is also open. Similarly, if it is the case that for every open set UU in YY that f1(U)f^{-1}(U) is open in XX, then ff is continuous. Why might this be true? Let's recall some of the functions we dealt with earlier:

    Let's deal with each of these functions separately, and see how the theorem is true or false depending on the function we are dealing with. For the first function, we said it's continuous. If we take an open set UU, then will its inverse image be open? Let's see:

    What does the above picture mean? The open set UU represents everything that falls in the ribbon, and f1(U)f^{-1}(U) is composed of the two intervals mapped to below the ribbon, where note these intervals are open (and recall the union of countably or uncountably many open sets is open). If we labeled the intervals I1I_1 and I2I_2, then fU=I1I2f^{U}=I_1\cup I_2. Since I1I_1 and I2I_2 are both open sets, then it follows that their union, and hence f1(U)f^{-1}(U), is also open. What about the second function? We would have the following:

    Here, the set f1(U)f^{-1}(U) is not open. It's half-open, and that should make sense because we knew from the start that ff was not continuous, and this picture supports our theorem; that is, we claim the inverse image, f1(U)f^{-1}(U) is not open because ff is not continuous. What about the last picture? We'd have the following:

    Is the point open in the two-point set? Discrete metric. Yes. So it works.

  • Proof idea: The definition of continuity just given, in terms of open sets and the like, is probably the most useful or best definition of continuity. Why?

    1. If you're a topologist, then you don't like referring to metrics necessarily. This is actually a definition of continuity that will hold for general topological spaces. You don't have to refer to distances or metrics. That's probably the best reason why it's a good definition. It's the most elegant in some sense. It just refers to the topology of the real line. You're only referring to what you consider to be open sets.

    2. It's also a question that often appears, in some way, on the Math GRE if you're going to graduate school for math. There's usually some question that tests your understanding of this definition.

    It would be informative to think of how you can prove the theorem under consideration using the ϵ\epsilon-δ\delta definition.

  • End note: If we replaced the "open set" conditions in our theorem with "closed set" then that's another definition of continuity. The inverse image of closed sets is closed. Why is that? By complements or "complementation." There are a number of different equivalent definitions of continuity.