Continuity

Karl Weierstrass (1815 – 1897) was the mathematician who (finally) formalized the definition of continuity. In that definition was the definition of limit. So, which came first – continuity or limit? The ideas and situations that required continuity could only be formalized with the concept of limit. So, looking at functions that are and are not continuous helps us understand what limits are and why we need them.

In the ideal world I mentioned last week, students would have plenty of work with continuous and not continuous functions. The vocabulary and notation, if not the formal definitions, would be used as early as possible. Then when students got to calculus, they would know the ideas and be ready to formalize the.

Using the definition of continuity to show that a function is or is not continuous at a point is a common question of the AP exams.

Continuity The definition of continuity.

Continuity Should continuity come before limits?

From One Side or the Other One-sided limits and one-sided differentiability

How to Tell Your Asymptote from a Hole in the Graph  From the technology series. Showing holes and asymptotes on a graphing calculator.

Fun with Continuity Defined everywhere and continuous nowhere. Continuous only at a single point.

Intermediate Weather  Using the IVT

Right Answer – Wrong Question Continuity or continuity on its domain

 

 

 

From One Side or the Other.

Recently, a reader wrote and suggested my post on continuity would be improved if I discussed one-sided continuity. This, along with one-sided differentiability, is today’s topic.

The definition of continuity requires that for a function to be continuous at a value x = a in its domain \underset{x\to a}{\mathop{\lim }}\,f\left( x \right)=f\left( a \right) and that both values are finite. That is, the limit as you approach the point in question be equal to the value at that point. This limit is a two-sided limit meaning that the limit is the same as x approaches a from both sides. That definition is extended to open intervals, by requiring that for a function to be continuous on an open interval, that it is continuous at every point of the interval

How do you check every point? One way is to prove the limit in the definition in general for any point in the open interval. Another is to develop a list of theorems that allow you to do this. For example, f(x) = x can be shown to be continuous at every number. Then sums, differences, and products, of this function allows you to extend the property to polynomials and then other functions.

But what about a function that has a domain that is not the entire number line? Something like f\left( x \right)=\sqrt{4-{{x}^{2}}},-2\le x\le 2. Here, f\left( -2 \right)=f\left( 2 \right)=0; the function is defined at the endpoints. A look at the graph shows a semi-circle that appears to contain the endpoints (–2, 0) and (2, 0). The function is continuous on the open interval (–2, 2) but cannot be continuous under the regular definition since the limit at the endpoints does not exist. The limit does not exist because the limit from the left at the left-endpoint, and the limit from the right at the right endpoint do not exist. What to do?

continuity

What is done is to require only that the one-sides limits from inside the domain exist. Here they do:\underset{x\to -2+}{\mathop{\lim }}\,f\left( x \right)=0  and the \underset{x\to 2-}{\mathop{\lim }}\,f\left( x \right)=0 and since the limits equal the values we say the function is continuous on the closed interval [–2, 2]. In general, when you say a function is continuous on a closed interval, you mean that the one-sided limits from inside the interval exist and equal the endpoint values.

You can determine that the limits exist by finding them as in the example above. Another way is to realize that if a < b < c < d and the function is continuous on the open (or closed) (a, d) then it is continuous on the closed interval [b c].

Why bother?

The reason we take this trouble is because for some reason the proof of the theorem under consideration requires that the endpoint value not only exist but hooks up with the function to make it continuous. Thus, the continuity on a closed interval is included in the hypotheses of theorem where this property is required. For example, the Intermediate Value Theorem would not work on a function that had no endpoints for f\left( c \right) to be between. Also, the Mean Value Theorem requires you to find the slope between the endpoints, so the endpoint needs to be not only defined, but attached to the rest of the function.

One-sided differentiability

The definition of the derivative at a point also requires a two-sided limit to exist at the point. Most of the early theorems in calculus require only that the function be differentiable on an open interval.

Is it possible to define differentiability at the endpoint of an interval? Yes. It’s done in the same way by using a one-sided limit. If x = a is the left endpoint of an interval, then the derivative from the right at that point is defined as

\displaystyle {f}'\left( a \right)=\underset{h\to 0+}{\mathop{\lim }}\,\frac{f\left( a+h \right)-f\left( a \right)}{h}.

By letting h approach 0 only from the right, you never consider values outside the interval. (At the right endpoint a similar definition is used with h\to 0-).

