Today I want to start talking about calculus. And in this segment, first of all we look at derivatives and curvature, then integration, and then basic ideas of gradient, divergence and curl. So let's start with derivatives and curvature. So firstly, the definition of the derivative of the function is the local slope or rate of change of the curve. So for example if we have some function y equals a function of x we write the derivative as either y prime or f prime of x or dy by dx, which is define the limit as delta x tends to 0 of the function evaluated at x plus delta x, minus the function evaluated at x divided by delta x. Or in terms of y, that's the same as the limit as delta x tends to y of the delta y over delta x. So for example, if I have some function y of x like this and I'm interested in computing the gradient this point, then the derivative is delta y divided by delta x. And in the limit as delta y and delta x tends to zero, this tends to the slope or the gradient of the function at that point. For example, what is the slope of the curve, y = x squared- 3x + 10, evaluated at x = 4. Which one of these is it? So firstly, we can easily differentiate that function. dy by dx is generally equal to 2x- 3. So evaluating that function add x is equal to four we have dy by dx is equal to five. And so the answer is d. And what we've done here is this this is the graph of that function y as a function of x. And here we were asked to evaluate the slope at x is equal to four which is approximately here. So we just evaluated the gradient, so if I draw a tangent at this point then we found that the slope of this point is 5. In other words, it's a rise of 5 over a horizontal distance of 1. And that's the simple meaning of the first derivative of a function. In the reference handbook, they have a table of derivatives, and also integrals, which we'll talk about later, of the various functions. And this is an extract from that table. This is a partial list. In this table, 'uv' and 'w' are arbitrary functions of 'x' and 'ac' and 'm' are constants. So here are some typical derivatives and in this let's suppose, for example, we want to differentiate with respect to x, y is equal to sine x. So from this table, the last one here, number 16, we see that d of the general formula, d of sin u by dx, is equal to cos u, du by dx. So to make this specific to sine of x, we just substitute u = x into that formula. And then we have the sine of x, which we see is equal to cosine x dx by dx but dx by dx is one therefore the differential of sine x is cosine x. And you can use these simple rules to differentiate a number of different functions using this table. The other important thing that we'll use is the product rule, number 5 here, which says that the differential of the product of two functions, uv, is equal to u dv by dx plus v du by dx. And let's apply that to an example. The derivative of the function y equals sine 2 x cosine x, is which of these alternatives? So we're going to use our basic product rule here and in this then sine 2 x d x is u and cosine x is v. So therefore, dy by dx is u, which is sine 2x times the differential co-sin x d x which is minus sin x plus v which is co-sin x again. Times the derivative du by dx, derivative of sine 2x is 2 cosine 2x. So the answer is minus sine 2x sin x plus 2 cosine x cosine 2x, which is answer A. Now, also we're interested in critical points on graphs. In particular maxima, minima and inflection points. And the rules for testing for maximum and minimum and inflections are given in this extract from the handbook over on the right hand side. So, generally speaking we have a situation like this. Where here we have a local minimum, here a global minimum, in other words, an overall minimum of the function, local maximum, and an inflection point. And to find these, first of all, the maximum and minimum occur where dy by dx is equal to 0. In other words, F prime of x is equal to 0. So at these points the local slope of the curve is 0, in other words horizontal. And to find whether it's a maximum point, then the second derivative with respect to x at that point is negative, less than 0, or for a minimum the second derivative at that point is greater than 0. An inflection point is a change in the local slope so here for example we have a slope here. As we move up the curve the slope is increasing until we get to the inflection point here. And then beyond that point the slope of the curve starts to decrease. So the slope changes sine at that point. The second derivative of the slope changes sine. Now also, we can only differentiate with respect to one variable at a time. So if we have more than one independent variable, we have to take the partial derivative, whereby we treat all of the other variables as constants. So for example if we have z is some function of x and y, then the partial derivative of z with respect to x, which we write by means of these curly differential or d signs here as opposed to an ordinary d, is equal to partial d function of x and y by dx. Let me illustrate that with an example. Question is, what is the partial differential with respect to x of the function z = x squared y + 2x cubed y squared plus three. Which one of these is it? Well, we can differentiate, so starting from our original function, z is equal to x squared y plus two x cubed, et cetera. Then differentiating that once with respect to x. The differential of x squared is 2x. y is treated like a constant, so it just stays as y. The differential of 2x cubed is 6x squared and y squared again, just stays as it is, it's a constant. And the differential of a constant, finally at the end, is 0. So the answer is 2xy + 6x squared y squared, which is answer B. Another property which it's used for is the local curvature of a curve. And the curvature of a curve denoted here by K, although later on in mechanics and materials we'll use Kappa, is the limit of the average curvature of the arc as the point Q approaches P. But more useful for us is to express this in terms of derivatives and rectangular coordinates. And here the equation is K the curvature is equal to the second derivative, D 2 y by dx squared divided by one plus the first derivative. y prime squared all of that raised to the 3 1/2s power. And another very useful property is the inverse of that, the local radius of curvature r is 1 over the curvature and therefore, is given by this function. And the radius of curvature is always a positive number, so we just take the absolute value there. Let's do an example on that. The radius of curvature of the function y=2x(squared)-3x+5 evaluated the point with coordinates 3 and 14 is which of these? So, we're going to use this formula from the previous slide. So, here's the formula that we started with, y equals two x squared minus three x plus five. So, first I'll differentiate that once with respect to x. y prime or dy by dx is equal to 4x- 3. And evaluating that at the point x = 3, I get y prime = 9. The second derivative of this function, differentiating that again with respect to x, d2y by the x x squared is equal to 4. So now I can plug those values into my basic equation for curvature and I get 1 + 9 squared to three-halves over 4. And the answer is 185.6. So the closest answer is A. And this completes our elementary discussion of derivatives and curvature.