Gradient (multivariable calculus)
The gradient is a vector of partial derivatives that indicates direction and rate of fastest increase of a multivariable function. It links geometry, optimization, and physical fields.
Overview. In multivariable calculus the gradient of a scalar function is a vector field that encodes both the direction in which the function increases most rapidly and the rate of that increase. The gradient is a central object in vector calculus and appears whenever one compares changes of a quantity with respect to several variables. The symbol ∇f (often read "nabla f") or the name grad f are commonly used to denote the gradient.
Definition and notation
For a real-valued function f(x1,…,xn) that is differentiable, the gradient ∇f is the n-dimensional vector of partial derivatives: ∇f = (∂f/∂x1, …, ∂f/∂xn). Each component measures how the function changes when one coordinate varies and the others are held fixed; these are the partial derivatives. The directional derivative of f in a unit direction u equals the dot product ∇f · u, so the gradient summarizes directional rates of change.
Geometric interpretation and properties
Geometrically, the gradient at a point points toward the steepest ascent of the function and its magnitude equals the maximal directional derivative at that point. It is perpendicular to level sets (contours) of f: in two dimensions the gradient is orthogonal to a curve of constant f, and in higher dimensions it is normal to level surfaces. These orthogonality and extremal properties make the gradient useful for locating maxima, minima, and saddle points.
Simple examples
- If f(x,y)=x^2+y^2, then ∇f=(2x,2y), which points away from the origin and whose length grows with distance.
- If f(x,y)=xy, then ∇f=(y,x); at the point (1,2) the gradient is (2,1), indicating a stronger increase in the x-direction there.
Applications and uses
The gradient appears in many fields. In numerical optimization methods such as gradient descent, the negative gradient gives a local direction to decrease a function and find minima. In physics, conservative force fields are gradients of potential energy, and many partial differential equations (heat, diffusion, Laplace) involve gradients. In image processing discrete approximations to gradients detect edges and transitions in intensity. More broadly, the gradient connects a scalar quantity to an associated vector field that describes spatial change.
Relations and notable facts
The gradient is closely linked with other differential operators: the divergence of a gradient gives the Laplacian, and in simply connected domains a vector field with zero curl can often be expressed as the gradient of some potential (a gradient field). The fundamental theorem for gradients states that the line integral of a gradient between two points equals the change in the underlying scalar function, a key fact in analysis and physics. For visual intuition see graphs and diagrams of surfaces and contour plots; a function's slope along a curve on such a graph equals the component of the gradient in the curve's direction. For basic illustrations consult introductory material on graphs of functions.

