AFD Note01 PDF
AFD Note01 PDF
1 Vector analysis
Vector analysis is vital to fluid mechanics because the most fundamental descriptive quantity in
fluid flow, the velocity, is a vector. We’ll start with the three-dimensional Cartesian coordinate
system with unit vectors êx , êy and êz . Consider the vectors a = ax êx + ay êy + az êz and b =
bx êx + by êy + bz êz . The dot product (or scalar product) of a and b is
where | · | denotes the length, or magnitude, of a vector, and θ is the angle between the vectors.
The cross product (or vector product) of a and b, a × b, is more complicated. Its magnitude
is given by
1
Figure 1: The direction of the cross product a × b.
where θ is the (smallest) angle between a and b (i.e. θ ≤ 180◦ ). The direction of a × b is perpen-
dicular to the plane of a and b, in the right-hand sense of rotation from a to b through the angle θ
(Fig. 1). Because of this direction definition, the cross product anti-commutes, i.e. a × b = −b × a.
It turns out that the most convenient way to express the cross product is as a determinant –
êx êy êz
a × b = ax ay az = (ay bz − az by )êx + (az bx − ax bz )êy + (ax by − ay bx )êz (4)
bx by bz
Easily seen through (4) are the identities êx × êy = êz , êy × êz = êx , and êz × êx = êy .
Of particular interest is the operator ∇ (variously called the gradient operator, del operator, or
grad operator). We can write ∇ as
∂ ∂ ∂
∇ = êx + êy + êz (5)
∂x ∂y ∂z
∇ has no meaning unless it’s operating on something. The familiar operations are the gradient,
the divergence, the curl, and the Laplacian.
x = sx s
y = sy s
z = sz s (7)
Suppose we want to know the rate of change of φ in the s direction, at the origin. This dφ/ds is
also known as the directional derivative. By the chain rule, this can be written (note the selective
use of partial derivatives)
dφ ∂φ dx ∂φ dy ∂φ dz
= + +
ds ∂x ds ∂y ds ∂z ds
∂φ ∂φ ∂φ
= sx + sy + sz (8)
∂x ∂y ∂z
2
Figure 2: Sample volume for illustrating the divergence.
dφ
= ∇φ · ŝ (9)
ds
that is, the rate of change of a scalar function φ in an arbitrary direction is equal to the scalar
product of the gradient ∇φ with the unit vector, ŝ, in that direction. Using (3), we can also write
(since |ŝ|=1)
dφ
= |∇φ| cos θ (10)
ds
where θ is the angle between ∇φ and ês . So we can also say that dφ/ds is the projection of ∇φ
onto the direction s. Finally, observe from (10) that ∇φ is perpendicular to lines of constant φ.
We can go through similar arguments for the remaining faces, and we get
3
Now notice that we can rewrite (12) as
fx (x = dx) − fx (x = 0)
[fx (x = dx) − fx (x = 0)] dy dz = dx dy dz
dx
fx (x = dx) − fx (x = 0)
= dV
dx
∂fx
≈ dV (14)
∂x
where the last part is true in the limit of dx approaching zero. Similarly, the flux out of faces 2
and 5 can be written (∂fy /∂y) dV , and out of faces 3 and 6 can be written (∂fz /∂z) dV . Referring
back to (11), given a vector f , the net volume flux out of the volume dV equals the product of ∇ · f
and dV . Thus ∇ · f is a measure of the spread, or divergence, of the vector field f .
This somewhat non-rigorous analysis can be generalized as the divergence theorem. Given
an arbitrary volume V , enclosed by the surface S, with outward unit normal vector n at all points
on S, the divergence theorem states
Z Z
∇ · f dV = f · n dS. (15)
V S
This will be very useful when we get to the equations for fluid flow.
To see where the term ‘curl’ comes from, look at Fig. 2 again, but this time only consider face
6. Call this the surface S, with area dx dy = dS. We’ll define a direction of travel around the
border of S in the counter-clockwise direction. Assume also that the vector field f is constant on
each edge of S. Starting at the the origin, we first travel along the edge defined by y = 0. The
component of f parallel to the direction of travel on this edge is fx (y = 0). We can then define a
contour integral (a sort of net travel) as fx (y = 0) dx. The next edge is the one defined by x = dx,
along which the net travel fy (x = dx) dy. Going all the way back around to the origin, we end up
with (taking care with the signs)
Again, this last expression is true for dx and dy approaching zero. Comparing with (16), (17) is
just the z-component of ∇ × f . By the direction convention for integration around a closed contour,
êz is the normal vector for face 6 (our surface S) in Fig. 2 for the counter-clockwise integration
direction. Thus, the integral of f around the contour enclosing S equals the component of ∇ × f
in the direction normal to S multiplied by dS. In the context of the integration around the closed
contour, the use of the term ‘curl’ is obvious.
4
Figure 3: Direction convention for integration around a closed contour, C. The vector n̂ is the unit
normal to the surface.
Stokes’ theorem generalizes this. Let S be a two-dimensional surface enclosed by the curve
C. Then
Z Z
(∇ × f ) · n dS = f · dx (18)
S C
where the direction of the line integral relates to the direction of the normal vector n in the right-
hand sense (Fig. 3).
applying (6) and (11). The Laplacian is interesting in relation to quantities that undergo gradient
diffusion. An example is heat, which diffuses proportionally to the gradient in temperature. If we
let φ be the temperature and κ be the thermal diffusivity, then the temperature flux vector can be
written (note the minus sign)
The Laplacian can thus be interpreted by substituting −∇φ for f in the discussion of the divergence
in Sec. 1.2. That is, the Laplacian describes the net flux of the scalar quantity into a volume.
Consider a uniform temperature field with a sharp positive spike somewhere in it. The spike will
have a strongly negative Laplacian value, which means that heat will flow out from the region of
the spike, which makes sense, since diffusivity tends to smooth out sharp gradients. Another scalar
quantity that undergoes gradient diffusion is species concentration – a vector quantity that does is
momentum, but we will need more math tools to consider the diffusion of vector quantities.