Vector Calculus Calculator

Vector Calculus
Input
Enter a function of x, y, z
Type a scalar field above…


x^2    y^3    z^2
sin(x)    cos(y)    tan(z)
e^x    e^(x*y)    exp(z)
log(x) = ln(x)    sqrt(x)
x*y    x*y*z    3*x^2
Multiplication: Use * explicitly: x*y not xy
Powers: x^2 or x^(2/3)
Constants: pi, e

Result

Enter a field and click Compute

Compute gradient, divergence, or curl with step-by-step solutions.

3D Vector Field

Compute a gradient or curl to see its 3D vector field.

Python Compiler

What is Vector Calculus?

Vector calculus extends single-variable calculus to fields in two and three dimensions. The three fundamental operations are the gradient, divergence, and curl, all defined using the del operator ∇.

These operations are essential in physics (electromagnetism, fluid dynamics, thermodynamics) and engineering (signal processing, computer graphics, robotics).

The Three Operations

OperationInputOutputFormula
Gradient ∇fScalar fieldVector field(∂f/∂x, ∂f/∂y, ∂f/∂z)
Divergence ∇·FVector fieldScalar∂Fx/∂x + ∂Fy/∂y + ∂Fz/∂z
Curl ∇×FVector fieldVector fielddet[i,j,k; ∂x,∂y,∂z; Fx,Fy,Fz]

Key Vector Calculus Identities

Curl of Gradient = 0

∇ × (∇f) = 0 for any smooth scalar field f. Gradient fields are always irrotational.

Divergence of Curl = 0

∇ · (∇ × F) = 0 for any smooth vector field F. Curl fields are always solenoidal.

Laplacian

∇²f = ∇ · (∇f) = ∂²f/∂x² + ∂²f/∂y² + ∂²f/∂z². The divergence of the gradient.

Divergence Theorem

&oiint; F · dS = &oiiint; (∇ · F) dV. Relates surface integral to volume integral.

Applications

Electromagnetism

Maxwell's equations use gradient, divergence, and curl to describe electric and magnetic fields.

🌊

Fluid Dynamics

Divergence measures fluid expansion/compression. Curl measures fluid rotation (vorticity).

🌡

Heat Transfer

The gradient of temperature gives the direction of heat flow. Fourier's law: q = -k∇T.

📈

Optimization

The gradient points in the direction of steepest ascent. Gradient descent finds minima of cost functions.

Frequently asked

The gradient of a scalar field f(x,y,z) is a vector field that points in the direction of the greatest rate of increase of f. It is computed as ∇f = (∂f/∂x, ∂f/∂y, ∂f/∂z). For example, the gradient of f = x² + y² + z² is (2x, 2y, 2z).
The divergence of a vector field F = (Fx, Fy, Fz) is a scalar measuring the rate at which the field spreads out from a point: ∇·F = ∂Fx/∂x + ∂Fy/∂y + ∂Fz/∂z. Positive divergence indicates a source; negative indicates a sink.
The curl of a vector field F measures its tendency to rotate around a point. It is computed using the determinant formula involving partial derivatives. If curl F = 0 the field is conservative (irrotational). For example, curl(−y, x, 0) = (0, 0, 2), indicating uniform rotation.
Use standard math notation: x^2 for squared, sin(x), e^z, sqrt(x), x*y for multiplication. Polynomials, trig, exponential, log, and hyperbolic functions all work. A live KaTeX preview shows your expression as rendered math.
Yes — after computing a result, click Show Steps for a detailed solution showing each partial derivative, simplification, and final assembly of the result vector. Steps are rendered with full LaTeX math notation.
Yes. Click Print Worksheet for a printable practice sheet from a bank of 1,500+ problems across 18 types: vectors from points, dot product, cross product, unit vectors, vector projections, direction cosines, angle between vectors, vector function derivatives, integrals, limits, and more. Each worksheet includes an answer key.