# Lecture 5: Integrating Complex Functions

Flash and JavaScript are required for this feature.

Track Description: Herb Gross generalizes the definition of the integral of a real-valued function of a real variable to the integral of a complex-valued function of a complex variable and examines the ramifications of this generalization.

Instructor/speaker: Prof. Herbert Gross

The following content is provided under a Creative Commons license. Your support will help MIT OpenCourseWare continue to offer high quality educational resources for free. To make a donation or view additional materials from hundreds of MIT courses, visit MIT OpenCourseWare at ocw.mit.edu.

HERBERT GROSS: Hi. Today, we're going to conclude our survey of complex variables. And a rather fitting topic, I imagine, would be what it means to integrate a complex valued function of a complex variable. And I thought that that's what we would talk about today.

And in fact, let's just call today's lecture "Integrating Complex Functions." But let me emphasize, I really do mean by a complex function the thing that we've been stressing throughout the course, a complex valued function of a complex variable. The idea being that if you have a complex function of a real variable, essentially, this breaks down, as we've seen in the previous assignment, into studying regular functions of a single real variable.

In other words, if you have u of t plus iv of t, where t is a real variable, this really gives us no problem. This is sort of like the vector treatment, a vector function, of a scalar variable, et cetera. So what I'm saying here, though, is let's make sure that it's clear that we're still talking about mappings that map complex numbers into complex numbers.

Now by way of review, how did we define the definite integral in the case of a single real variable? We define the integral from x0 to x1 f of x dx to be a certain limit. Namely, we partitioned the interval from x0 to x1 into n pieces, calling the pieces delta x1 up to delta xn.

We took a number, say, c sub k star in the k partition, formed the sum f of c sub k star delta xk-- xk went from 1 to n-- and took that limit as the maximum-sized interval. The maximum delta x sub k went to 0. And if that limit existed, that was defined to be the definite integral.

Now, we did see a few other things along the way. But this is the main definition. You see, this is the definition that we're using. Some of the consequences of this definition were one, if we could find the function capital F, whose derivative was little f, then this integral was simply capital F of x1 minus capital F of x0.

And we also saw that if we wished, and we didn't have to, but if we wished, we could view this thing geometrically by observing that the x-axis was the domain of f. The y-axis was the range of f. We could then plot the curve y equals f of x, look at the area of the region R between x0 and x1, and the area of the region R was the value of this definite integral.

But the important point is what? That the definition of the integral is as a limit of an infinite sum. And now the question is, how shall we define the analogous thing for a complex valued function of a complex variable? In other words, what shall we mean by integral from z0 to z1, f of z dz?

And because we've been so successful with this technique in the past, it would seem that the simplest thing to do would be to simply replace x by z every place in this definition. In other words, let's simply do this. Let's define the integral z0 to z1 f of z dz to be the limit as the maximum delta z sub k approaches 0. Summation-- k goes from 1 to n, f of c sub k star times delta z sub k, where all we have done is replaced xs every place by zs wherever they appeared.

Now, the reason I've put question marks here is that all of a sudden, a problem occurs that never occurred in the real case. You see, the key reason that these problems are going to occur, as I'll explain in a moment, hinges on the fact that in the real case, the domain of f was one-dimensional. It was an axis, the x-axis.

In the complex variable case, the domain of f is two-dimensional. It's the entire xy plane, the Argand diagram. You see, the problem is simply this. What do you mean by delta z sub k? Intuitively, it certainly should seem to mean what? The line that joins the point in the Argand diagram z sub k minus 1 to the point z sub k.

In other words, remember, we view complex numbers as being vectors. They have a magnitude and a direction. So delta z sub k can be viewed as the vector which joins these two points.

The trouble is this. Let's take a look in the Argand diagram and locate the points z0 and z1. Here's z0. Here's z1. That's all that's given. Where shall these intermediary points z sub-- where should these intermediary points that are going to give rise to delta z sub k be?