So why don’t we ever see one-sided derivatives? Because the theorems do not need them to prove their result. Hypotheses of theorems should be the minimum requirements needed, so if there is no need for the function to be differentiable at an endpoint, this is not listed in the hypotheses. This makes the hypothesis less restrictive and, therefore, covers more situations.

One theorem, beyond what is usually covered in beginning calculus, where endpoint differentiability is needed is Darboux’s Theorem. Darboux’s Theorem is sometime called the Intermediate Value Theorem for derivatives. It says that the derivative takes on all values between the derivatives at the endpoints, and thus needs the one-sided derivatives at the endpoints to exist. Interestingly, Darboux’s Theorem does not require the function to be continuous on the open interval between the endpoints.

.

Continuous Fun

The topic of this post is continuity. The phrase “a function is continuous on its domain” was much discussed last week on the AP Calculus Community bulletin board as it is about this time every year. This led to a discussion of one-sided continuity at the endpoint of an interval.

Let’s start by looking at some definitions related to continuity. A detailed discussion of definitions is worth doing in any math class; it helps students learn about the structure of mathematics. Definitions are biconditional statements; that is, either part implies the other.

Definitions related to Continuity

  1. A function is continuous at a point, (a, f(a)) if, and only if, (1) f(a) exists (is a finite number), and (2) \displaystyle \underset{x\to a}{\mathop{\lim }}\,f\left( x \right) exists (is a finite number), and (3) \displaystyle \underset{x\to a}{\mathop{\lim }}\,f\left( x \right)=f\left( a \right) – the limit equals the value.

This is the three-part definition you will find in most textbooks. The first two conditions are sort of for emphasis since the third is not possible if the limit does not exist (or is infinite) and/or the value does not exist (DNE). Graphically this means that as you move along the graph of f getting closer to the place where x = a the function values are getting closer to f(a). This is not always the case; specifically, if this does not happen the function is not continuous at the point.

For example, let  \displaystyle f\left( x \right)=\frac{x-3}{(x-2)(x-3)}

continuity 1

  • This function is undefined at x = 2 and x = 3; at both values f(x) DNE.
  • At x = 3 the limit does exist and is equal to 1. In this case the graph appears to be missing a single point, here (3, 1). This is called a removable discontinuity because be redefining the function so that f(3) = 1 the function could be made continuous.  This happens most often when the factor in the denominator that becomes zero “cancels” with a like factor in the numerator. This can also happen if the function value is defined as something different than the limit. There are other examples such as \displaystyle \frac{\sin \left( x \right)}{x} at x = 0
  • At x = 2 the limit DNE, and the situation appears as a vertical asymptote on the graph: on the left the values approach negative infinity and on the right they approach positive infinity. This is because a factor in the denominator gets very small as you approach 2.

Proving a function is continuous has been asked on AP Calculus exams. (See 2003 AB 6a and 2011 AB 6a) Students were expected to state the value of the two one-sided limits and the value of the function to show the three parts of the definition were true.

  1. A function is continuous on an open interval if, and only if, it is continuous at every point in the interval.

The definition of continuous at a point is extended to all the points of an interval. But do you have to check each and every point? No, this is determined by finding where the function is not continuous; the function is then continuous on the intervals between these points.

  1. In many theorems it is necessary to have a function be continuous on a closed interval; the endpoints must be included, but the limit in the main definition is a two-sided limit. The main definition is adapted to read A function is continuous from the right at x = a (or from the left at x = b) if, and only if, \displaystyle \underset{x\to a+}{\mathop{\lim }}\,f\left( x \right)=f\left( a \right)\text{ }\left( \underset{x\to b-}{\mathop{\lim }}\,f\left( x \right)=f\left( b \right) \right).

The limits are approached from inside the interval: from the right at the left end and from the left at the right end.

Continuous on its Domain

Functions exist only on their domain, so there is no way a function can be continuous except on its domain. I wrote about this is a previous post Right answer, Wrong Question.

When analyzing a new function one of the things you look for is where the function is continuous. But really you do this by looking for places where it is not continuous; everywhere else the function will be continuous.

Vertical asymptotes, removable discontinuities, and oscillating discontinuities are not possible for a function continuous on its domain; these appear on the graph, but mark places where the function DNE. The only kind of discontinuity a function may have on its domain are jump or step discontinuities. These often occur with piecewise defined functions where the endpoint of one piece is defined and different from the corresponding endpoint of the next piece. For example,

