Mathwords logoMathwords

Jacobian — Definition, Formula & Examples

The Jacobian is a matrix that collects all the first-order partial derivatives of a vector-valued function, organizing how each output component changes with respect to each input variable. Its determinant, called the Jacobian determinant, measures how the function locally stretches or compresses area (or volume) near a point.

Given a differentiable function F:RnRm\mathbf{F}: \mathbb{R}^n \to \mathbb{R}^m with component functions F1,F2,,FmF_1, F_2, \ldots, F_m, the Jacobian matrix J\mathbf{J} is the m×nm \times n matrix whose entry in the ii-th row and jj-th column is Jij=FixjJ_{ij} = \dfrac{\partial F_i}{\partial x_j}. When m=nm = n, the Jacobian determinant det(J)\det(\mathbf{J}) is defined and represents the local scaling factor of the transformation at a given point.

Key Formula

J=[F1x1F1xnFmx1Fmxn]\mathbf{J} = \begin{bmatrix} \dfrac{\partial F_1}{\partial x_1} & \cdots & \dfrac{\partial F_1}{\partial x_n} \\[6pt] \vdots & \ddots & \vdots \\[6pt] \dfrac{\partial F_m}{\partial x_1} & \cdots & \dfrac{\partial F_m}{\partial x_n} \end{bmatrix}
Where:
  • FiF_i = The i-th component function of the vector-valued function F
  • xjx_j = The j-th input variable
  • mm = Number of output components (rows)
  • nn = Number of input variables (columns)

How It Works

To build the Jacobian, compute each partial derivative Fixj\frac{\partial F_i}{\partial x_j} and place it in row ii, column jj. The resulting matrix is the best linear approximation of F\mathbf{F} near a point — it generalizes the single-variable derivative to multiple dimensions. When m=nm = n, you can take its determinant: a nonzero Jacobian determinant means the function is locally invertible (by the Inverse Function Theorem). In integration, the absolute value of the Jacobian determinant serves as the scaling factor when changing variables — for instance, converting a double integral from Cartesian to polar coordinates.

Worked Example

Problem: Find the Jacobian matrix and its determinant for the transformation from polar to Cartesian coordinates: F(r,θ)=(rcosθ,  rsinθ)F(r, \theta) = (r\cos\theta,\; r\sin\theta).
Step 1: Identify the component functions: F1=rcosθF_1 = r\cos\theta and F2=rsinθF_2 = r\sin\theta.
Step 2: Compute each partial derivative to fill the 2×2 Jacobian matrix.
J=[F1rF1θF2rF2θ]=[cosθrsinθsinθrcosθ]\mathbf{J} = \begin{bmatrix} \dfrac{\partial F_1}{\partial r} & \dfrac{\partial F_1}{\partial \theta} \\[6pt] \dfrac{\partial F_2}{\partial r} & \dfrac{\partial F_2}{\partial \theta} \end{bmatrix} = \begin{bmatrix} \cos\theta & -r\sin\theta \\ \sin\theta & r\cos\theta \end{bmatrix}
Step 3: Compute the determinant of J.
det(J)=(cosθ)(rcosθ)(rsinθ)(sinθ)=rcos2θ+rsin2θ=r\det(\mathbf{J}) = (\cos\theta)(r\cos\theta) - (-r\sin\theta)(\sin\theta) = r\cos^2\theta + r\sin^2\theta = r
Answer: The Jacobian matrix is [cosθrsinθsinθrcosθ]\begin{bmatrix} \cos\theta & -r\sin\theta \\ \sin\theta & r\cos\theta \end{bmatrix} and the Jacobian determinant is rr. This is why the area element in polar coordinates is rdrdθr\,dr\,d\theta.

Another Example

Problem: Find the Jacobian matrix for F(x,y)=(x2y,  5x+siny)\mathbf{F}(x, y) = (x^2 y,\; 5x + \sin y).
Step 1: Set F1=x2yF_1 = x^2 y and F2=5x+sinyF_2 = 5x + \sin y.
Step 2: Compute the four partial derivatives.
J=[(x2y)x(x2y)y(5x+siny)x(5x+siny)y]=[2xyx25cosy]\mathbf{J} = \begin{bmatrix} \dfrac{\partial(x^2 y)}{\partial x} & \dfrac{\partial(x^2 y)}{\partial y} \\[6pt] \dfrac{\partial(5x+\sin y)}{\partial x} & \dfrac{\partial(5x+\sin y)}{\partial y} \end{bmatrix} = \begin{bmatrix} 2xy & x^2 \\ 5 & \cos y \end{bmatrix}
Step 3: Compute the determinant.
det(J)=2xycosy5x2\det(\mathbf{J}) = 2xy\cos y - 5x^2
Answer: The Jacobian matrix is [2xyx25cosy]\begin{bmatrix} 2xy & x^2 \\ 5 & \cos y \end{bmatrix} with determinant 2xycosy5x22xy\cos y - 5x^2.

Why It Matters

The Jacobian appears constantly in Calculus III (multivariable calculus) whenever you change variables in multiple integrals — polar, cylindrical, and spherical coordinate substitutions all rely on the Jacobian determinant. In machine learning, the Jacobian matrix tracks how neural-network outputs respond to changes in inputs, which is central to backpropagation. Robotics engineers use Jacobians to relate joint velocities to end-effector velocities in robotic arms.

Common Mistakes

Mistake: Forgetting the absolute value of the Jacobian determinant when substituting in integrals.
Correction: The area/volume scaling factor is det(J)|\det(\mathbf{J})|. A negative determinant indicates orientation reversal, but the integral scaling is always the absolute value.
Mistake: Mixing up row and column positions — placing Fi/xj\partial F_i / \partial x_j in the wrong location.
Correction: Each row corresponds to one output component FiF_i and each column corresponds to one input variable xjx_j. Row ii, column jj holds Fi/xj\partial F_i / \partial x_j.