Math Core

Lesson 5.1 · Vector Calculus

Vector fields

Wind velocity over a map, the gravitational pull at each point near the Earth, the flow of water in a pipe: each of these assigns a vector to every point of a region. Objects like this are called vector fields, and they are the main characters of this unit. Before you can integrate along curves and across surfaces, you need to be comfortable reading, sketching and computing with them.

What a vector field is

A function f(x,y)f(x, y) from the last units takes a point and returns a number. A vector field takes a point and returns a vector.

Definition

Vector field

A vector field on a region DD in the plane is a function F\mathbf{F} that assigns to each point (x,y)(x, y) in DD a two-dimensional vector

F(x,y)=⟨P(x,y), Q(x,y)⟩=P(x,y) i+Q(x,y) j.\mathbf{F}(x, y) = \langle P(x, y),\, Q(x, y) \rangle = P(x, y)\,\mathbf{i} + Q(x, y)\,\mathbf{j}.

A vector field on a solid region EE in space assigns a three-dimensional vector F(x,y,z)=⟨P,Q,R⟩\mathbf{F}(x, y, z) = \langle P, Q, R \rangle to each point. The scalar functions PP, QQ, RR are the component functions of F\mathbf{F}.

Evaluating a vector field is just evaluating each component. If F(x,y)=⟨x2−y, 3xy⟩\mathbf{F}(x, y) = \langle x^2 - y,\ 3xy \rangle, then F(1,2)=⟨1−2, 6⟩=⟨−1,6⟩\mathbf{F}(1, 2) = \langle 1 - 2,\ 6 \rangle = \langle -1, 6 \rangle.

Drawing a vector field

To picture F\mathbf{F}, pick a grid of sample points and draw the vector F(x,y)\mathbf{F}(x, y) as an arrow located at (x,y)(x, y). Real vectors are often too long to fit, so plots scale every arrow down by the same factor. The directions and the relative lengths are what you read from the picture.

Take the rotation field F(x,y)=⟨−y,x⟩\mathbf{F}(x, y) = \langle -y, x \rangle. At (1,0)(1, 0) it points straight up, ⟨0,1⟩\langle 0, 1 \rangle; at (0,1)(0, 1) it points left, ⟨−1,0⟩\langle -1, 0 \rangle. In general F(x,y)⋅⟨x,y⟩=−xy+yx=0\mathbf{F}(x, y) \cdot \langle x, y \rangle = -xy + yx = 0, so each arrow is perpendicular to the position vector, and ∣F(x,y)∣=x2+y2|\mathbf{F}(x, y)| = \sqrt{x^2 + y^2}, so arrows get longer as you move away from the origin.

F(x, y) = ⟨−y, x⟩: counterclockwise rotation, with arrows growing longer away from the origin (arrows scaled down).Open in grapher →

Compare the radial field G(x,y)=⟨x,y⟩\mathbf{G}(x, y) = \langle x, y \rangle, where every arrow points directly away from the origin.

G(x, y) = ⟨x, y⟩: every arrow points away from the origin.Open in grapher →

A quick way to sketch any field by hand: find where it is zero, check what it does on the axes, then check a few diagonal points. You rarely need more than a dozen arrows to recognize the pattern.

Worked example: Reading a field from its formula

Describe F(x,y)=⟨1,x⟩\mathbf{F}(x, y) = \langle 1, x \rangle.

The first component is always 11, so every arrow has a rightward part of the same size. The second component equals xx: on the yy-axis the arrows are horizontal, to the right of it they tilt upward (more steeply as xx grows), and to the left they tilt downward. Nothing depends on yy, so the picture looks the same along every vertical line. Moving along the field from any point you trace out a parabola y=12x2+Cy = \tfrac{1}{2}x^2 + C, because the slope of the arrow at (x,y)(x, y) is x1=x\dfrac{x}{1} = x.

Gradient fields

You have already met one very important family of vector fields. If ff is a differentiable function of two or three variables, its gradient