In other words, there seem to be many points that we can pick for a partition. In particular, it would seem that the most natural definition would be to specify a particular curve C and then look at delta z sub k in terms of the curve C. Because you see once, the curve C is specified, if I partition things now, notice that the delta z sub ks do not connect random points, but rather points on the curve C.

The difficult point is that there are many different curves that join z0 to z1. So perhaps the first thing that we should do is, keeping in mind this ambiguity, maybe we should come back to this definition and put in a C to indicate that we're going to talk about the integral of f of z dz from the point z0 to the point z1 along the curve C, keeping in mind, you see, that the reason that we have to specify the curve here is that z0 and z1 are in the plane. You see?

Going back to this example here, notice that here, when we said let's go from x0 to x1, there was only one direction in which you could go from x0 to x1. Namely, since the domain of definition of f was the x-axis, the direction had to be in the direction of the x-axis. You see, in the Argand diagram case, I can go along any curve in the plane, provided that the curve connects the two points in question.

Now, the other question that I think I should point out here, even though it may be bringing up a question that you might not have anticipated-- notice that when I interpret the definite integral as an area here, notice that the lower bound is the domain of f itself. And the upper bound is already from the curve y equals f of x-- that the upper curve brings out the function here. You see, the x-axis is the domain. The y-axis is the range.

I would like you to observe that there is no similar interpretation along the curve C. In other words, if we were to drop perpendiculars from z0 to z1 down to the x-axis and talk about that area, that would be the wrong area to talk about. Because you see, the point is that that region is determined just by our domain.

Notice that this curve-- and this is very, very crucial-- that the curve that we're talking about here, C, has absolutely nothing in the world to do with this f of z. Just like when we computed mass using density, the density had nothing to do with the region that you were integrating with respect to. The point to observe here is that we're assuming that f of z is defined every place in the plane. f of z is defined here. It's defined here. It's defined here. It's also defined on the curve C.

Notice that f, in this case, is a complex number, which means that it has a real and imaginary part. f is no place in this diagram. And to plot what f does, I would have to use the uv plane because f itself is two-dimensional. In other words, I would need two dimensions for the domain and two dimensions for the range. And I hope that that part is fairly clear to you now. Don't confuse the path of integration with the integrand f of z. They are entirely different concepts.

At any rate, I hope that this does suggest the concept of a line integral in some sense. What I'm saying now is, OK, I want to integrate this from z0 to z1. That means I want to compute a particular limit. I picked the curve that joins z0 to z1.

Let's assume that in Cartesian coordinates, that curve parametrically has the form x is some function of t. y is some function of t, where t is a real variable. That's important. t is a real variable. By the way, as we mentioned when we were studying vectors, if I want to introduce vector notation, the radius vector, and write the curve C in vector form, notice that the curve C also has the form that r is x of ti plus y of tj.

And finally, if I now want to write the curve in terms of complex numbers-- after all, the Argand diagram now is the domain of the complex numbers. What is the connection between the xy plane and the Argand diagram? The x-axis names the real part, the y-axis, the imaginary part.

In other words, the unit-- we think of the i vector as representing the real part, the j vector as the imaginary part. Notice that changing this notation into the language of the Argand diagram results in this equation being replaced by z equals x of t plus iy of t. Where notice now that z is a complex valued function of the real variable t.

And t, of course, goes from some fixed value t0 to some fixed value t1. Because after all, what we're saying is that the curve Z equals x of t plus iy of t is being traced out in terms of t. When t0 corresponds to being at z0, t1 corresponds to being at z1.

The idea now is this. We go back to our definition of what the definite integral meant in terms of a limit. We observe that we'll assume that we'll make the further restriction that our curves are smooth, so that dz, dt will exist.

