Skip to content

Cross Product Calculator — Step-by-Step Solutions

The Cross Product Calculator computes the cross product of two three-dimensional vectors. It also calculates the magnitude, unit vector direction, checks whether vectors are parallel, and computes the dot product.

Enter the components of two 3D vectors to get instant results with step-by-step solutions showing the determinant formula expansion.

Your calculations will appear here

How to Use the Cross Product Calculator

  1. Select a calculation mode from the tabs at the top. The five modes are: Cross Product, Magnitude, Unit Vector Direction, Parallel Check, and Dot Product.
  2. Enter the three components of Vector a (a_x, a_y, a_z) and the three components of Vector b (b_x, b_y, b_z) in the input fields. Results update as you type.
  3. In Cross Product mode, the calculator returns the resultant vector a x b along with step-by-step working showing the determinant expansion.
  4. Use Magnitude mode to find |a x b|, which equals the area of the parallelogram spanned by the two vectors. Unit Vector Direction normalises the cross product to give the direction perpendicular to both input vectors.
  5. Parallel Check tests whether the two vectors are parallel by verifying that their cross product is the zero vector. Dot Product mode computes a . b, the scalar product, for comparison.
  6. Copy the share URL at the bottom of the calculator to save or send your calculation with all inputs pre-filled.

Formula and Theory

The cross product (also called the vector product) of two three-dimensional vectors a and b produces a new vector that is perpendicular to both a and b. It is defined as a x b = |a||b|sin(theta) n, where theta is the angle between the vectors and n is the unit normal determined by the right-hand rule.

The most practical way to compute the cross product is through the determinant of a 3x3 matrix whose first row contains the unit vectors i, j, k and whose second and third rows contain the components of a and b respectively. Expanding along the first row gives: a x b = (a_y * b_z - a_z * b_y) i - (a_x * b_z - a_z * b_x) j + (a_x * b_y - a_y * b_x) k.

The magnitude of the cross product |a x b| equals the area of the parallelogram formed by the two vectors. Dividing by two gives the area of the triangle they span. This geometric interpretation makes the cross product essential in computational geometry and computer graphics for calculating surface areas and determining face orientations.

Key algebraic properties distinguish the cross product from the dot product. The cross product is anti-commutative: a x b = -(b x a). It is distributive over addition: a x (b + c) = a x b + a x c. However, it is NOT associative: a x (b x c) does not generally equal (a x b) x c. The cross product of any vector with itself is the zero vector, and the cross product of parallel vectors is always zero.

In physics, the cross product appears in torque (tau = r x F, where r is the position vector and F is the force), angular momentum (L = r x p), and the magnetic force on a charged particle (F = qv x B). In computer graphics, cross products compute surface normals for lighting calculations, determine the winding order of polygon vertices, and test whether a point lies inside a triangle.

Worked Examples

Example 1: Standard basis vectors

Problem: Find the cross product of i = (1, 0, 0) and j = (0, 1, 0).

Solution: Apply the formula: i component = (0)(0) - (0)(1) = 0. j component = -((1)(0) - (0)(0)) = 0. k component = (1)(1) - (0)(0) = 1. So i x j = (0, 0, 1) = k.

Answer: (0, 0, 1)

Example 2: General 3D vectors

Problem: Compute (2, 3, 4) x (5, 6, 7).

Solution: i component: (3)(7) - (4)(6) = 21 - 24 = -3. j component: -((2)(7) - (4)(5)) = -(14 - 20) = 6. k component: (2)(6) - (3)(5) = 12 - 15 = -3.

Answer: (-3, 6, -3)

Example 3: Parallel vectors yield the zero vector

Problem: Compute (2, 4, 6) x (1, 2, 3).

Solution: Note that (2, 4, 6) = 2 * (1, 2, 3), so the vectors are parallel. i component: (4)(3) - (6)(2) = 12 - 12 = 0. j component: -((2)(3) - (6)(1)) = -(6 - 6) = 0. k component: (2)(2) - (4)(1) = 4 - 4 = 0.

Answer: (0, 0, 0) -- the zero vector, confirming the vectors are parallel

Example 4: Area of a triangle from vertices

Problem: Find the area of the triangle with vertices A = (1, 0, 0), B = (0, 1, 0), C = (0, 0, 1).

Solution: Form edge vectors: AB = B - A = (-1, 1, 0), AC = C - A = (-1, 0, 1). Cross product: AB x AC = ((1)(1) - (0)(0), -((-1)(1) - (0)(-1)), (-1)(0) - (1)(-1)) = (1, 1, 1). Magnitude: sqrt(1 + 1 + 1) = sqrt(3). Triangle area = |AB x AC| / 2 = sqrt(3) / 2.

Answer: sqrt(3) / 2 (approximately 0.866)

Example 5: Torque calculation

Problem: A force F = (0, 0, 10) N is applied at position r = (3, 0, 0) m from the pivot. Find the torque.

