-
-
Now let's do a slightly fancier
example, then we'll try to
-
analyze the vector field.
-
And hopefully this will
make everything a little
-
bit more tangible.
-
So let's say that the velocity
of the fluid, or the particles
-
in the fluid, at any given
point in the x-y plane, let's
-
say in the x-direction, it is x
squared, x squared minus 3x
-
plus 2 in the x-direction, plus
y squared minus 3y plus
-
2 in the y-direction.
-
Make it simple so that we only
have one thing to factor.
-
So let's just do
the math first.
-
Let's figure out the divergence
of our vector field, the
-
divergence of our field.
-
And going to show you a graph
of this field soon, so we'll
-
get an intuition of what it
actually looks like, instead of
-
my not-so-accurate drawings.
-
So what's the divergence?
-
We take the partial derivative
of the x-component
-
with respect to x.
-
So that's just, there's only an
x-variable here, so we don't
-
really have to worry about
keeping y or z constant.
-
It's really just a derivative
of this expression
-
with respect to x.
-
So it's 2x minus 3.
-
And then we add that to the
partial derivative of the
-
y-component, or the y-function,
with respect to y.
-
There's only y's in the
y-component, so we just
-
take the derivative
with respect to y.
-
So it's plus 2y minus 3.
-
Or we could just say that the
divergence of v, at any point
-
xy, so this is a function of x
and y, is 2x plus 2y minus 3.
-
Now before I show you the
graph, let's analyze this
-
function a little bit.
-
First of all, let's just look
at the original vector field,
-
and think about when does that
vector field have some
-
interesting points?
-
Well, I think some interesting
points are when either the x-
-
or the y-components
are equal to 0.
-
So when is the
x-component equal to 0?
-
Well, if we factor the
x-component, that's the
-
same thing as, we could
rewrite our vector field.
-
If we just factored that,
that's x minus 1 times x minus
-
2i plus, and it's the same
polynomial, just with y, for
-
the y-component, so y minus
1 times y minus 2 times j.
-
So the x-component is 0 when x
is equal to 1, these are just
-
the roots of this polynomial,
when x is equal to
-
1 or 2, right?
-
And the y-component is 0
when y is equal to 1 or 2.
-
And they're both equal to 0
if we have any combination
-
of these points.
-
So the points where they're
both equal to 0 are 1, 1, x's
-
is 1, y is 2, right, because
then both components
-
are 0, 2, 1, or 2, 2.
-
So these are the points where
the magnitude of the velocity
-
of our fluid, or the particles
of the fluid, are 0.
-
And we'll see that on
our graph in a second.
-
And let me ask
another question.
-
At what points are, well, let's
first decide, what point is
-
the divergence equal to 0?
-
Let's say, at what point is
a divergence equal to 0.
-
Let me click clear
up some space.
-
I think I can delete this.
-
We got our points, we figured
out what coordinates are the
-
magnitude of the
vector field 0.
-
So let's try to figure out,
when is the divergence
-
equal to 0?
-
So this is divergence.
-
So if we set that equal
to 0, 2x plus 2y, 2x
-
plus 2y, oh, sorry.
-
You know what, this is 2x
minus 3 plus 2y minus 3.
-
So this is minus 6, right?
-
Minus 3 minus 3,
that's minus 6.
-
That's my major flaw,
adding and subtracting.
-
Anyway, so the divergence.
-
2x plus 2y, minus 6.
-
And we want to know,
when does that equal 0?
-
So let's set it equal to 0.
-
And we can simplify
this a little bit.
-
We can divide both sides of the
equation by 2, and you get x
-
plus y minus 3 is equal to 0.
-
You get x plus y is equal to 3.
-
We could be finished there, or
we could just put it in our
-
traditional mx plus b form,
that's the way I find it
-
easier to visualize a line.
-
We could say y is
equal to 3 minus x.
-
So along this line, the
divergence of the vector fields
-
b is equal to 0, along the line
y is equal to 3 minus x.
-
And if we're above that line,
the divergence is going to be
-
positive, right, because if you
just made this a greater than
-
sign, that would carry over.
-
You'd have y is
greater than 3-x.
-
So y greater than 3-x, the
divergence is positive.
-
And y is less than 3 minus x,
the divergence is negative.
-
And you could just make this a
less than sign then solve, and
-
you'll get y is less than 3-x,
you want to know when the
-
divergence is negative.
-
So I think we've done all of
the analyzing we can do.
-
So let's take a look at the
graph and see if it if it's
-
consistent with our intuition
of what a divergence is,
-
and the numbers we found.
-
-
I hope you can see this.
-
So this is the vector field.
-
I don't have space to show it,
but I think you remember, this
-
is, you know, x squared
minus 3x plus 2.
-
This is the definition
of our vector field.
-
Have it graphed here.
-
And we figured out, we just
figured out when the
-
x-components and the
y-components are equal to 0,
-
and then we said, when are
both of them equal to 0?
-
And we said, oh, well
at the point 1, 1.
-
Well, this is the point 1, 1,
and we that the magnitudes of
-
the vectors are 0
at that point.
-
And actually, I could
zoom in a little bit.
-
Right around here, they're all
pointing inwards,, but they get
-
smaller and smaller as you
approach the point 1, 1, right?
-
We also said at the point
1, 2. x is 1, y is 2.
-
And here, too, we see that
the magnitude of the vectors
-
get very, very, very small.
-
We could zoom in again.
-
And we see, the magnitude
gets very small.
-
The other point, 2, 1, once
again, we see the magnitude
-
get small, and then 2, 2.
-
So that's consistent with what
we found out, that the vector
-
field gets very small
at this point.
-
And the other interesting
thing we said, OK, when does
-
the divergence equal 0?
-
Well, the divergence equaled
0 along the line y is
-
equal to 3 minus x.
-
So the line y is equal to 3
minus x starts, the y-intercept
-
is going to be 3, and it's
going to come down like this.
-
Right?
-
So anything along, at any
point along that line,
-
the divergence is 0.
-
And if we actually look at
the graph, it makes sense.
-
Because I can't draw on this
graph, but if we drew a circle
-
right there, let's assume that
that's on that, the line y is
-
equal to 3 minus x, we would
see that in a given amount of
-
time, just as many particles
are entering through the top
-
right as leaving through
the bottom left, right?
-
A lot of entering through the
top right and a lot of leaving
-
through the bottom left.
-
And the vectors, though,
are about the same.
-
And if we go to the bottom, if
we go here on the line, it
-
looks like maybe there are less
entering, but there's
-
also less leaving.
-
I know it's hard to see, but
anywhere along the line,
-
you see just as much
entering as leaving.
-
And that's why the
divergence is 0.
-
Now, let's look at some
of the other points.
-
Up here, we figure the
diverge is positive.
-
And does that make
sense?
-
Let's pick an arbitrary point.
-
If we were to draw a circle
around here, we see the vectors
-
on the left-hand side of that
circle that you can't see,
-
because I can't draw
on this graph.
-
But actually, let's
just say the square.
-
Let's say the square
is my region, right?
-
This one right here.
-
If that square is my region,
we see the vectors on the
-
left-hand side are larger, than
factors leaving are larger than
-
the vectors entering it, right?
-
So if, in a given amount of
time, more is leaving than
-
entering, then I'm becoming
less dense, or you could say
-
that the particles
are diverging.
-
And that makes sense, because
I have a positive divergence.
-
And if we go here, where the
divergence is negative, let's
-
pick an arbitrary spot.
-
Let's say this
square right here.
-
We see that the vectors
entering it, the magnitude of
-
the vectors entering it, are
larger than the magnitude of
-
the vectors exiting it.
-
So in any given amount of time,
more is coming in than leaving.
-
So it's getting denser,
or it's converging.
-
So negative divergence, you can
view it as getting denser,
-
or it's actually converging.
-
Actually, something
interesting is happening
-
at these two points.
-
So we said that at the point
2, 1, we see that in the
-
y-direction it's actually
converging, right?
-
Above y is equal to 1, the
arrows are pointing down,
-
and below it the arrows
are pointing up, right?
-
So in the y-direction, we're
actually converging, or we
-
have a negative divergence.
-
Things are entering
any given spot.
-
But in the x-direction, things
are getting pushed out, right?
-
So the reason why the
divergence is 0 here, you might
-
have particles entering above
and below a certain space, but
-
you have just as many particles
exiting to the left
-
and the right.
-
So it's kind of like particles
are getting deflected out.
-
So on a net basis, between both
dimensions, you have no
-
increase or decrease in density
along that line y is
-
equal to 3 minus x.
-
And before I run out of time, I
just want to give you that core
-
intuition again, of why the
divergence is positive, and why
-
that means that things are
flowing out, when the rate
-
of change is positive.
-
So we said the
divergence is positive.
-
Let's say at the spot, right?
-
So it makes sense, if our
partial derivatives are
-
positive, that means that the
magnitude of our vector is
-
getting larger and larger for
larger values of our
-
x's and y's, right?
-
So if the magnitude of our
vectors are getting larger and
-
larger for larger values of x
and y, the vectors on the
-
right are going to have
a larger magnitude than
-
the factors on the left.
-
They're increasing
in magnitude.
-
And so if I were to draw a
boundary, more is going to
-
be coming out of the right
than entering to the left.
-
And so you have a positive
diverge, or you're
-
getting less dense.
-
Anyway, I hope I haven't
confused you too much,
-
but I have run out
of time once again.
-
I'll see you in the next video.