What we now do is go back to our infinite sum and multiply and divide by delta t sub k, the idea being-- notice that this is what? A complex valued function of a real variable. Because I can handle complex valued functions of a real variable-- namely, I just break them down into real and imaginary parts and use the same calculus that we used in part one of this course-- the idea is that with this suggestive notation, and remembering how the infinite sum gave rise to the integral notation, looking at this, you see we arrive at the fact that the integral from z0 to z1 along the curve C, f of z dz.

If we want to write that in terms of an integral involving a real variable t, it's simply what? The integral from t0 to t1 f of z of t. In other words, we're assuming that z is a function of t along the curve C-- we know what z looks like along the curve C in terms of t-- times the derivative of z with respect to t, z prime of t, times dt.

And we'll have plenty of exercises, including one in this lecture, to show you how we use this particular result. On the other hand, keep in mind that this is just what? One way of visualizing what the infinite sum is.

A second way to visualize the same problem is to recall that we very frequently like things in terms of u and v components, coordinates. The idea is that if we now want to introduce u and v in the usual manner, f of z is then u plus iv. Delta z is delta x plus i delta y.

And coming back to our basic definition over here, you see, what we can now do is rewrite f as u plus iv, rewrite delta z, sub k as delta x sub k plus i delta y sub k, multiply this thing out, pick off the real and the imaginary parts, write this as two separate sums, et cetera, and take the limit separately. What this leads to, if you want to go through the whole rigorous process quickly, just coming up with the right answer, is that essentially, what we do is, given this particular integral, we write f as u plus iv. We write dz as dx plus idy. Y

We then multiply the way we ordinarily would with complex numbers. See, udx minus vdy. And the imaginary part is vdx plus udy. Break this up as two separate integrals.

And the key point is notice that both of these integrals-- forgetting about the coefficient of here being i, this is the only place where i appears. Notice that both integrals are now ordinary line integrals. You see u as a real valued function of x and y. v is a real valued function of x and y. Along the curve C, x and y are functions of t.

Remember, the equation of the curve C was x was some function of t. y was some function of t. In other words, again, this is not only a line integral. But if you want to use this parametric form, both of these integrals involve real integrals of real variables. In other words, both u, v, dx, and dy are all expressible in terms of t and dt. And we can integrate this expression in the usual way.

But the reason I like the u and v form is that we've stressed what it means for a function to be analytic in terms of the real and imaginary parts, et cetera. Remember, keep an eye on this. Remember this particular expression here.

And here's the key point. If it turns out that u and v are the real and imaginary parts of an analytic function-- in other words, if u plus iv is some analytic function f-- remember that the Cauchy-Riemann conditions told us that the partial of u with respect to x is equal to the partial of v with respect to y. The partial of u with respect to y is minus the partial of v with respect to x.

And if you look at these two conditions coupled with our definition of what it meant for a real differential in two variables to be exact, notice that this condition here tells us that this is exact. And this condition here tells us that this is exact. In other words, both of these ordinary line integrals are exact if u plus iv is analytic. And again, if you want to leave the complex number part out of this, if all we know is that the partial of the real function u with respect to x equals the partial of the real valued function v with respect to y, et cetera.

And in particular then, because this is exact, what happened when a differential was exact? Remember, if the differential was exact, the line integral was what? Dependent only on the endpoints, but not on the path that connected the end points. Or stated in still other words, if the integrand was exact, the line integral around the closed curve was 0.

So what we're saying in summary is that notice that if f equals u plus iv is analytic, then the integral from z0 to z1 f of z dz is independent of C. It depends only on z0 and z1. And in that case, I do not have to specify what curve C is joining z0 and z1.

And in particular, if f of z happens to be analytic, so that this is exact, then the integral around a closed curve is 0 for all closed curves C. And that means again in particular, if I know that f of z is analytic, I do not have to indicate the curve that I'm forming the contour or integral around. You see? But I do have to put this in here if the function is not analytic.