∇f=⟨fx,fy⟩or∇f=⟨fx,fy,fz⟩\nabla f = \langle f_x, f_y \rangle \qquad \text{or} \qquad \nabla f = \langle f_x, f_y, f_z \rangle

is a vector field, called a gradient field. At each point it points in the direction of fastest increase of ff and is perpendicular to the level curve (or level surface) through that point.

Conservative fields

A vector field F\mathbf{F} is conservative if F=∇f\mathbf{F} = \nabla f for some scalar function ff. The function ff is called a potential function for F\mathbf{F}.

The name comes from physics: when a force field is conservative, mechanical energy is conserved. In the next two lessons you'll see why conservative fields make line integrals dramatically easier, and how to test whether a field is conservative.

Worked example: Computing a gradient field

Let f(x,y,z)=x2y−yz3f(x, y, z) = x^2 y - yz^3. Find ∇f\nabla f and evaluate it at (1,−1,2)(1, -1, 2).

∇f=⟨2xy, x2−z3, −3yz2⟩.\nabla f = \langle 2xy,\ x^2 - z^3,\ -3yz^2 \rangle.

At (1,−1,2)(1, -1, 2): ∇f=⟨2(1)(−1), 1−8, −3(−1)(4)⟩=⟨−2,−7,12⟩\nabla f = \langle 2(1)(-1),\ 1 - 8,\ -3(-1)(4) \rangle = \langle -2, -7, 12 \rangle.

Fields in space and inverse-square fields

Three-dimensional fields work the same way, although they are harder to draw. The most famous one is the gravitational field of a mass MM at the origin. Write r=⟨x,y,z⟩\mathbf{r} = \langle x, y, z \rangle and r=∣r∣r = |\mathbf{r}|. Newton's law says

F(x,y,z)=−GMr3 r,\mathbf{F}(x, y, z) = -\frac{GM}{r^3}\,\mathbf{r},

which points toward the origin and has magnitude GMr2\dfrac{GM}{r^2}: an inverse-square field. The electric field of a point charge has the same shape. These fields reappear at the end of the unit, where the divergence theorem explains Gauss's law.

Worked example: Magnitude of an inverse-square field

Let F(x,y,z)=⟨x,y,z⟩(x2+y2+z2)3/2\mathbf{F}(x, y, z) = \dfrac{\langle x, y, z \rangle}{(x^2 + y^2 + z^2)^{3/2}}. Find ∣F(2,−1,2)∣|\mathbf{F}(2, -1, 2)|.

Here r=4+1+4=3r = \sqrt{4 + 1 + 4} = 3. Since F=r/r3\mathbf{F} = \mathbf{r}/r^3, its magnitude is r/r3=1/r2=19r/r^3 = 1/r^2 = \dfrac{1}{9}.

Flow lines

If F\mathbf{F} is the velocity field of a fluid, a particle dropped into the fluid moves along a curve r(t)\mathbf{r}(t) whose velocity always matches the field: r′(t)=F(r(t))\mathbf{r}'(t) = \mathbf{F}(\mathbf{r}(t)). Such a curve is a flow line (or streamline). Geometrically, flow lines are curves that are tangent to the arrows at every point. For ⟨−y,x⟩\langle -y, x \rangle the flow lines are circles centered at the origin; for ⟨x,y⟩\langle x, y \rangle they are rays leaving the origin.

Common mistake

A vector field plot shows each vector as an arrow at its point, but the arrows are scaled. Don't read coordinates off an arrow's tip. Use the formula for exact values and the picture only for direction and relative size.

Tip

To check a sketch, compute F\mathbf{F} at two or three easy points such as (1,0)(1, 0), (0,1)(0, 1) and (1,1)(1, 1) and make sure the arrows you drew there point the right way.

Practice

Practice 1

Let F(x,y)=⟨x−y, xy⟩\mathbf{F}(x, y) = \langle x - y,\ xy \rangle. Find F(3,2)\mathbf{F}(3, 2).

Enter a point like (2, -3)

Practice 2

Let F(x,y,z)=⟨yz, xz, xy⟩\mathbf{F}(x, y, z) = \langle yz,\ xz,\ xy \rangle. Find F(1,2,3)\mathbf{F}(1, 2, 3).