Definition
On let be
given the scalar product ⟨ The gradient
of the totally differentiable function
at the point
is the point given by the requirement
uniquely determined vector The operator
is the total differential or Cartan derivative.
For differentiable functions gradient has the defining property
for
The Landau symbol represents terms that
grow slower than , and
represents a linear function of
If the gradient exists, it is unique and can be derived from
where is the nabla operator. This is also how gradients are defined for scalar, vector, and second level tensor fields, or nth level tensor fields in general.
For a scalar field, it follows that ; therefore, one often writes
(pronounced "Nabla
") instead of
.
Coordinate representation
The gradient also has different representations in different coordinate systems.
Cartesian coordinates
In with the standard Euclidean scalar product, is
the column vector
The entries ∂ are the partial derivatives of
in
direction.
Calculation example
Given a scalar field by in the xy plane. It has partial derivatives ∂
and ∂
and it follows
or in vector representation
For example, for the point the gradient vector is
. The magnitude is
.
Cylinder and sphere coordinates
- Display in three-dimensional cylindrical coordinates:
- Display in three-dimensional spherical coordinates:
These are special cases of the gradient on Riemannian manifolds. For this generalization see: Outer derivative.
Orthogonal coordinates
In general orthogonal coordinates the gradient has the representation
where the denote the magnitude and
denote the direction of the vector ∂
General curvilinear coordinates
In general curvilinear coordinates the gradient has the representation
where is the gradient of the coordinate
Geometric interpretation
The gradient has a descriptive meaning in the already mentioned case of (two-dimensional) maps, in which height data are registered. The height function is then a scalar field, which assigns a height to each point on the map (characterized by an x- and a y-coordinate). The gradient of this scalar field at a point is a vector pointing in the direction of the steepest slope of the height function, and the magnitude of the gradient corresponds to the magnitude of this slope. The gradient at any point is perpendicular to the contour line (level line) of the height function through that point. In a local minimum or maximum (extremum) or at a saddle point, the gradient is just the zero vector, provided that this extreme point lies in the interior of the considered area.
With the help of the gradient, the increase in any direction can also be determined. This so-called directional derivative is - in contrast to the gradient - a scalar. If one runs in the area in (infinitesimally) small triple steps from a point a to the point b and sums up the product of step length and direction derivative in direction of the step, one receives as result the height difference to the starting point a at the destination point b. This height difference is obviously path independent. This height difference is obviously path-independent. In particular, if the start and end points coincide, one has not changed one's altitude at the end, no matter which path one has taken through the area.
Applications
Conservative forces
→ Main article: Conservative force
In physics, many force fields can be represented as the gradient of a potential. Examples are:
- the gravitational force
which is the same as for a central mass M
is, or
- static electric fields
in electrodynamics
In conservative force fields, one of the factors exploited is that, for sample masses or sample sample loads the path integrals the work along any path
through the force field depends only on the starting and ending points of the path, but not on its course, see #integral theorems.
Transport phenomena
Numerous transport phenomena can be traced back to the fact that the associated currents can be expressed as a gradient of a scalar field, with the proportionality factor that occurs being referred to as the transport coefficient or conductivity.
An example is the heat flow in thermodynamics, for which
where λ is the thermal conductivity.
In fluid mechanics, a potential flow is a flow in which the velocity is a gradient of a potential field, see velocity potential.
Image processing
→ Main article: Edge detection
One problem in image processing is to detect contiguous areas in an image. Since an image contains discrete values, filters like the Sobel operator are used to obtain a gradient field of the image. A filter is a matrix that is used to convolve the image (see Discrete Convolution). The edges in the image are then recognizable as extreme values of the filtered image.
More applications
- Just as Gauss-Newton methods are used for finding zeros of functions, the gradient method is used for multidimensional optimization problems in numerics.
- A pressure gradient microphone exploits the pressure differences between spatial points.
Generalizations
Gradients of vectors and tensors
See also: Gradient of a vector field
As already noted in the #Definition section, the gradient is also applied to vectors and tensors. Gradient of a scalar field (zero level tensor field) results in a vector field which is a first level tensor field. In general, gradient of a tensor field of nth degree leads to a tensor field of degree n+1.
The coefficients of the gradients of the covariant basis vectors of a curvilinear coordinate system are the Christoffel symbols.
Especially in continuum mechanics and fluid mechanics the gradients of scalar and vector fields are used in many ways, because the above #properties can be easily transferred to gradients of vector fields.
Riemannian manifolds
For a smooth function on a Riemannian manifold
the gradient of is
that vector field
with which for each vector field
the equation
where the inner product of tangent vectors at
defined by and ∂
(often
called ) is that function, which gives to each point
the directional derivative of
in direction
, evaluated in
, is assigned. In other words, in a map φ
from an open subset of
to an open subset of
is
given by:
where is the
component of
in these coordinates.
In local coordinates the gradient has the form
Analogous to the case one has the relation of the gradient with the outer derivative by means of
More precisely, is that of 1-form
under the musical isomorphism ("sharp") defined
by means of the metric
corresponding vector field. The relation between outer derivative and gradient for functions on the is the special case for the flat metric given by the Euclidean scalar product.
Related articles
Author
AlegsaOnline.com Gradient (multivariable calculus) Leandro Alegsa
URL: https://en.alegsaonline.com/art/40060