And by the way, let me just make one more remark in passing. And we'll emphasize this more in the learning exercises. Not only is it true that integral z0 to z1 f of z dz depends only on the end points if f is analytic. But the parallel structure that is obeyed in the real case also is true here.

Namely, if f is analytic, not only does the integral from z0 to z1 f of z dz not depend on the path, but it can be evaluated very simply just by computing capital F of z1 minus capital F of z0, where capital F is any function whose derivative is little f-- the same structure as before. But-- and this is extremely important to note-- the integral around the closed curve C, f of z dz, need not be 0 if f is not analytic.

And I think the best way to show you that is by means of an example. Let's compute the integral around the closed curve C, dz over z, where C is the circle in the Argand diagram, centered at the origin with radius equal to r. And again, to emphasize what I said to you earlier in the lesson, do not confuse the integrand with the path C.

Notice that the integrand here is what? What is the integrand? It's 1 over z. Notice that 1 over z is defined at any point in the Argand plane, all right? Notice also from our previous lecture on derivatives that 1 over z is analytic, except when z equals 0, in which case 1 over z isn't even defined.

You see, what we're saying is notice that on the curve C, I can talk about f of 1 over z for each point on the curve. I can talk about 1 over z for every point inside the curve. I can talk about 1 over z for every point outside the curve.

What I want to compute here is the integral as I move along this curve-- 1 over z dz. Notice, by the way, that inside the interval, inside the circle, f of z is not analytic. f of z has a bad point. Namely, 1 over z is trouble when z equals 0.

And notice that z equals 0 is inside my region. In other words, notice that my function f of z is analytic on the circle, but it's not analytic every place inside the circle. The one bad spot is when z is 0.

So I do have a case where what? The integrand, which is 1 over z, is not analytic in the entire region, even though it does happen to be analytic on the boundary. You see, the boundary is made up of points, none of which is the origin because this is a circle of positive radius r centered at the origin.

And again, keep in mind that f does not appear in this diagram anywhere. If I wanted to plot 1 over z, I have to use the uv plane. If I want to think of this in terms of a real interpretation, what I'm saying is visualize a force, which when written in the language of complex variables, is 1 over z.

We don't have to worry about what that means. What it really means is write the real and the imaginary parts of this. And u is the real part, and v is the imaginary part. It's like computing the work as you go along this circle under the influence of that particular force.

And the force has two components, you see, an i and a j component-- in terms of the Argand diagram, a real and an imaginary component. So I can't stress that point too much. Separate the integrand from the path that you're integrating with respect to.

Now, what I claim is, is that if I integrate 1 over z along the curve C from beginning to end, let's say for the sake of definiteness, I start at the point 1 over here and go around-- at the point r and go around like this. I claim that this integral will not be 0. And I'm going to do it two ways for you, one which emphasizes the uv definition of integral, and one that emphasizes the f of z f prime dt definition.

Method one is what? To compute this particular integral, you simply write the integrand in terms of its real and imaginary parts and write dz as dx plus i dy. If I do that, I mechanically get from here to here, remembering that to get into the standard form of a real plus i times a real, I must multiply the denominator by its complex conjugate. I multiply the numerator and denominator here by x minus iy.

I then get this expression. You see x plus iy times x minus iy being x squared plus y squared. I now pick off the real and the imaginary parts. The real part here is xdx plus ydy because minus i times i is plus 1. The imaginary part is going to be minus ydx plus xdy. And so in terms of u and v components, this is the integral that I'm evaluating. And you see, notice that both of the integrands are line integrals-- real line integrals.

Now, notice that on C, how do I describe the curve C? Remember, I'm trying to go so that my area always stays to the left. I'm starting at this point. So why not write this parametrically as x equals capital R cosine theta and y equals capital R sine theta? You see?

That puts me in here when theta is 0, brings me around in the counterclockwise direction, back to the same point when theta is 2 pi. In other words, parametrically, the curve C is given how? x is our cosine theta. y is our sine theta.

