# Green's theorem proof (part 2)

## Video transcript

Let's say we have the same path that we had in the last video. Draw my y-axis, that is my x-axis. Let's say the path looks like this, it looks something like this. It's the same one we had in the last video. Might not look exactly like it, let me see what I did in the last video. It looked like that in the last video, but close enough. Let's say we're dealing with the exact same curve as the last video. We could call that curve c. Now last video, we dealt with a vector field that only had vectors in the i direction. Let's build with another vector field that only has vectors in j direction, or the vertical direction. So let's say that q, the vector field q of xy, say it's equal to capital Q of xy times j, and we are going to concern ourselves we're going to concern ourselves with though closed line integral around the path c of q dot dr. And we've seen it already. dr can be rewritten as dx times i, plus dy times j. So if we were to take the dot product of these two, this line integral is going to be the exact same thing. This is going to be the same thing as the closed line integral over c of q dot dr. Well, Q only has a j-component. So if you take [? its ?] 0i, so 0 times dxs is 0, and then you're going to have Q xy times dy. They had no i-component, so this is just going to be Q, I'll switch to that same color again, Q of x and y times dy. That's the dot product. There was no i-component, that's why we lose the dx. Now let's see if there's any way that we can solve this line integral without having to resort to a third parameter, t. Just like we did in the last video. Actually, it will be almost identical, we're just dealing with y's now instead of x's. So what we can do is, we could say, well, what's our minimum y and our maximum y? So our minimum y, let's say it's right here. The minimum y, let's call that a. Let's say our maximum y that we attain is right over there. Let's call that b. Oh, and just like in the last, I forgot to tell you the direction of the curve. But this is the same path as last time, so we're going in a counterclockwise direction. The exact same curve, exact same path. So we're going in that direction. Now in the last video, we broke it up into two functions of x's, two y's as a function of x. Now we want to deal with y's. Let's break it up into two functions of y. So if we break this path into two paths, those are kind of our extreme points, let's call this past right here, let's call that path right there, let's call that y, let's call that x of-- so here, along this path, x is equal to-- or I could just write path 2, or a call it c2. We could say it's, x is equal to x2 of y. That's that path. And then the first path, or it doesn't have to be the first path, depending where you start. You can start anywhere. Let's say this one in magenta. We'll call that path 1, and we could say, that that's defined as x is equal to x1 of y. It's a little confusing when you have x as a function of y, but it's really completely analogous to what we did in the last video. We're literally just swapping x's and y. We're now expressing x as a function of y, instead of y as a function of x. So we have these two curves. You can imagine just flipping it, and we're doing the exact same thing that we did in the last videos, just now in terms of y. But if you look at it this way, this line integral can be rewritten as being equal to the integral, let's just do c2 first. This is the integral from b to a. We start at b, and we go to a. This is, we're coming back from a high y to a low y. The integral from b to a of Q of-- in that gray color. Q of, instead of having an x there, we know along this curve right here, x is equal to, we want everything in terms of y. So here, x is equal to x2 of y. So Q of x2 of y, x2 of y comma y, maybe I'm using too many colors here, but I think you get the idea. dy. So this is the part of the line integral, just over this left hand curve. And then we're going to add to that the line integral, or really just a regular integral now, from y is equal to a to y is equal to b of Q of, instead of x being equal to x2, now x is equal to x1 of y, it's equal to this curve, this other function. So x1 of y, x1 of y comma y, dy, and we can do exactly what we did in the previous video. Instead of, we don't like the larger number on the bottom, so let's swap these two around. So if you swap these two, if you make this into an a, and this into a b, that makes it the negative of the integral, when you swap the two, change the direction. This is exactly what we did in the last video, so hopefully it's nothing too fancy. But now that we have the same boundaries of integration, these two definite integrals, we can just write them as one definite integral. So this is going to be equal to the integral from a to b. And I'll write this one first, since it's positive. Of, I'll write in this one. Q of x1 of y comma y, minus this one. Right? We have the minus sign here. Minus q of x2 of y and y dy. Let me do that in that neutral color. dy, that's multiplied by all of these things. I distributed out the dy, I think you get the idea. This is identical to what we did in the last video. And this could be rewritten as, this is equal to the integral from a to b of, and inside of the integral, we're evaluating the function of Q of xy from the boundaries, the upper boundary, where, the upper boundary is going to be from x is equal to x1 of y, and the lower boundary is x is equal to x2 of y. Right? All the x's we substituted with that, and then we get some expression, and then from that, we subtract this with x substituted as x2 of y. That's exactly what we did, and just like I said in last video, we're going kind of the reverse direction that we normally go in definite integrals. We normally get to this, and then the next step is, we get this. But now we're going in the reverse direction, but it's all the same difference. And all of that times dy. And just like we saw in the last video, this, let me do it in orange, this expression right here, actually let me draw that dy a little further out so it doesn't get all congested. Let me do the dy out here. This expression, this entire expression, is the same exact thing as the integral from x is equal to, I can just write it here, let me write it in the same colors. x2 of y to x1 of y to x1 of y the partial of Q with respect to x dx. I want to make it very clear. This is, at least in my mind, the first part, a little confusing. But if you just saw an integral like this, this is the inside of a double integral. And it is. The outside is what we saw there, the integral from a to b, dy. But if you just saw this in a double integral, what you would do is you would take the antiderivative of this, the antiderivative of this with respect to x, the antiderivative of the partial of Q with respect to x with respect to x, is going to be just Q of xy. And since it's a definite integral, you would evaluate it at x1 of y, and then subtract from that, this function evaluated x2 of y, which is exactly what we did. So hopefully you appreciate that. And then we got our result, which is very similar to the last result. What does this double integral represent? It represents, well, anything, if you have any double integral that goes from-- if you imagine, this is some function, let me draw it in three dimensions. This is really almost a review of what we did in the last video. If that's the y-axis, that's our x-axis, that's our z-axis. This is some function of x and y, so some surface you can imagine on xy plane. It's some surface. So we could call that the partial of q with respect to x. And what this double integral is, this is essentially defining a region, and you can kind of view this dx times dy as kind of a small differential of area. So the region under question, the boundary points, are from y going from, y goes from, at the bottom, it goes from x2 of y, which we saw was a curve that looks something like this. That's the lower y, and over here, if we draw it in two dimensions, this was the lower y-curve. The upper y-curve is x1 of y, so the upper y-curve looks something like that. The upper y-curve goes something like that. So x varies from the lower y-curve to the upper y-curve, right? That's what we're doing right here. And then y varies from a to b. And so this is essentially saying, let's take the double integral over this region right here of this function. So it's essentially the volume, if this is the ceiling, and this boundary is essentially the wall. It's the volume of that room. And I don't know what it would look like when it comes up here. But you can kind of imagine something like that. It would be the volume of that. So that's what we're taking. This is the identical result we got in the last video. And this is a pretty neat thing. So all of a sudden, this vector, that-- and Q of xy, I didn't draw it out like I did the last time, Q of xy only has [? things ?] in the j-direction, so it only has, if I were to draw its vector field, the vectors only go up and down. They have no horizontal component to them. But we saw, when you start with a vector field like this, you take the line integral around this closed loop, and I'll rewrite it right here, you take this line integral around this closed loop of q dot dr, which is equal to the integral around the closed loop of Q of xy dy. We just figured out that that's equivalent to the double integral over the region. This is the region. Right? That's exactly what we're doing over here. If I just gave you the region, you'd have to define it, you'd say, well, x is going from, this is going from this function to that function, and y is going from a to b, and you might want to review the double integral videos, if that confuses you. So we're taking the double integral over the region of the partial of Q with respect to x, d-- well, you could write dx dy, or you can even right a little da, right? The differential of area, right, that we can imagine as a da, which is the same thing as a dx dy. And if we combine that with the last video, and this is kind of the neat bringing it all together part, the result of the last video was this. That if I had a function that's defined completely in terms of x, we had this, right here. We had that result. Actually, let me copy and paste both of these to a nice clean part of my whiteboard, and then we can do the exciting conclusion. Let me copy and paste that. So that's what we got in the last video. And this video, we got this result. I'll just copy and paste that part right there. You might already predict where this is going. And then let me paste it over here. This is the result from this video. Now let's think about an arbitrary vector field but is defined as, I'll do that in pink, let's say F is a vector field defined over the xy plane, and F is equal to P of xy i plus Q of xy j. You can almost imagine F being the addition of our vector fields, P and Q, that we did in the last two videos. Q was this video, and we did P in the video before that. But this is really any arbitrary vector field. And let's say we want to take the vector field, or sorry, the line integral of this vector field, along some path. It could be the same one we've done, which has been a very arbitrary one. It's really any arbitrary path. So let me draw some arbitrary path over here. Let's say, that is my arbitrary path, my arbitrary curve. Let's say it goes in that counterclockwise direction, just like that. And I'm interested in what the line integral, the closed line integral, around that path of F dot dr is. And we've seen it multiple times. dr is equal to dx i plus dy times j. So this line integral can be rewritten as, this is equal to the line integral around the path c. F dot dr, that's going to be this term times dx, so that's p of xy times dx plus this term, Q of xy times dy. And this whole thing, essentially this is the same thing as the line integral of p of xy dx, plus the line integral of Q of xy dy. Now what are these things? This is what we figured out in the first video, this is what we figured out just now in this video. This thing right here is the exact same thing as that over there. So this is going to be equal to the double integral over this region right here, of the minus partial of P with respect to y. Instead of a dy dx, we could say just over the differential of area. And then plus this one, this result. Q. This thing right here is exactly what we just proved, is exactly what we just showed in this video. So that's plus, I'll leave it up there, maybe I'll do it in the yellow, plus the double integral over the same region of the partial of Q with respect to x. da, where that's just dy dx, or dx dy, you can switch the order, it's the differential of area. And now, we can add these two integrals. What do we get? So this is equal to, and this is kind of our big, grand conclusion. Maybe magenta is called for here. The double integral over the region of, I'll write this one first because it's positive, that one's negative, of the partial of Q with respect to x, minus the partial of p with respect to y, d, the differential of area. This is our big takeaway. This is our big takeaway. Let me write it here. The line integral of the closed loop of F dot dr is equal to the double integral of this expression. And it's something, just remember. We're taking the function that was associated with the x-component, or the i-component, we're taking the partial with respect to y. And the function that was associated with the y-component, we're taking the partial with respect to x. And that first one, we're taking the negative of. That's a good way to remember it. But this result right here, this is, maybe I should write it in green, this is Green's Theorem. And it's a neat way to relate a line integral of a vector field that has these partial derivatives, assuming it has these partial derivatives, to the region, to a double integral of the region. Now, and this is a little bit of a side note, we've seen in several videos before, we've learned that if F is conservative, which means it's the gradient of some function, that it's path-independent, that the closed integral around any path is equal to 0. And that's still true. So that tells us that if F is conservative, this thing right here must be equal to 0. That's the only way that you're always going to enforce that this whole integral is going to be equal, is going to be equal to 0 over any, any, any region. I'm sure you could think of situations where they cancel each other out, but really over any region. That's the only way that this is going to be true. That these two things are going to be equal to 0. So then you could say, partial of Q with respect to x, minus the partial of P with respect to y, has to be equal to 0, or these two things have to equal each other. Or. This is kind of a corollary to Green's Theorem. Kind of a low-hanging fruit you could have figured out. The partial of Q with respect to x is equal to the partial of P with respect to y. And when you study exact equations in differential equations, you'll see this a lot more. And actually, well, I won't go into too much, but conservative fields, you're actually, the differential form of what you see in the line integrals, if it's conservative, it would be an exact equation. But we're not going to go into that too much. But hopefully you might see the parallels if you've already run into exact equations in differential equations. But this is the big takeaway, and let's maybe do some examples using this takeaway in the next video.