 This lesson is on continuous and differentiable functions. We are going to work on the constant function theorem, the racetrack theorem, and two theorems which are related, and they are the mean-value theorem and Rold's theorem. Our first theorem is the constant function theorem, and it reads, if a function is continuous over closed AB and differentiable over open AB because a function cannot be differentiable at its end point, and f prime is equal to 0 over open AB, then the function is a constant. This is very obvious because you already know that if you have a function y is equal to 5 and you take its derivative, it is equal to 0. Only they are saying this backwards. If you know a function has a derivative of 0, then you know it to be a constant function. And that's all there is to this particular theorem. So if you know the function's derivative is 0, then you know the function is a constant on an interval or over the entire function. Our second theorem is really called the racetrack principle, and it reads, given to functions f of x and g of x, if f prime of x is greater than or equal to g prime of x, then f of x is greater than g of x. And we can give an example of that. Let's say we have the function f of x is equal to x and g of x is equal to 2x. We know that f prime is equal to 1 here and g prime is equal to 2 there. We know that the function g of x equals 2x is greater than the function f of x equals x when x is greater than 0. In the racetrack principle, we need a starting point. In this case, it is at 0. And of course, the g prime of x is greater than the f prime of x when x is greater than 0. And of course we can say that vice versa. Given two functions f of x and g of x, if f prime of x is less than or equal to g prime of x, then f of x is less than or equal to g of x. Let's use the racetrack principle to show how to compare two functions. And the functions we want to compare are ln of x and x minus 1. Now if we put both of these functions on our calculator, our two functions are ln of x and x minus 1. If we graph these in a zoom 4, we see that the line is actually the tangent line to the curve of ln of x. And let's just check to make sure they are tangent. If we get an intersecting point, they will be tangent. So we'll go to second calc, intersect. And we'll get our first curve, our second curve, and it will come shortly. And they intersect at 1, x equal to 1 and y is equal to 0. So we do have that intersecting point. So we have a tangent line and a curve. Now if we look at this, before we get to the intersecting point, the slope on the tangent line is less than the slope on the curve. And this is because the curve has to reach the point of tangency. And then after that, the slope on the tangent line is greater than the slope on the curve. So this is what we have to show that the slope on one is less than the slope on the other before the point of tangency and after the point of tangency it is greater. We have the function here. f of x is equal to ln of x and g of x is equal to x minus 1. That's the line and the tangent line. So we take f prime of x and we get 1 over x. We take g prime of x and we get 1. And I said when x is between 0 and 1, the slope on the curve will be greater than the slope on the tangent line. And sure enough, any numbers that you put in here will be greater, 1 half, 1 fourth, 1 third, etc., etc., 3 fourths will be greater than 1. So f prime of x is greater than g prime of x. When x is greater than 1, then g prime should be greater than f prime. And if we put any number in here beyond 1 into your f prime, beyond 1, like 2, 3, 4, 5, 1.5, of course, that will be less than the g prime. So that means g prime of x will be greater than f prime of x. And that is how you use your racetrack principle to show one function is less than another function. Let's go on to another theorem, the mean value theorem. If f is continuous over closed a b and differentiable over open a b, then there exists a c between a and b such that f prime at c, the derivative of c, is equal to f of b minus f of a over b minus a. Well, let's look at this graphically. If we have a curve and we make a point a and a point b on the curve, and we draw the secant line that connects the two points, we have a slope of f of b minus f of a over b minus a. This theorem tells us that there is some point on our curve c somewhere where the slope of the line at c is equal to the slope between a and b. That's our mean value theorem. Well, let's do an example on that. Given f of x is equal to sine x over the interval 0 pi over 2, verify that f satisfies the hypotheses of the mean value theorem and find c. Well, one hypothesis is that it's continuous over 0 pi over 2 and sine is certainly continuous over 0 pi over 2, 2 that is differentiable over 0 pi over 2. Don't forget, these are parentheses, these are brackets. The sine wave definitely is differentiable over 0 pi over 2. So it's continuous and differentiable. Now we can find c. So the first thing we're going to do to find c is to take the derivative of sine. So f prime of x is equal to cosine x. The next thing we're going to do is to find f of b minus f of a over b minus a. f of b is the sine of pi over 2 which we know to be 1 minus the sine of 0 is 0 over b minus a which is pi over 2 minus 0 which is pi over 2 and that gives us 2 over pi. So now we know that cosine of c is equal to 2 over pi so that makes c equal to the arc cosine of 2 over pi. Well, let's look at our calculators and maybe we can see how this works on our calculator. So let's graph the function sine x and use a window of 0 to pi over 2 for x's and negative 1 to 1 for y's and our graph will look like this. Next I'm going to draw the tangent line at arc cosine of 2 over pi. So we'll use the draw function and tangent and do arc cosine of 2 divided by pi. There it comes. And now I'm going to draw the line that connects 0 and pi over 2. So go to the draw feature again. We're going to do a line and this time we're going to come down and go to the left. Get to 0, 0. Okay, press enter. Go to the right and bring it up to the end of my curve and we can see once I have done that that the two lines are indeed parallel to each other. Okay? So this is your mean value theorem. Let's go on to our next theorem. Roll's theorem. If f is continuous over closed A, B and differentiable over open A, B and f of A equals f of B and sometimes you will see that that has to equal 0 but it's not necessarily so. Then there exists a c between A and B such that f prime of c equals f of B minus f of A over B minus A. Well that's the mean value theorem but we're going to add one more thing to it. That has to equal 0. And that's because f of B and f of A are equal and if we drew this it would look something like this. This would be A, this would be B and this would be where c is, that horizontal tangent line. So let's do an example on this. Given f of x is equal to sine x over the interval 0 pi, verify that f satisfies the hypothesis of Roll's theorem and find c. So let's do that. So one, it's continuous over there at a pi, closed A, B. Two, it's differentiable over open A, B, 0 to pi and this one needs another piece to it. We have to verify that f of A equals f of B. So f of pi is equal to sine of pi which is equal to 0. f of 0 equals sine of 0 which is equal to 0. So f of A does equal f of B. So we'll go on and find c. So f prime of x is equal to cosine x f of B minus f of A over B minus A is equal to 0 minus 0 over pi so that's equal to 0. So now we have cosine x is equal to 0 therefore x is equal to pi over 2 which you already knew because the middle between 0 and pi is pi over 2 and that's where sine reaches its maximum point. This ends our discussion of theorems about continuous and differentiable functions.