maths.free › Multivariable Calculus › Derivatives in many variables › Directional derivative
Directional derivative
In multivariable calculus, the directional derivative measures the instantaneous rate at which a function changes along a specified vector through a given point.
Directional derivative
In multivariable calculus, the directional derivative measures the instantaneous rate at which a function changes along a specified vector through a given point. If the vector is multiplied by a scalar, the corresponding directional derivative is multiplied by the same scalar.
Some elementary texts instead use the phrase "directional derivative in the direction of v" for the rate of change of a function per unit distance in that direction. In that convention the nonzero vector v is first normalized to the unit vector \(\hat{\mathbf v} = \mathbf v/\|\mathbf v\|\), where the normalized vector is denoted with a circumflex (hat) symbol: \(\mathbf{\widehat{}}\).
The directional derivative of a scalar function f with respect to a vector v may be denoted by any of the following: \[\begin{aligned} \nabla_{\mathbf{v}}{f}(\mathbf{x}) &=f'_\mathbf{v}(\mathbf{x})\\ &=D_\mathbf{v}f(\mathbf{x})\\ &=Df(\mathbf{x})(\mathbf{v})\\ &=\partial_\mathbf{v}f(\mathbf{x})\\ &=\frac{\partial f(\mathbf{x})}{\partial \mathbf{v}}\\ &=\mathbf{v}\cdot{\nabla f(\mathbf{x})}\\ &=\mathbf{v} \cdot \frac{\partial f(\mathbf{x})}{\partial\mathbf{x}}.\\ \end{aligned}\]
It therefore generalizes the notion of a partial derivative, in which the rate of change is taken along one of the curvilinear coordinate curves, all other coordinates being constant. In functional analysis, the analogous notion for functions between topological vector spaces is the Gateaux derivative.
Definition
The directional derivative of a scalar function \[f(\mathbf{x}) = f(x_1, x_2, \ldots, x_n)\] along a vector \[\mathbf{v} = (v_1, \ldots, v_n)\] is the function \(\nabla_{\mathbf{v}}{f}\) defined by the limit \[\nabla_{\mathbf{v}}{f}(\mathbf{x}) = \lim_{h \to 0}{\frac{f(\mathbf{x} + h\mathbf{v}) - f(\mathbf{x})}{h}} = \left. \frac{\mathrm{d}}{\mathrm{d}t}f(\mathbf{x}+t\mathbf{v})\right|_{t=0}.\]
This definition is valid in a broad range of contexts, for example, where the norm of a vector is defined. In finite dimensions, it does not depend on the choice of norm, since all norms are equivalent. Its applicability extends to functions on finite-dimensional vector spaces without a metric and to differentiable manifolds, such as in general relativity.
For differentiable functions
If the function f is differentiable at x, then the directional derivative exists along any vector v at x, and one has
\[\nabla_{\mathbf{v}}{f}(\mathbf{x}) = \nabla f(\mathbf{x}) \cdot \mathbf{v}\]
where the \(\nabla\) on the right denotes the gradient and \(\cdot\) is the dot product.
It can be derived by using the property that all directional derivatives at a point make up a single tangent plane which can be defined using partial derivatives. This can be used to find a formula for the gradient vector and an alternative formula for the directional derivative, the latter of which can be rewritten as shown above for convenience.
It also follows from defining a path \(\mathbf{h}(t) = \mathbf{x} + t\mathbf{v}\) and using the definition of the derivative as a limit along this path to get \[\begin{aligned} \nabla_\mathbf{v} f(\mathbf{x})-\nabla f(\mathbf{x})\cdot \mathbf{v} & = \lim_{t \to 0}\frac {f(\mathbf{x}+t \mathbf{v})-f(\mathbf{x})} t - \nabla f(\mathbf{x})\cdot \mathbf{v} \\ &=\lim_{t \to 0}\frac {f(\mathbf{x}+t \mathbf{v})-f(\mathbf{x})-t\nabla f(\mathbf{x})\cdot \mathbf{v}} t \\ &= 0, \end{aligned}\] whence \(\nabla f(\mathbf{x})\cdot \mathbf{v}=\nabla_\mathbf{v} f(\mathbf{x})\).
Using only direction of vector
In a Euclidean space, some authors define the directional derivative to be with respect to an arbitrary nonzero vector v after normalization, thus being independent of its magnitude and depending only on its direction.
This definition gives the rate change of a function f per unit of distance moved in the direction given by v. In this case, one has \[\nabla_{\hat{\mathbf{v}}}{f}(\mathbf{x}) = \lim_{h \to 0}{\frac{f(\mathbf{x} + h\mathbf{v}) - f(\mathbf{x})}{h\|v\|}},\] or in case f is differentiable at x, \[\nabla_{\hat{\mathbf{v}}}{f}(\mathbf{x}) = \nabla f(\mathbf{x}) \cdot \hat{\mathbf{v}} .\]
Properties
Many of the familiar properties of the ordinary derivative hold for the directional derivative. These include, for any functions f and g defined in a neighborhood of, and differentiable at, p:
- sum rule: \[\nabla_{\mathbf{v}} (f + g) = \nabla_{\mathbf{v}} f + \nabla_{\mathbf{v}} g.\]
- constant factor rule: For any constant c, \[\nabla_{\mathbf{v}} (cf) = c\nabla_{\mathbf{v}} f.\]
- product rule (or Leibniz's rule): \[\nabla_{\mathbf{v}} (fg) = g\nabla_{\mathbf{v}} f + f\nabla_{\mathbf{v}} g.\]
- chain rule: If g is differentiable at p and h is differentiable at g(p), then \[\nabla_{\mathbf{v}}(h\circ g)(\mathbf{p}) = h'(g(\mathbf{p})) \nabla_{\mathbf{v}} g (\mathbf{p}).\]
In differential geometry
Let M be a differentiable manifold and p a point of M. Suppose that f is a function defined in a neighborhood of p, and differentiable at p. If v is a tangent vector to M at p, then the directional derivative of f along v, denoted variously as df(v) (see Exterior derivative), \(\nabla_{\mathbf{v}} f(\mathbf{p})\) (see Covariant derivative), \(L_{\mathbf{v}} f(\mathbf{p})\) (see Lie derivative), or \({\mathbf{v}}_{\mathbf{p}}(f)\) (see Tangent space § Definition via derivations), can be defined as follows. Let γ : [−1, 1] → M be a differentiable curve with γ(0) = p and γ′(0) = v. Then the directional derivative is defined by \[\nabla_{\mathbf{v}} f(\mathbf{p}) = \left.\frac{d}{d\tau} f\circ\gamma(\tau)\right|_{\tau=0}.\] This definition can be proven independent of the choice of γ, provided γ is selected in the prescribed manner so that γ(0) = p and γ′(0) = v.
The Lie derivative
The Lie derivative of a vector field \(W^\mu(x)\) along a vector field \(V^\mu(x)\) is given by the difference of two directional derivatives (with vanishing torsion): \[\mathcal{L}_V W^\mu=(V\cdot\nabla) W^\mu-(W\cdot\nabla) V^\mu.\] In particular, for a scalar field \(\phi(x)\), the Lie derivative reduces to the standard directional derivative: \[\mathcal{L}_V \phi=(V\cdot\nabla) \phi.\]
The Riemann tensor
Directional derivatives are often used in introductory derivations of the Riemann curvature tensor. Consider a curved rectangle with an infinitesimal vector \(\delta\) along one edge and \(\delta'\) along the other. We translate a covector \(S\) along \(\delta\) then \(\delta'\) and then subtract the translation along \(\delta'\) and then \(\delta\). Instead of building the directional derivative using partial derivatives, we use the covariant derivative. The translation operator for \(\delta\) is thus \[1+\sum_\nu \delta^\nu D_\nu=1+\delta\cdot D,\] and for \(\delta'\), \[1+\sum_\mu \delta'^\mu D_\mu=1+\delta'\cdot D.\] The difference between the two paths is then \[(1+\delta'\cdot D)(1+\delta\cdot D)S^\rho-(1+\delta\cdot D)(1+\delta'\cdot D)S^\rho=\sum_{\mu,\nu}\delta'^\mu \delta^\nu[D_\mu,D_\nu]S_\rho.\] It can be argued that the noncommutativity of the covariant derivatives measures the curvature of the manifold: \[[D_\mu,D_\nu]S_\rho=\pm \sum_\sigma R^\sigma{}_{\rho\mu\nu}S_\sigma,\] where \(R\) is the Riemann curvature tensor and the sign depends on the sign convention of the author.
Translations
In the Poincaré algebra, we can define an infinitesimal translation operator P as \[\mathbf{P}=i\nabla.\] (the i ensures that P is a self-adjoint operator) For a finite displacement λ, the unitary Hilbert space representation for translations is \[U(\boldsymbol{\lambda})=\exp\left(-i\boldsymbol{\lambda}\cdot\mathbf{P}\right).\] By using the above definition of the infinitesimal translation operator, we see that the finite translation operator is an exponentiated directional derivative: \[U(\boldsymbol{\lambda})=\exp\left(\boldsymbol{\lambda}\cdot\nabla\right).\] This is a translation operator in the sense that it acts on multivariable functions f(x) as \[U(\boldsymbol{\lambda}) f(\mathbf{x})=\exp\left(\boldsymbol{\lambda}\cdot\nabla\right) f(\mathbf{x}) = f(\mathbf{x}+\boldsymbol{\lambda}).\]
Condensed: the full section is in Wikipedia.
Rotations
The rotation operator also contains a directional derivative. The rotation operator for an angle θ, i.e. by an amount θ = |θ| about an axis parallel to \(\hat{\theta} = \boldsymbol{\theta}/\theta\) is \[U(R(\mathbf{\theta}))=\exp(-i\mathbf{\theta}\cdot\mathbf{L}).\] Here L is the vector operator that generates SO(3): \[\mathbf{L}=\begin{pmatrix} 0& 0 & 0\\ 0& 0 & 1\\ 0& -1 & 0 \end{pmatrix}\mathbf{i}+\begin{pmatrix} 0 &0 & -1\\ 0& 0 &0 \\ 1 & 0 & 0 \end{pmatrix}\mathbf{j}+\begin{pmatrix} 0&1 &0 \\ -1&0 &0 \\ 0 & 0 & 0 \end{pmatrix}\mathbf{k}.\] It may be shown geometrically that an infinitesimal right-handed rotation changes the position vector x by \[\mathbf{x}\rightarrow \mathbf{x}-\delta\boldsymbol{\theta}\times\mathbf{x}.\] So we would expect under infinitesimal rotation: \[U(R(\delta\boldsymbol{\theta})) f(\mathbf{x}) = f(\mathbf{x}-\delta\boldsymbol{\theta}\times\mathbf{x})=f(\mathbf{x})-(\delta\boldsymbol{\theta}\times\mathbf{x})\cdot\nabla f.\] It follows that \[U(R(\delta\mathbf{\theta}))=1-(\delta\mathbf{\theta}\times\mathbf{x})\cdot\nabla.\] Following the same exponentiation procedure as above, we arrive at the rotation operator in the position basis, which is an exponentiated directional derivative: \[U(R(\mathbf{\theta}))=\exp(-(\mathbf{\theta}\times\mathbf{x})\cdot\nabla).\]
Normal derivative
A normal derivative is a directional derivative taken in the direction normal (that is, orthogonal) to some surface in space, or more generally along a normal vector field orthogonal to some hypersurface. See for example Neumann boundary condition. If the normal direction is denoted by \(\mathbf{n}\), then the normal derivative of a function f is sometimes denoted as \(\frac{ \partial f}{\partial \mathbf{n}}\). In other notations, \[\frac{ \partial f}{\partial \mathbf{n}} = \nabla f(\mathbf{x}) \cdot \mathbf{n} = \nabla_{\mathbf{n}}{f}(\mathbf{x}) = \frac{\partial f}{\partial \mathbf{x}} \cdot \mathbf{n} = Df(\mathbf{x})[\mathbf{n}].\]
In the continuum mechanics of solids
Several important results in continuum mechanics require the derivatives of vectors with respect to vectors and of tensors with respect to vectors and tensors. The directional derivative provides a systematic way of finding these derivatives.
Condensed: the full section is in Wikipedia.
Derivatives of scalar valued functions of vectors
Let f(v) be a real valued function of the vector v. Then the derivative of f(v) with respect to v (or at v) is the vector defined through its dot product with any vector u being
\[\frac{\partial f}{\partial \mathbf{v}}\cdot\mathbf{u} = Df(\mathbf{v})[\mathbf{u}] = \left[\frac{d}{d\alpha}~f(\mathbf{v} + \alpha~\mathbf{u})\right]_{\alpha=0}\]
for all vectors u. The above dot product yields a scalar, and if u is a unit vector gives the directional derivative of f at v, in the u direction.
Properties:
- If \(f(\mathbf{v}) = f_1(\mathbf{v}) + f_2(\mathbf{v})\) then \[\frac{\partial f}{\partial \mathbf{v}}\cdot\mathbf{u} = \left(\frac{\partial f_1}{\partial \mathbf{v}} + \frac{\partial f_2}{\partial \mathbf{v}}\right)\cdot\mathbf{u}\]
- If \(f(\mathbf{v}) = f_1(\mathbf{v})~ f_2(\mathbf{v})\) then \[\frac{\partial f}{\partial \mathbf{v}}\cdot\mathbf{u} = \left(\frac{\partial f_1}{\partial \mathbf{v}} \cdot \mathbf{u} \right)~f_2(\mathbf{v}) + f_1(\mathbf{v})~\left(\frac{\partial f_2}{\partial \mathbf{v}}\cdot\mathbf{u} \right)\]
- If \(f(\mathbf{v}) = f_1(f_2(\mathbf{v}))\) then \[\frac{\partial f}{\partial \mathbf{v}}\cdot\mathbf{u} = \frac{\partial f_1}{\partial f_2}~\frac{\partial f_2}{\partial \mathbf{v}}\cdot\mathbf{u}\]
Derivatives of vector valued functions of vectors
Let f(v) be a vector valued function of the vector v. Then the derivative of f(v) with respect to v (or at v) is the second order tensor defined through its dot product with any vector u being
\[\frac{\partial \mathbf{f}}{\partial \mathbf{v}}\cdot\mathbf{u} = D\mathbf{f}(\mathbf{v})[\mathbf{u}] = \left[\frac{d}{d\alpha}~\mathbf{f}(\mathbf{v} + \alpha~\mathbf{u} ) \right]_{\alpha = 0}\]
for all vectors u. The above dot product yields a vector, and if u is a unit vector gives the direction derivative of f at v, in the directional u.
Properties:
- If \(\mathbf{f}(\mathbf{v}) = \mathbf{f}_1(\mathbf{v}) + \mathbf{f}_2(\mathbf{v})\) then \[\frac{\partial \mathbf{f}}{\partial \mathbf{v}}\cdot\mathbf{u} = \left(\frac{\partial \mathbf{f}_1}{\partial \mathbf{v}} + \frac{\partial \mathbf{f}_2}{\partial \mathbf{v}}\right)\cdot\mathbf{u}\]
- If \(\mathbf{f}(\mathbf{v}) = \mathbf{f}_1(\mathbf{v})\times\mathbf{f}_2(\mathbf{v})\) then \[\frac{\partial \mathbf{f}}{\partial \mathbf{v}}\cdot\mathbf{u} = \left(\frac{\partial \mathbf{f}_1}{\partial \mathbf{v}}\cdot\mathbf{u}\right)\times\mathbf{f}_2(\mathbf{v}) + \mathbf{f}_1(\mathbf{v})\times\left(\frac{\partial \mathbf{f}_2}{\partial \mathbf{v}}\cdot\mathbf{u} \right)\]
- If \(\mathbf{f}(\mathbf{v}) = \mathbf{f}_1(\mathbf{f}_2(\mathbf{v}))\) then \[\frac{\partial \mathbf{f}}{\partial \mathbf{v}}\cdot\mathbf{u} = \frac{\partial \mathbf{f}_1}{\partial \mathbf{f}_2}\cdot\left(\frac{\partial \mathbf{f}_2}{\partial \mathbf{v}}\cdot\mathbf{u} \right)\]
Nu är det din tur. Ingen miniräknare bestämmer detta, men bitarna i det är beräkningsbara. Prova en nedan, eller skriv din egen.
Ett gratis konto lägger till anteckningar om varje lektion, en förteckning över vad du har avslutat, dina lösta problem på ett ställe, och en handledare du kan fråga om denna sida. Matematiken i sig är öppen för alla, inloggad eller inte.
Registrera dig InloggningSymboler som används här
Knacka på alla symboler för den fullständiga definitionen, en bild, och vad varje bokstav i den betyder.
Frågor folk frågar
What is a partial derivative?
The ordinary derivative with respect to one variable while every other variable is frozen: the slope of the surface in one coordinate direction.
What does the gradient point at?
Uphill: the direction of steepest increase, with length equal to that steepest slope. It is perpendicular to the level curves.
Delar av denna sida är anpassade från Wikipedia (CC BY-SA 4.0). Kondenserad och återförklarad här; felen är våra.
Mer information Multivariable Calculus
Functions of several variablesPartial derivatives and the gradientOptimisation in several variablesDouble and triple integralsVector fields, line integrals and the big theorems