Vector Dot Product Calculator (3D)
The dot product of two 3D vectors a = (a1, a2, a3) and b = (b1, b2, b3) is computed as a times b = a1 times b1 + a2 times b2 + a3 times b3. It produces a single scalar value. Enter the components of two 3D vectors and this calculator returns the dot product, the magnitude of each vector, the angle between them in degrees, and the scalar projection of a onto b. The angle formula is theta = arccos(a dot b divided by (|a| times |b|)), and the result ranges from 0 (parallel, same direction) to 180 (antiparallel). When the dot product equals zero, the vectors are perpendicular. The scalar projection comp(a onto b) = (a dot b) / |b| measures how much of vector a lies along the direction of b. Applications include finding the component of a force in a given direction, computing work done by a force (W = F dot d), and testing perpendicularity of vectors in geometry, physics, and computer graphics.
Dot product formulas
a · b = a1*b1 + a2*b2 + a3*b3
|a| = sqrt(a1^2 + a2^2 + a3^2)
theta = arccos(a·b / (|a| * |b|))
Scalar projection of a onto b = (a·b) / |b|
Perpendicular iff a·b = 0
Dot product: frequently asked questions
What is the dot product of two vectors?
The dot product (also called scalar product or inner product) of vectors a and b is a·b = a1*b1 + a2*b2 + a3*b3. The result is a scalar (single number), not a vector. It equals |a|*|b|*cos(theta), where theta is the angle between the vectors. The dot product is commutative: a·b = b·a.
How do you find the angle between two vectors using the dot product?
Rearranging the formula: cos(theta) = (a·b) / (|a|*|b|), so theta = arccos((a·b) / (|a|*|b|)). The angle is always between 0 and 180 degrees. If the dot product is positive, the angle is acute (less than 90 degrees). If zero, the vectors are perpendicular. If negative, the angle is obtuse.
What does it mean when the dot product is zero?
A dot product of zero means the two vectors are perpendicular (orthogonal) to each other. The angle between them is exactly 90 degrees. This is a key concept in linear algebra: orthogonal vectors have no component in each other's direction. In a Cartesian coordinate system, the unit vectors i, j, and k are mutually orthogonal.
What is the scalar projection of a onto b?
The scalar projection of a onto b is the signed length of the shadow that a casts onto b: comp_b(a) = a·b / |b|. It equals |a|*cos(theta) where theta is the angle between a and b. The vector projection is (a·b / |b|^2) * b, which gives a vector in the direction of b.
How does the dot product differ from the cross product?
The dot product a·b produces a scalar and measures how parallel two vectors are. The cross product a x b produces a vector perpendicular to both a and b, and its magnitude equals |a|*|b|*sin(theta). The dot product is zero for perpendicular vectors; the cross product is zero for parallel vectors.
Sources
- Vector algebra: NIST DLMF 1.6, Vectors and Vector Spaces.
- Dot product reference: Wolfram MathWorld, Dot Product.
Reviewed by the CalculatorHub team, edited by James Graham, 14 June 2026. See our methodology.