Main content

### Course: Multivariable calculus > Unit 4

Lesson 4: Line integrals in vector fields (articles)# Flux in two dimensions

How line integrals can measure flow rate through a curve. Learning this is a good foundation for Green's divergence theorem.

## What we're building to

- Given a region enclosed by a curve
, and a fluid flow determined by a vector field${C}$ , the rate at which fluid is exiting that region (assuming it has density${F}(x,y)$ ) can be measured with the following line integral:$1$ Here, is some function that returns the outward unit normal vector at every point on the curve${\hat{\mathbf{\text{n}}}(x,y)}$ .${C}$ - This integral
is called a flux integral, or sometimes a "two-dimensional flux integral", since there is another similar notion in three dimensions.$\int}_{{C}}{\mathbf{\text{F}}}\cdot {\hat{\mathbf{\text{n}}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}{ds$ - In any two-dimensional context where something can be considered flowing, such as a fluid,
**two-dimensional flux is a measure of the flow rate through a curve**. In general, the curve isn't necessarily a closed loop.

## Changing fluid mass in a region

Suppose you have some two-dimensional vector field, ${\mathbf{\text{F}}(x,y)}$

And consider some closed curve $C$ wandering through this field.

As we like to do with vector fields, let's say this represents some kind of fluid flow. But let's limit ourselves to thinking about what happens over a very small amount of time, just a quick instance really. For example, you can imagine each fluid particle moving from the tail of one of the vectors drawn above to its tip.

Key question: How can we measure the instantaneous rate of change of the mass of fluid inside the region enclosed by? ${C}$

Specifically, let's say our fluid has a constant density throughout the plane, perhaps $1$ kilogram per square meter. If we let the fluid flow for a small amount of time, $\mathrm{\Delta}t$ , what is the total mass of fluid which leaves/enters the region? The answer, of course, will be some function of the vector field $\mathbf{\text{F}}$ and the curve $C$ .

If this question reminds you of the intuition for divergence, it's for a very good reason. In fact, in another article, we will use the formula we are now deriving to give the formal definition of divergence, and to show a special relationship divergence has with line integrals in two dimensions.

## One bit of length at a time

One way to answer this question is to break up the curve into many tiny segments and consider how much fluid leaves or enters each segment. If we zoom in on a small enough segment, we can basically treat it as a straight line, and the fluid particles going through it are pretty much all moving at the same speed and in the same direction.

As we let the fluid flow for the small change in time $\mathrm{\Delta}t$ , the fluid passing through this segment will form a parallelogram.

(I happened to draw a case where the fluid is going out of the region, but you could just as easily imagine the fluid coming into the region if the velocity vectors at that point were turned the other way.)

Since we are assuming a uniform density of $1{\textstyle \phantom{\rule{0.278em}{0ex}}}\text{kg}/{\text{m}}^{2}$ for the fluid, the mass of fluid leaving the region equals the area of this parallelogram. Let's break down that area.

- The base of the parallelogram is the length of our tiny segment. Let's call that
.$\mathrm{\Delta}s$ - The displacement vector of a fluid particle which starts at some point on the tiny segment will be
, where$\mathbf{\text{v}}\mathrm{\Delta}t$ is the velocity vector of fluid at that point, and$\mathbf{\text{v}}$ is the amount of time the fluid flowed.$\mathrm{\Delta}t$ - The height of the parallelogram will be the component of the
displacement vector which is perpendicular to the segment. You can extract this by taking the dot product between$\mathbf{\text{v}}\mathrm{\Delta}t$ and a unit normal vector to the curve$\mathbf{\text{v}}\mathrm{\Delta}t$ . Let's name that unit normal vector${C}$ .${\hat{\mathbf{\text{n}}}}$

**Concept check**: What is the total mass exiting the tiny segment of length

Dividing out by $\mathrm{\Delta}t$ , we have the amount of mass passing through this tiny line segment per unit time:

Exiting mass per unit time$=(\overrightarrow{\mathbf{\text{v}}}\cdot \hat{\mathbf{\text{n}}})(\mathrm{\Delta}s)$

## Bringing it together with an integral

Now think about ${C}$ , each with a tiny amount of mass exiting or entering through it per unit time. If you want to add up all those tiny changes in mass along the curve, what better tool is there than a line integral?

*all*of the tiny segments which make up the curveSpecifically, the line integral will look like this:

where

- The vector field
gives the fluid velocity at each point along the curve.${\mathbf{\text{F}}(x,y)}$ - The term
should be considered a function,${\hat{\mathbf{\text{n}}}}$ , which takes in a point on${\hat{\mathbf{\text{n}}}(x,y)}$ and outputs the unit normal vector to${C}$ at that point.${C}$ - Using the symbol
instead of$\oint$ is just to emphasize that the line integral is around a closed loop.$\int$ indicates a tiny change in arc length along the curve. Conceptually it is no different from the${ds}$ term in the previous section, but now we are considering it as an infinitesimal quantity used for integration.$\mathrm{\Delta}s$ - As you walk along the curve
, the value${C}$ measures how much the fluid is leaving/entering the region enclosed by${\mathbf{\text{F}}}\cdot {\hat{\mathbf{\text{n}}}}$ at each point. It is positive when the fluid is leaving, and negative when the fluid flows in, so the integral as a whole will return${C}$ **the total mass leaving the region enclosed by**. per unit time${C}$

More elaborately, you might write:

**Definition**: This flow rate through a curve is called

**flux**. More specifically, I should say the component of the flow rate which is

*perpendicular to the curve*is called flux.

Many things other than fluids in physics are considered to "flow", such as heat, and (loosely speaking) the electromagnetic field, and the word flux is used very broadly in reference to any one of these circumstances. It's most common for the word "flux" to refer to flow rate through a surface in three-dimensions. I will talk about this in the context of surface integrals later on. As such, you might call this flow rate through a curve "two-dimensional flux".

This integral $\oint}_{{C}}{\mathbf{\text{F}}}\cdot {\hat{\mathbf{\text{n}}}}{\textstyle \phantom{\rule{0.167em}{0ex}}}{ds$
is sometimes called a "flux integral", and as with all new operations, the best way to get a feel for it is to work through an example.

## Example: Flux through a circle

Consider the vector field

And draw a circle of radius $3$ centered at the origin.

From this picture, you might be able to guess that the fluid flowing along this vector field tends to go out of the circle. But how much? To apply the integral from the last section, we first need to do two things:

- Parameterize the circle.
- Find a function for
on the circle.$\hat{\mathbf{\text{n}}}$

We parameterize the circle using our friendly neighborhood cosine-sine parameterization:

For the parameterization to traverse the circle once and only once, let $t$ range from $0$ to $2\pi $ .

Which of the following functions gives the unit normal vector?

We can now apply this data to the line integral we found in the last section. (If you are uncomfortable with the computation of the line integral, consider reviewing the article on line integrals in a scalar field).

Once you have an integral in this form, you can just plug it into a calculator (or something like Wolfram Alpha) to get the numerical result:

## Computing a unit normal vector

You might be wondering how to compute the unit normal vector ${\hat{\mathbf{\text{n}}}}(x,y)$ for an arbitrary curve that is given to you. It felt like kind of a special case for the circle, didn't it? Well, luckily for you, constructing such a unit normal vector just so happens to be the topic of the next article.

I actually kind of lied to you when I said the unit normal vector is given with a function ${\hat{\mathbf{\text{n}}}}(x,y)$ with inputs on the $xy$ -plane. In practice, it is typically given as a parametric function ${\hat{\mathbf{\text{n}}}}(t)$ that "lines up" with the parameterization of the curve ${C}$ , so to speak. In principle, you should still think of it as acting on points in the $xy$ -plane, it's just that in practice you only end up defining it for points on the curve ${C}$ itself, since that's all you need. Don't worry, you'll see what I mean in the next article.

## Summary

- In any context where something can be considered flowing, such as a fluid,
**two-dimensional flux is a measure of the flow rate through a curve**. The flux over the boundary of a region can be used to measure whether whatever is flowing tends to go into or out of that region.

- The flux through a curve
can be measured with the line integral${C}$ where defines the vector field which indicates the flow rate.${\mathbf{\text{F}}(x,y)}$

is some function which return the outward unit normal vector at every point on the curve${\hat{\mathbf{\text{n}}}}$ .${C}$

## Want to join the conversation?

- isn't the line integral telling us about the mass flow only through the curve and not the area enclosed by it?(7 votes)
- Yes, but mass cannot flow into or out of the area enclosed without passing through the curve.(15 votes)

- You asked for the unit tangent vector in the article above when you intended to ask for the unit NORMAL vector?(12 votes)
- it's a unit normal vector you're decribing, which is what we should be calculating, but the question was misphrased; it was asking for the unit tangent vector(2 votes)

- I was re-doing the calculations knowing the formula for the unit normal vector, and I got n(r(t)) = [-3cos(t)/3, -3sin(t)/3], the negative of what Grant got. The article mentioned that if the top sign is reversed, it goes anti-clockwise, and visaversa if we reverse the bottom sign, but if you don't have a visual representation of the graph, how can you tell?

p.s the final answer comes out the same just negative(atleast for this example)(5 votes)- Imagine it like the derivative of the parametric path and you can see by its components in which quadrant the vector might be in and that really helps in deciding how the components need to change to make it orthogonal to path... without graphing the curve.(4 votes)

- Since you defined density to be constant everywhere that should mean the curl of the vector field should be zero. Therefore does that mean there exists a potential function for F. Could we use ∇f to make calculations easier here like we did for closed line integrals?

Sorry if my question makes no sense.(4 votes) - In the example of the circle, if I use the formula for finding the unit normal vector (As given in next article), I am getting -Cos(t) i - Sin(t) j. I differentiated r(t) to find tangent Vector and then divided by the magnitude which was 3, and then replaced the i and j values and made the x value negative, as it said in the article. Where did I go wrong?(3 votes)
- well since there are two normal orthogonal vectors, you need the one going outwards so you have to flip yours around(2 votes)

- the unit normal vector is simple the unit tangent vector T(t) = ( f'(t) / ||f'(t)|| ) multiplied by i ( 1 imaginary unit). T(t) * i(3 votes)
- There's a typo where 'specifical' is written instead of 'specifically' just fyi(2 votes)
- Why does he state, under the header--What we're building to", that "In general, the curve isn't necessarily a closed loop."?? I thought we were dealing exclusively with a closed loop.(2 votes)
- How should you tell which way to orient your unit normal vectors so that it points outwards, if you didn't have a graph?(1 vote)
- the author refers us to the article Line Integrals in a Scalar Field in preparation for the Flux through a circle problem and uses absolute value of r'(t) for the ds portion, yet the problem involves a vector field. Why is the absolute value of r'(t) and the method for a scalar field chosen?(1 vote)
- It is not the absolute value, but rather the magnitude of r'(t). Recall from the previous lessons that

dr/dt = x'(t) i + y'(t) j

Thus, the magnitude of r'(t) is:

||r'(t|| = √{(dx/dt)² + (dy/dt)² } = √{(dx)² + (dy)²}/(dt)²} = √{(dx)² + (dy)²} / dt = dS / dt

so dS = ||r'(t)|| * dt(1 vote)