Enter a point like (2, -3)

Practice 3

For the rotation field F(x,y)=⟨−y,x⟩\mathbf{F}(x, y) = \langle -y, x \rangle, find ∣F(3,4)∣|\mathbf{F}(3, 4)|.

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 4

Let f(x,y)=x2y+y3f(x, y) = x^2 y + y^3. Find the gradient field ∇f\nabla f at the point (1,2)(1, 2).

Enter a point like (2, -3)

Practice 5

Which formula matches this vector field?

(-2 + -0.3005(t/pi - 1), -2 + 0.3005(t/pi - 1))(-2.3005 + 0.1592*abs(t/pi - 1) + -0.0847(t/pi - 1), -1.6995 + -0.1592*abs(t/pi - 1) + -0.0847(t/pi - 1))(-2 + -0.1503(t/pi - 1), -1 + 0.3005(t/pi - 1))(-2.1503 + 0.0796*abs(t/pi - 1) + -0.0847(t/pi - 1), -0.6995 + -0.1592*abs(t/pi - 1) + -0.0423(t/pi - 1))(-2 + 0(t/pi - 1), 0 + 0.3005(t/pi - 1))(-2 + 0*abs(t/pi - 1) + -0.0847(t/pi - 1), 0.3005 + -0.1592*abs(t/pi - 1) + 0(t/pi - 1))(-2 + 0.1503(t/pi - 1), 1 + 0.3005(t/pi - 1))(-1.8497 + -0.0796*abs(t/pi - 1) + -0.0847(t/pi - 1), 1.3005 + -0.1592*abs(t/pi - 1) + 0.0423(t/pi - 1))(-2 + 0.3005(t/pi - 1), 2 + 0.3005(t/pi - 1))(-1.6995 + -0.1592*abs(t/pi - 1) + -0.0847(t/pi - 1), 2.3005 + -0.1592*abs(t/pi - 1) + 0.0847(t/pi - 1))(-1 + -0.3005(t/pi - 1), -2 + 0.1503(t/pi - 1))(-1.3005 + 0.1592*abs(t/pi - 1) + -0.0423(t/pi - 1), -1.8497 + -0.0796*abs(t/pi - 1) + -0.0847(t/pi - 1))(-1 + -0.1503(t/pi - 1), -1 + 0.1503(t/pi - 1))(-1.1503 + 0.0796*abs(t/pi - 1) + -0.0423(t/pi - 1), -0.8497 + -0.0796*abs(t/pi - 1) + -0.0423(t/pi - 1))(-1 + 0(t/pi - 1), 0 + 0.1503(t/pi - 1))(-1 + 0*abs(t/pi - 1) + -0.0563(t/pi - 1), 0.1503 + -0.106*abs(t/pi - 1) + 0(t/pi - 1))(-1 + 0.1503(t/pi - 1), 1 + 0.1503(t/pi - 1))(-0.8497 + -0.0796*abs(t/pi - 1) + -0.0423(t/pi - 1), 1.1503 + -0.0796*abs(t/pi - 1) + 0.0423(t/pi - 1))(-1 + 0.3005(t/pi - 1), 2 + 0.1503(t/pi - 1))(-0.6995 + -0.1592*abs(t/pi - 1) + -0.0423(t/pi - 1), 2.1503 + -0.0796*abs(t/pi - 1) + 0.0847(t/pi - 1))(0 + -0.3005(t/pi - 1), -2 + 0(t/pi - 1))(-0.3005 + 0.1592*abs(t/pi - 1) + 0(t/pi - 1), -2 + 0*abs(t/pi - 1) + -0.0847(t/pi - 1))(0 + -0.1503(t/pi - 1), -1 + 0(t/pi - 1))(-0.1503 + 0.106*abs(t/pi - 1) + 0(t/pi - 1), -1 + 0*abs(t/pi - 1) + -0.0563(t/pi - 1))(0 + 0.1503(t/pi - 1), 1 + 0(t/pi - 1))(0.1503 + -0.106*abs(t/pi - 1) + 0(t/pi - 1), 1 + 0*abs(t/pi - 1) + 0.0563(t/pi - 1))(0 + 0.3005(t/pi - 1), 2 + 0(t/pi - 1))(0.3005 + -0.1592*abs(t/pi - 1) + 0(t/pi - 1), 2 + 0*abs(t/pi - 1) + 0.0847(t/pi - 1))(1 + -0.3005(t/pi - 1), -2 + -0.1503(t/pi - 1))(0.6995 + 0.1592*abs(t/pi - 1) + 0.0423(t/pi - 1), -2.1503 + 0.0796*abs(t/pi - 1) + -0.0847(t/pi - 1))(1 + -0.1503(t/pi - 1), -1 + -0.1503(t/pi - 1))(0.8497 + 0.0796*abs(t/pi - 1) + 0.0423(t/pi - 1), -1.1503 + 0.0796*abs(t/pi - 1) + -0.0423(t/pi - 1))(1 + 0(t/pi - 1), 0 + -0.1503(t/pi - 1))(1 + 0*abs(t/pi - 1) + 0.0563(t/pi - 1), -0.1503 + 0.106*abs(t/pi - 1) + 0(t/pi - 1))(1 + 0.1503(t/pi - 1), 1 + -0.1503(t/pi - 1))(1.1503 + -0.0796*abs(t/pi - 1) + 0.0423(t/pi - 1), 0.8497 + 0.0796*abs(t/pi - 1) + 0.0423(t/pi - 1))(1 + 0.3005(t/pi - 1), 2 + -0.1503(t/pi - 1))(1.3005 + -0.1592*abs(t/pi - 1) + 0.0423(t/pi - 1), 1.8497 + 0.0796*abs(t/pi - 1) + 0.0847(t/pi - 1))(2 + -0.3005(t/pi - 1), -2 + -0.3005(t/pi - 1))(1.6995 + 0.1592*abs(t/pi - 1) + 0.0847(t/pi - 1), -2.3005 + 0.1592*abs(t/pi - 1) + -0.0847(t/pi - 1))(2 + -0.1503(t/pi - 1), -1 + -0.3005(t/pi - 1))(1.8497 + 0.0796*abs(t/pi - 1) + 0.0847(t/pi - 1), -1.3005 + 0.1592*abs(t/pi - 1) + -0.0423(t/pi - 1))(2 + 0(t/pi - 1), 0 + -0.3005(t/pi - 1))(2 + 0*abs(t/pi - 1) + 0.0847(t/pi - 1), -0.3005 + 0.1592*abs(t/pi - 1) + 0(t/pi - 1))(2 + 0.1503(t/pi - 1), 1 + -0.3005(t/pi - 1))(2.1503 + -0.0796*abs(t/pi - 1) + 0.0847(t/pi - 1), 0.6995 + 0.1592*abs(t/pi - 1) + 0.0423(t/pi - 1))(2 + 0.3005(t/pi - 1), 2 + -0.3005(t/pi - 1))(2.3005 + -0.1592*abs(t/pi - 1) + 0.0847(t/pi - 1), 1.6995 + 0.1592*abs(t/pi - 1) + 0.0847(t/pi - 1))Open in grapher →
Practice 6

Let F(x,y)=⟨x,y⟩x2+y2\mathbf{F}(x, y) = \dfrac{\langle x, y \rangle}{x^2 + y^2}. Find ∣F(3,4)∣|\mathbf{F}(3, 4)|.

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 7

The flow lines of F(x,y)=⟨x,2y⟩\mathbf{F}(x, y) = \langle x, 2y \rangle satisfy x′(t)=xx'(t) = x and y′(t)=2yy'(t) = 2y. The flow line through (1,1)(1, 1) lies on a curve y=g(x)y = g(x). Find g(x)g(x).

Enter an expression, e.g. 3x^2 - 2x + 1

Practice 8

The conservative field F\mathbf{F} has potential function f(x,y)=xeyf(x, y) = xe^y. Find F(2,0)\mathbf{F}(2, 0).

Enter a point like (2, -3)