Dot product calculator

Calculate the dot product a · b and the angle between two vectors. Works for 2D and 3D vectors.

Vector a
Vector b

Dot product formula

a · b = a₁b₁ + a₂b₂ + a₃b₃

The result is a scalar (single number), not a vector.

Angle between vectors

cos(θ) = (a · b) / (|a| × |b|)

If a · b = 0, the vectors are perpendicular (orthogonal).

If a · b > 0, the angle is acute (< 90°). If a · b < 0, the angle is obtuse (> 90°).

Applications

Physics: Work W = F · d (force dot displacement).

Projection: proj_b(a) = (a · b / b · b) × b.

Similarity: Cosine similarity in machine learning uses the dot product to compare vectors.

Popular slope & distance problems
Related calculators