\displaystyle f\left( x \right)=\left\{ \begin{matrix} \sin \left( x \right) & 0\le x\le \pi \\ \cos \left( x \right) & \pi <x\le 2\pi \\ \end{matrix} \right.

  • Since f\left( \pi \right)=0 the function is defined there, but the limits of the two parts (0 and -1) are not the same, so the function is defined, but not continuous on its domain.

Another example is the greatest integer function (aka the floor function) whose graph is shown in below. Note that the left-endpoint of each segment (at the integer values) is included, while the right-endpoint at the next integer is not included.

continuity 2

Spotting discontinuities

Here are some hints on looking for places where a function is not continuous:

  1. Look for the zeros of the denominators
  2. For piecewise functions check the places where the pieces change definition.
  3. For trigonometric functions, the sine and cosine are continuous for all x. Since the other trigonometric functions are defined in terms of the sine and cosine look places where the sine or cosine is zero and appears in the denominator of the definition.
  4. Function involving square roots and other even degree roots are not defined, and therefore not continuous where their arguments are negative. For example, \sqrt{4-{{x}^{2}}} is continuous on the closed interval [-2, 2] (using the definitions for closed intervals – one-sided limits), but not elsewhere.
  5. Use technology to graph the function; discontinuities usually show up. The exception is a removable discontinuity or an oscillating discontinuity which may not show up because the x-value of the discontinuity may not be a pixel coordinate.

Pathological Examples

  1. This function, attributed to Dirichlet, is defined for all Real numbers, but not continuous anywhere.

f\left( x \right)=\left\{ \begin{matrix} 1 & \text{if }x\text{ is irrational} \\ 0 & \text{if }x\text{ is rational} \\ \end{matrix} \right.

  • Between every pair of irrational numbers is a rational number, and between every pair of rational numbers is an irrational number.
  1. With a slight variation, we have this function:

\displaystyle g\left( x \right)=\left\{ \begin{matrix} 1 & \text{if }x\text{ is irrational} \\ x & \text{if }x\text{ is rational} \\ \end{matrix} \right.

  • This function is defined for all Real numbers and is continuous at only one point (1, 1). Go figure.

.

Right Answer – Wrong Question

About this time every year the AP Calculus Community discussion turns to the sentence, “A function is continuous on its domain.” Functions such as f\left( x \right)=\frac{1}{x} cause confusion – is it continuous or not?  The confusion comes, I think, from the way we introduce continuity to new calculus students.

We say – and I did say this myself just last week – that the graph of a continuous function can be drawn without taking your pencil off the paper. That idea helps students get a start on understanding what continuity means, but it is not quite correct.

The definition of continuity requires that for a function to be continuous at a point, the limit at that point equals the value there (and that both the limit and value be finite). The only way a function can have a value at a point is if the point is in the domain. So, the definition of continuity can be applied only at points in the domain. If the domain of the function is not all Real numbers, then the function cannot be continuous “everywhere;” rather it can only be continuous on its domain. (And, of course, there are many examples of functions that are not continuous at all points in their domains.)

So what do you say about a function like f\left( x \right)=\frac{1}{x}?

Its domain is all Real numbers x\ne 0. The function is continuous at all the points in its domain and so it is continuous on its domain.

But that statement does not tell the whole story. We asked the wrong question. We should ask where the function is not continuous. If we ask where this function is not continuous, the answer is that the function is not continuous at x = 0. Asking where a function is not continuous requires that we consider the entire number line, all Real numbers. The answer often provides better information.

So then, obviously a function is not continuous at any and all the points not in its domain (plus perhaps some other points in its domain). Accepting that a function is continuous on its domain, even if correct, does give us as much information as asking where a function is not continuous.

Ask the right question!

Continuity 2

The definition of continuity of a function used in most first-year calculus textbooks reads something like this:

A function f is continuous at x = a if, and only if,

(1) f(a) exists (the value is a finite number),

(2) \underset{x\to a}{\mathop{\lim }}\,f\left( x \right) exists (the limit is a finite number), and

(3) \underset{x\to a}{\mathop{\lim }}\,f\left( x \right)=f\left( a \right) (the limit equals the value).

A function is continuous on an interval if, and only if, it is continuous at all values of the interval. For the endpoints of closed intervals, the limits are adjusted to one-sided limits with x approaching a from inside the interval.

As I’ve written before, limits logically come before continuity since limits are used in the definition of continuity. But as a practical and historical matter continuity comes first. Continuity, or rather lack of continuity, gives us the examples that motivate the need for the concept of limit.

Karl Weierstrass (1815 – 1897) gave the modern definition of continuity: Given a function f and an element a of the domain I,   f is said to be continuous at the point a if for any number \varepsilon >0, however small, there exists a number \delta >0 such that for all x in the domain of f\left| x-a \right|<\delta  implies \left| f\left( x \right)-f\left( a \right) \right|<\varepsilon .

This looks very much like the definition of limit. In the delta-epsilon definition of limit the last inequality above is \left| f\left( x \right)-L \right|<\varepsilon  where L is the limit. Replacing the value with the limit allows a somewhat simpler wording of the definition of continuity than that given at the beginning, but adds the delta-epsilon complication. Weierstrass’ definition eliminates the need for saying the value and the limit are finite since that is assumed by writing f (a).

Some textbooks use the phrase “a function is continuous on its domain.” This seems somewhat limiting (no pun intended) in that a function such as \displaystyle f\left( x \right)=\tfrac{1}{x} is certainly continuous on its domain but not continuous on the entire number line. We are usually concerned about where a function is not continuous, so first we find where it is not continuous: at the points not in its domain plus possibly other points in its domain.

Recent AP calculus exams (2012 AB4c, 2011 AB 6a) gave students a piecewise defined function and asked if it is continuous at the point where the two pieces meet. The question directed students to “use the definition of continuity to explain your answer” and “show that f is continuous.”  To answer the question students were expected to state what the two one-sided limits are and what the value there is. Since all these numbers are finite and equal the requirements of the definition are met.

This kind of question could be considered a question about continuity or a question about applying a definition (or theorem) to a particular situation. Either way students should understand the hypotheses of a definition or theorem and know how to verify that they are met in a particular situation.

Definitions

Definitions are similar to theorems, but are true in both directions; technically, this means that the statement and its converse are both true (p\leftrightarrow q). The double arrow is read “if, and only if.” Both parts are either true or both parts are false. Definitions usually name some thing or some property.  Definitions are not proved.

The definition of continuity is a good example: A function f is continuous at xa if, and only if, these three things are true

(1)  f\left( a \right) exist (i.e. is a finite number)

(2)  \underset{x\to a}{\mathop{\lim }}\,f\left( x \right) exist (i.e. is a finite number)

(3) \underset{x\to a}{\mathop{\lim }}\,f\left( x \right)=f\left( a \right)  (“The limit equals the value.”)

“Play” with it: consider cases where only 2 of the 3 requirements are true – is the function still continuous? What would happen if you removed the requirements about finite numbers?

To use a theorem, one must be sure all the hypotheses are true. To use a definition, one may say that either part is true once you have established that the other part is true. So, if you know a function is continuous at a point, then the three statements are true; or if you can show the three statements are true, you may say the function is continuous.

Here’s an example: A typical AP problem might give a piecewise defined function and ask if it is continuous at the place where the domain is divided.

To get credit for justifying an answer of “yes”, students must show that all the requirements of the definition are met. Specifically, they must show that the limit as x approaches that point must equal the value of  the function at that point (and both are finite).  In turn, to show that this limit exist the student must show that the hypotheses of the theorem that says if the two one-sided limits are equal to the same number, then that number is the limit.

To get credit for an answer of “no”, the student must show that (only) one of the hypotheses is false.

Finally, as with theorems, express definitions in words. With your students, “play” with the theorem or definition by making changes to the hypotheses and seeing how that affects the conclusion. Look at the graphs. Don’t just state the definition and expect students to understand it, remember it and use it correctly.

Fun with Continuity

Most functions we see in calculus are continuous everywhere or at all but a few points that can be easily identified. But consider the Dirichlet function:

Q\left( x \right)=\left\{ \begin{matrix} 1 & x\in \ rational\ numbers \\ 0 & x\in \ irrational\ numbers \\ \end{matrix} \right.

Since there is one (actually many) rational numbers between any two irrational number and one (many again) irrational numbers between any two rational numbers, this function is not continuous anywhere!

But a very similar function is continuous at exactly one point (1, 1):

f\left( x \right)=\left\{ \begin{matrix} 1 & x\in \ rational\ numbers \\ x & x\in \ irrational\ numbers \\ \end{matrix} \right.

Can you use this idea to make a function that is continuous at exactly two points?