I could have used t in here if I wanted to, but why bother? dx is just minus R sine theta d theta. dy is our cosine theta d theta. x squared plus y squared on C is just R squared. And theta goes continuously from 0 to 2pi.

So you see, if I now put all of this information into here, see, xdx is what? It's minus R squared sine theta cosine theta d theta. ydy is plus R squared sine theta cosine theta d theta. So therefore, the sum is 0. So therefore, this integral will be 0 because the integrand is 0.

On the other hand, minus ydx is minus R sine theta times minus R sine theta d theta. That's R squared sine squared theta d theta. xdy is R squared cosine squared theta d theta. So I add those together, and then I divide by R squared. And I have now converted this in terms of theta. So the integral goes from 0 to 2pi, the same as we did, you see, with ordinary line integrals.

And to summarize this for you, because I may have talked kind of fast, all we're saying is that the integral around the closed curve C, dz over z, is the real part is 0. And the imaginary part, the coefficient of i, is integral from 0 to 2pi R squared sine squared theta plus cosine squared theta d theta over R squared. Notice that R cannot be 0 because C is the circle of radius R centered at the origin.

On that circle-- I mean, R is a positive number, here. So it's just not 0. I can cancel the Rs because the radius of a circle can't be 0. And all I'm left with is sine squared theta plus cosine squared theta, which is 1. The integral d theta from 0 to 2pi is just 2pi. So this integral is just 2pi i. All right?

And the second method is to use the formula what? Integral f of z dz is the integral f of z of theta dz d theta times d theta. In this case, notice that the circle centered at the origin with radius R is given in polar complex form by z equals R e to the i theta.

Remember, in polar form, R is the magnitude. And theta is the angle. To say that you're on the circle of radius R centered origin simply says that the magnitude of the point must be R, the radius. And the angle can be any angle whatsoever between 0 and 2pi if you wanted to reverse the curve C just one time.

At any rate, from this, notice that dz d theta is simply what? iRe to the i theta. Therefore, dz over z around C is just the integral from 0 to 2pi. f of z of t-- in this case, that's f of z of theta-- that's 1 over z of theta. z of theta is Re to the i theta, dz d theta, which is this, times d theta.

You see, I've now converted this into a complex valued function of a real variable. At any rate, making all of these substitutions and simplifying, dz d theta being iRe to the i theta, and z being Re to the i theta, these cancel, leaving only a factor of i. The i comes outside. I have i integral 0 to 2pi d theta, which is just 2pi i. Again, notice the answers are the same because the techniques are equivalent.

Which of the two ways is better? It depends on yourself, as to which way you feel more comfortable with. It depends on the particular problem that you're dealing with and the like. We'll emphasize these things in the exercises. But for the time being, I just hope that you have a feeling as to what we mean by integrating a complex valued function around a particular contour.

And by the way, the subject called topology finds a natural inroad to the study of complex variables from this point of view. Namely, I call this "rubber sheet" geometry simply because of a properly that I'll mention for you in a few moments. But the idea is this. One of the very interesting factors about what we've just done, one of the interesting byproducts is this.

Let's suppose I'm integrating f of z dz along a simple curve C1. And let's suppose that C2 is another curve that encloses C1. And let's suppose that f is analytic on the boundaries C1 and C2 and also in the region between them.

In other words, I want to compute f of z dz along C1. I want to compute f of z dz along C2. And all I know is that f of z is analytic on and between C1 and C2.

Then the amazing result is that the integral around C1, f of z dz, is equal to the integral around C2, f of z dz. That's where the word "rubber sheet" geometry comes in. What you're saying is that if there are no bad spots between the two curves, if I were to visualize this curve as being a rubber band, by stretching that rubber band, I could make it take the form of the curve C2.

And what you're saying is given any curve that you're integrating around, if I can stretch that curve out into any position I want without breaking it, I stretch that curve out in such a way that as that curve is being stretched, it never goes through any points at which f of z fails to be analytic. Then it turns out that the integral around the new curve is the same as the integral around the old curve.

