f (x) = f (2)    

First let's see if f (x) exists by checking the left-hand and right-hand limits. As x approaches 2 from the left, f (x) is defined by the function 2x2 - 2, so

f (x) = 2x2-2 = 2(2)2 - 2 = 6    

As x approaches 2 from the right, f (x) is defined by the function 5x - 4, so

f (x) = 5x-4 = 5(2) - 4 = 6    

Since

f (x) = f (x) = 6,    

we can say that

f (x) = 6.    

At x = 2, f (x) is defined by 2x2 - 2, so f (2) = 2(2)2 - 2 = 6. Now we have shown that

f (x) = f (2)    

which shows that f (x) is continuous at x = 2. Since f (x) is also continuous when x does not equal 2, f (x) is a continuous function. Below is a graph of f (x) to help you visualize what we have just done:

Figure %: A continuous (left) and discontinuous (right) function

The Intermediate Value Theorem

The intermediate value theorem says that if f is continuous on the closed interval [a, b], then f attains each of the values between f (a) and f (b) at least once on the open interval (a, b).

A real-life example may help here. The temperature at various times of the day is a good example of a continuous function. Let's say that at 6am, it is 46 degrees outside, and by noon, it is 67 degrees. By the intermediate value theorem, at some time between 6am and noon, the temperature outside must have been exactly 51.7 degrees. We can pick any value between 46 and 67 and be confident that that exact temperature was attained sometime between 6am and noon.

We can also understand the intermediate value theorem graphically. Below is a graph of a function f that is continuous on [a.b]. Note that every value between f (a) and f (b) is attained somewhere on the interval (a, b).

Figure %: Each value between f (a) and f (b) is attained somewhere on the interval (a, b)