Directional Derivative Calculator

Type a function, a point and a direction to find the rate of change in that direction.

Use x, y and z. Type powers with ^ and functions with brackets: sin(xy), e^(x + y), ln(x), sqrt(x).

The point as 2 or 3 numbers, one for each variable, such as (1, 2) or (1, 2, 3).

A direction with one number for each variable. It is divided by its own length, so any length works.

Try

Result

You enteredDuf(1,2), u=(3,4)D_{\mathbf{u}} f\left(1, 2\right),\ \mathbf{u} = \left(3, 4\right)

Duf=165\displaystyle D_{\mathbf{u}} f = \frac{16}{5}

Fraction

165\displaystyle \frac{16}{5}
Show the work
  1. Gradient

    The directional derivative needs the gradient of ff, the vector of its partial derivatives.

    ∇f=(fx,fy)=(2x y,x2)\begin{aligned} \nabla f &= \left(f_x, f_y\right) \\ &= \left(2x\,y, x^{2}\right) \end{aligned}
  2. Gradient at the point

    Substitute the point (1,2)\left(1, 2\right) into the gradient.

    ∇f(1,2)=(4,1)\nabla f\left(1, 2\right) = \left(4, 1\right)
  3. Unit vector in the direction

    The directional derivative uses a unit vector, so the direction (3,4)\left(3, 4\right) is normalised: divided by its length 25=5\sqrt{25} = 5.

    Using u=v∣v∣\mathbf{u} = \frac{\mathbf{v}}{\left|\mathbf{v}\right|}

    u^=(35,45)\hat{u} = \left(\frac{3}{5}, \frac{4}{5}\right)
  4. Directional derivative

    Take the dot product of the gradient with the unit vector: it is the rate of change of f in that direction.

    Duf=∇f⋅u=(4,1)⋅(35,45)=165\begin{aligned} D_{\mathbf{u}} f &= \nabla f \cdot \mathbf{u} \\ &= \left(4, 1\right) \cdot \left(\frac{3}{5}, \frac{4}{5}\right) \\ &= \frac{16}{5} \end{aligned}
  5. Result

    The directional derivative at the point.

    Duf=165D_{\mathbf{u}} f = \frac{16}{5}

Worked examples