And the easiest way to prove this is by the method of making cuts here. Remember we showed in our lecture on Green's theorem that I could make a cut. Actually, in the lecture on Green's theorem, I made two cuts so that I could vividly show you the two separate pieces. All you need is one cut. See, let me cut the region this way.

And to emphasize what I've done here, I'll pull this apart just so that we can see what's happened here. You see, I've made the cut. And now, here's what I'm saying. This S and F stands for start and finish. You see, I'm going to start at this point here. I'm going to go along the simply connected region that I have here. Once I make the cut, this is a simply connected region.

Notice that if I go along here, I am doing what? I am integrating a complex valued function over a simply connected region, where the function is analytic. Consequently, whatever this integral turns out to be-- in other words, the integral f of z dz along this particular contour must be 0 by our previous result, that if a function is analytic, the integral around the closed curve is 0.

Now, here's the point. Notice that with this cut in here, when I look at the line integral, I traverse to cut twice-- once in one sense, once in the opposite sense-- so that cancels. See? That part cancels out. Notice that this integral around here, this part, is just the integral around the closed curve of C2 f of z dz because after all, we're assuming that this is together. I've just separated it here so that we can see what's happening.

Notice that the inner curve is C1, but in the opposite orientation. You see, C1 is traversed in this sense. But the inner curve here is traversed in the opposite sense. So this integrand is just minus the integral C1 f of z dz.

So if we put this whole thing together, what we have is that this integral with the cut along C is, on the one hand, 0. On the other hand, it's the integral around C2 f of z dz minus the integral around C1 f of z dz. Because this expression is 0, it means that this equals this. And that proves the result that we wanted. In other words, this must equal this because the difference is 0.

How is this useful in the theory of complex integration? Well, let me give you an example. Let's go back to our old friend, integrating dz over z along the closed curve C. But now, the closed curve C is going to be much messier than before. It's not going to be a nice circle. The closed curve C is going to be something like this. And what I'd like to do is to find the value of this integral along the curve C.

Now, the point is I could get into a mess trying to express C parametrically. But the beauty is what? First of all, notice that if C doesn't enclose the origin, the integral is just 0 because the only place that the integrand 1 over z fails to be analytic is when z is 0.

Consequently, if I were to take a region like this-- see, call this my C. If I were to take a region like this, notice that the integral around here would just be 0 because in and on this region, the function 1 over z is analytic. At any rate, I know that I'm in a bad situation here because my function fails to be analytic over here.

The integral around the closed curve doesn't have to be 0. However, what I do know is how to find the integral around this very nice curve C1, where C1 happens to be a circle centered at the origin. You see, the integral around C1 was just 2pi i. We did that in our earlier example.

The important point is to observe that between the circle C1 and the given curve C, in that particular region, including the two curves C and C1, the function 1 over z is analytic. Consequently, the integral dz over z along the curve C is the same as the integral dz over z along the curve C1. And therefore, its value will also be 2 pi i.

Now, at any rate, all I've tried to show you in this particular lecture, and I hope this part has come through fairly clearly, is the fact that we can handle complex valued functions in terms of integration and that this leads to a treatment of line integrals. It leads to examining certain types of line integrals along certain regions in the xy plane, which we can call the Argand diagram.

We will save applications or identifications with the real world for the exercises. But all I hope by now is that we have had a little bit of insight to the various aspects of mathematical analysis as it applies to complex variables. This winds up our treatment of complex variables as far as this course is concerned.

And next time, we will begin a new block of material and begin, again, a survey-type investigation of a subject known as ordinary differential equations. At any rate then, until next time, goodbye.

Funding for the publication of this video was provided by the Gabriella and Paul Rosenbaum Foundation. Help OCW continue to provide free and open access to MIT courses by making a donation at ocw.mit.edu/donate.