Solution: Torque tau = r x F. i component: (0)(10) - (0)(0) = 0. j component: -((3)(10) - (0)(0)) = -30. k component: (3)(0) - (0)(0) = 0. So tau = (0, -30, 0) N*m.

Answer: (0, -30, 0) N*m -- the torque acts in the negative y-direction

Example 6: Normal to a plane from two direction vectors

Problem: Find a normal vector to the plane containing the direction vectors u = (1, 2, 0) and v = (3, 0, 1).

Solution: The cross product u x v is perpendicular to both u and v, hence normal to the plane. i component: (2)(1) - (0)(0) = 2. j component: -((1)(1) - (0)(3)) = -1. k component: (1)(0) - (2)(3) = -6.

Answer: (2, -1, -6)

Example 7: Unit normal vector

Problem: Find the unit normal vector for the cross product result (2, -1, -6).

Solution: Magnitude = sqrt(4 + 1 + 36) = sqrt(41). Unit vector = (2/sqrt(41), -1/sqrt(41), -6/sqrt(41)).

Answer: (0.3123, -0.1562, -0.9370) approximately

Example 8: Magnetic force on a moving charge

Problem: A particle with charge q = 2 C moves with velocity v = (1, 0, 0) m/s through magnetic field B = (0, 1, 0) T. Find the force.

Solution: F = qv x B. First compute v x B: i = (0)(0) - (0)(1) = 0, j = -((1)(0) - (0)(0)) = 0, k = (1)(1) - (0)(0) = 1. So v x B = (0, 0, 1). Then F = 2 * (0, 0, 1) = (0, 0, 2) N.

Answer: (0, 0, 2) N -- the force is perpendicular to both velocity and field

Frequently Asked Questions

What is the cross product used for?
The cross product finds a vector perpendicular to two given vectors. It is used in physics for torque, angular momentum, and magnetic force calculations. In computer graphics, it computes surface normals for lighting, determines polygon winding order, and performs point-in-triangle tests. In engineering, it calculates moments of force and areas of parallelograms and triangles.
Is the cross product commutative?
No. The cross product is anti-commutative, meaning a x b = -(b x a). Swapping the order of the vectors reverses the direction of the result. This is because the right-hand rule produces opposite directions when the operands are swapped.
What happens when you take the cross product of parallel vectors?
The cross product of parallel (or anti-parallel) vectors is the zero vector (0, 0, 0). This is because the angle between them is 0 or 180 degrees, and sin(0) = sin(180) = 0. This property is commonly used to test whether two vectors are parallel.
How is the cross product different from the dot product?
The dot product produces a scalar (a single number) and measures how much two vectors point in the same direction. The cross product produces a vector that is perpendicular to both inputs. The dot product uses cosine of the angle (a . b = |a||b|cos(theta)) while the cross product uses sine (|a x b| = |a||b|sin(theta)). The dot product is commutative; the cross product is anti-commutative.
Does the cross product work in 2D?
The cross product as a vector operation is only defined in three dimensions (and seven dimensions, though that is rarely used). For 2D vectors, you can compute a "pseudo cross product" by treating them as 3D vectors with z = 0. The result is a scalar equal to a_x * b_y - a_y * b_x, which represents the z-component of the full 3D cross product and gives the signed area of the parallelogram.
What is the right-hand rule?
The right-hand rule determines the direction of the cross product. Point the fingers of your right hand along vector a, then curl them towards vector b. Your thumb points in the direction of a x b. This convention ensures a consistent orientation in three-dimensional space.
How do you find the area of a parallelogram using the cross product?
The area of the parallelogram formed by vectors a and b equals the magnitude of their cross product: Area = |a x b|. For a triangle, divide by two: Area = |a x b| / 2. This works because |a x b| = |a||b|sin(theta), which is the geometric definition of parallelogram area.
What is the cross product formula?
The cross product a x b is computed using the determinant formula: a x b = (a_y * b_z - a_z * b_y, -(a_x * b_z - a_z * b_x), a_x * b_y - a_y * b_x). This is equivalent to expanding the determinant of a 3x3 matrix with unit vectors i, j, k in the first row and the components of a and b in the second and third rows.
Why is the cross product only defined in 3D?
The cross product requires a unique perpendicular direction to both input vectors. In 2D, there is no third dimension for the result to point in (only a scalar pseudo-product exists). In 4D and higher, there are multiple perpendicular directions, so a unique product cannot be defined. Three dimensions (and seven dimensions, by the properties of octonions) are the only spaces where a vector product with the required algebraic properties exists.
How is the cross product used in physics?
In mechanics, torque is tau = r x F (position cross force). Angular momentum is L = r x p (position cross momentum). In electromagnetism, the force on a moving charge in a magnetic field is F = qv x B (charge times velocity cross field). The Poynting vector S = E x H gives the direction of electromagnetic energy flow. All these quantities are inherently three-dimensional and use the cross product to capture both magnitude and direction.

Related Linear Algebra Calculators

Related Articles