Cross Product Calculator

Compute the cross product of two 3D vectors and see the result vector, its magnitude, the angle between vectors, and a full step-by-step solution with interactive visualization.

Calculate Cross Product

Enter two 3D vectors to compute their cross product, magnitude, angle, and parallelogram area

x y z
Try examples:

How to Use This Calculator

1

Enter Vector Components

Type the i, j, and k components for both Vector A and Vector B into the input fields

2

Click Calculate

Press the Calculate button or use Ctrl+Enter to compute the cross product and all related properties

3

Explore the Results

View the cross product vector, magnitude, angle, parallelogram area, 3D visualization, and step-by-step solution

Quick Tips:

  • Try the preset examples to see cross products in action: unit vectors, torque, surface normals, and parallelogram area
  • The 3D visualization shows Vector A in blue, Vector B in red, and the resulting cross product in green
  • Use the decimal places selector to adjust precision, and copy all results to clipboard with one click

What Is the Cross Product?

The cross product is a fundamental operation in three-dimensional vector mathematics. Given two vectors in 3D space, the cross product produces a third vector that is perpendicular to both of the original vectors. This property makes it unlike any other common arithmetic operation, and it is the reason the cross product appears so often in physics, engineering, and computer graphics.

To understand why this operation matters, think about a flat surface defined by two lines that intersect. Those two lines determine a unique direction that sticks straight out of the surface, perpendicular to it. The cross product is the mathematical tool that finds exactly that direction. It converts two vectors that define a plane into the vector that is normal to that plane.

The cross product is sometimes called the vector product to distinguish it from the dot product, which is also known as the scalar product. The names highlight the most important difference: the dot product produces a number, while the cross product produces a new vector. Both operations combine two vectors, but they answer different questions and are used in different situations.

The Cross Product Formula

If Vector A has components (ax, ay, az) and Vector B has components (bx, by, bz), the cross product A x B is computed component by component using the following formulas:

(A x B)x = ay · bz − az · by

(A x B)y = az · bx − ax · bz

(A x B)z = ax · by − ay · bx

The result is a new vector with three components, each derived from pairs of components of A and B

A helpful way to remember this is to write out a formal 3x3 determinant. Place the unit vectors i, j, k in the first row, the components of A in the second row, and the components of B in the third row. Expanding this determinant along the first row gives you the three component formulas above. The determinant approach is the standard technique taught in linear algebra and multivariable calculus courses, and it provides a systematic way to compute the cross product without memorizing the individual formulas.

For example, if A = (2, 3, 4) and B = (5, 6, 7), then the cross product A x B equals: x = (3)(7) - (4)(6) = 21 - 24 = -3, y = (4)(5) - (2)(7) = 20 - 14 = 6, z = (2)(6) - (3)(5) = 12 - 15 = -3. So A x B = (-3, 6, -3).

Geometric Interpretation

The cross product has a rich geometric meaning that goes beyond the formula. The magnitude of the cross product vector equals the area of the parallelogram whose sides are defined by the two input vectors. This leads directly to a practical formula: the area of a triangle with two sides represented by vectors A and B is exactly half the magnitude of A x B.

The magnitude formula is |A x B| = |A| |B| sin(theta), where theta is the angle between the two vectors. This tells you something important: the cross product is largest when the two vectors are perpendicular (sin 90° = 1) and becomes zero when they are parallel (sin 0° = 0). The sine function captures how much the two vectors "spread apart" in their shared plane, which corresponds directly to the area they enclose.

The direction of the cross product is determined by the right-hand rule. Point the fingers of your right hand along Vector A, curl them toward Vector B through the smaller angle between the two vectors, and your extended thumb indicates the direction of A x B. This convention is universal in physics and engineering, and it ensures that the cross product behaves consistently across all coordinate systems that share the same handedness.

Key Properties of the Cross Product

The cross product has several algebraic properties that distinguish it from ordinary multiplication and make it both useful and sometimes surprising to work with.

Anticommutativity. Reversing the order of the vectors reverses the direction of the result. A x B = -(B x A). This is the property that catches most beginners off guard. Unlike regular multiplication or the dot product, swapping the inputs gives a different result, not the same one. The magnitude is the same, but the direction flips. This makes physical sense: if you use the right-hand rule for B x A instead of A x B, your thumb points the other way.

Distributivity over addition. The cross product distributes over vector addition in the standard way: A x (B + C) = (A x B) + (A x C). This property allows you to expand cross products of sums without any surprises and makes algebraic manipulation straightforward.

Scalar multiplication. You can factor out scalar constants: (cA) x B = c(A x B) = A x (cB). Multiplying either input vector by a scalar multiplies the resulting cross product by the same scalar. This is consistent with the geometric interpretation, since scaling a vector scales the area of the parallelogram.

Self-cross product. Any vector crossed with itself equals the zero vector: A x A = 0. This follows directly from the anticommutativity property (A x A = -(A x A) implies A x A = 0) and also from the sine formula, since the angle between a vector and itself is zero and sin(0) = 0.

Non-associativity. The cross product is not associative. (A x B) x C is generally not equal to A x (B x C). This is an important difference from scalar multiplication and the dot product. When working with expressions involving three or more cross products, the order of operations and the placement of parentheses genuinely change the result.

Standard basis cross products. The unit vectors i, j, and k (pointing along the x, y, and z axes) obey the cyclic pattern: i x j = k, j x k = i, k x i = j. Reversing any pair changes the sign: j x i = -k, k x j = -i, i x k = -j. Memorizing this cycle is a fast shortcut for mental calculations involving standard basis vectors.

Cross Product vs. Dot Product

Students learning vector algebra often encounter the cross product and dot product at the same time, and it is worth understanding clearly how the two operations differ and when to use each one.

The dot product of two vectors A and B is defined as ax·bx + ay·by + az·bz, and it equals |A||B|cos(theta). It produces a scalar, a single number with no direction. A positive dot product means the vectors point in roughly the same direction; a zero dot product means they are perpendicular; a negative dot product means they point in roughly opposite directions. The dot product is defined in any number of dimensions and is the natural tool for measuring projection, work done by a force, and the similarity between directions.

The cross product, by contrast, produces a vector. Its magnitude uses the sine of the angle, so it is zero when vectors are parallel and maximum when they are perpendicular. It measures the rotational or area relationship between two vectors, not their alignment. It is only defined in three-dimensional space in the standard sense.

Dot Product
  • Result: scalar (number)
  • Formula: |A||B|cos(theta)
  • Zero when: vectors are perpendicular
  • Maximum when: vectors are parallel
  • Works in: any dimension
  • Commutative: A·B = B·A
Cross Product
  • Result: vector
  • Formula: |A||B|sin(theta)
  • Zero when: vectors are parallel
  • Maximum when: vectors are perpendicular
  • Works in: 3 dimensions (standard)
  • Anticommutative: A x B = -(B x A)

A practical rule of thumb: reach for the dot product when you want to know how much two directions agree with each other, and reach for the cross product when you need a direction that is perpendicular to two given directions, or when you want to measure an area or a rotational effect.

Applications in Physics

Physics provides some of the most natural and compelling uses of the cross product. Many of the fundamental quantities in mechanics and electromagnetism are defined as cross products because they involve both a magnitude and a direction in three-dimensional space.

Torque. When a force F is applied at a position r relative to a pivot point, the torque tau is defined as tau = r x F. The magnitude of the torque equals the force times the distance times the sine of the angle between them, which is exactly what the cross product gives. The direction of the torque vector indicates the axis around which the rotation tends to occur, following the right-hand rule. A wrench turning a bolt, a door swinging on a hinge, a wheel spinning under an applied force: all of these are governed by the torque cross product.

Magnetic force. The force on a charged particle moving through a magnetic field is F = q(v x B), where q is the charge, v is the velocity vector, and B is the magnetic field vector. The cross product means that only the component of velocity perpendicular to the magnetic field contributes to the force, and the force itself is perpendicular to both the velocity and the field. This is why charged particles in uniform magnetic fields travel in circles or helices rather than straight lines.

Angular momentum. The angular momentum of a particle is L = r x p, where r is the position vector and p is the linear momentum. Just like torque, the cross product gives both the magnitude of the angular momentum and its axis of rotation. Conservation of angular momentum, one of the most fundamental principles in physics, is expressed in terms of this cross product quantity.

Angular velocity and rotational motion. When a rigid body rotates with angular velocity omega (a vector pointing along the rotation axis), the velocity of any point at position r is v = omega x r. This cross product elegantly connects the rotation of the whole body to the linear velocity of each individual point within it.

Applications in Computer Graphics and Engineering

Outside of physics, the cross product is equally important in 3D graphics programming and in various branches of engineering.

In 3D computer graphics, every visible surface has a normal vector: a unit vector pointing perpendicularly out of the surface. Normal vectors determine how light interacts with a surface, which in turn controls shading, reflections, and the overall appearance of 3D models. To compute the normal of a triangle with vertices P1, P2, and P3, you form the edge vectors A = P2 - P1 and B = P3 - P1, then compute A x B. This gives a vector perpendicular to the triangle face. Normalizing it to unit length gives the surface normal used in lighting calculations.

Camera systems in 3D graphics also rely heavily on cross products. A camera needs three orthogonal vectors to define its local coordinate system: a forward direction, a right direction, and an up direction. Given a forward direction and a rough world-up direction, you compute the camera's right vector as the cross product of forward and up, then recompute the exact up vector as the cross product of right and forward. This process, called Gram-Schmidt orthogonalization, ensures a properly aligned coordinate system even as the camera moves and rotates.

In structural engineering and robotics, cross products appear in moment calculations, wrench analysis, and the computation of joint torques. Determining whether a set of forces on a structure creates a net rotational effect, computing the bending moment in a beam, or calculating the force that a robot joint must exert all come down to cross product operations.

Common Mistakes to Avoid

Even with a calculator handling the arithmetic, understanding the common errors in cross product work helps you set up problems correctly and interpret results with confidence.

Confusing the order of the vectors. Because A x B = -(B x A), the order of your inputs matters. Always check which vector is the first operand and which is the second. In a torque calculation, for example, it should be r x F, not F x r. Getting the order wrong gives you a result pointing in exactly the opposite direction.

Sign errors in the middle component. The formula for the y component of the cross product carries a negative sign: (A x B)y = az·bx - ax·bz, which comes from the cofactor expansion of the determinant. Students who memorize the x and z component formulas as "first times second minus second times first" often forget that the y component has this sign already built in through the determinant structure. The calculator handles this automatically, but knowing why helps you catch errors when working by hand.

Trying to apply the cross product in 2D. The standard cross product requires three-dimensional vectors. If you have 2D vectors, you need to extend them to 3D by adding a z component of zero. The resulting cross product will always point purely in the z direction, and its magnitude gives the signed area of the parallelogram formed by the original 2D vectors.

Expecting commutativity. The most persistent conceptual mistake is expecting A x B to equal B x A. The cross product is anticommutative, meaning the order of the inputs always matters. This is not an error in the calculation; it is a fundamental property of the operation.

Forgetting to normalize for direction-only questions. The cross product gives a vector whose length encodes the parallelogram area. If you only need the direction (for example, when computing a surface normal), you need to divide the result by its magnitude to obtain a unit vector. This step is called normalizing, and omitting it is a common source of subtle errors in graphics and physics code.

Frequently Asked Questions

What is the cross product of two vectors?

The cross product is a binary operation on two vectors in three-dimensional space that produces a third vector perpendicular to both input vectors. Its magnitude equals the area of the parallelogram formed by the two input vectors, and its direction is determined by the right-hand rule. Unlike the dot product, the cross product is only defined in three dimensions (and in seven dimensions as a special algebraic case), and it always produces a vector rather than a scalar.

How do you calculate the cross product using the determinant method?

Set up a 3x3 matrix with the unit vectors i, j, and k in the first row, the components of Vector A (ax, ay, az) in the second row, and the components of Vector B (bx, by, bz) in the third row. Expand along the first row using cofactor expansion: the i component is (ay·bz - az·by), the j component is -(ax·bz - az·bx), and the k component is (ax·by - ay·bx). The result is the vector (ay·bz - az·by, az·bx - ax·bz, ax·by - ay·bx).

What is the right-hand rule for cross products?

The right-hand rule is a physical gesture that tells you the direction of the cross product vector. Point the fingers of your right hand along the first vector A, then curl them toward the second vector B through the smaller angle between them. Your extended thumb points in the direction of the cross product A x B. If you reverse the order and compute B x A, your thumb would point in the opposite direction, which is why A x B = -(B x A). This rule is widely used in physics to determine the direction of torque, angular momentum, and magnetic forces.

What is the difference between the cross product and the dot product?

The cross product and dot product are both ways to multiply two vectors, but they produce completely different results and measure different geometric relationships. The dot product multiplies corresponding components and sums them, producing a scalar (a single number) that is proportional to the cosine of the angle between the vectors. The cross product produces a new vector perpendicular to both inputs, with a magnitude proportional to the sine of the angle between them. The dot product is defined in any number of dimensions, while the standard cross product only works in three dimensions. Use the dot product when you care about how much two vectors point in the same direction; use the cross product when you need a vector perpendicular to a plane or want to measure the rotational relationship between two vectors.

When is the cross product equal to zero?

The cross product A x B equals the zero vector whenever the two input vectors are parallel or antiparallel, meaning they point in exactly the same direction or exactly opposite directions. This happens because the magnitude formula is |A||B|sin(theta), and sin(0°) = sin(180°) = 0, so the magnitude is zero regardless of the lengths of the vectors. The cross product is also zero if either vector is itself the zero vector. Geometrically, a zero cross product means the two vectors lie on the same line through the origin, so they do not define a unique plane and there is no single perpendicular direction.

What are the real-world applications of the cross product?

The cross product appears throughout physics, engineering, and computer graphics. In physics, torque is defined as r x F, the cross product of the position vector and the applied force, which gives both the magnitude and rotational axis of the turning effect. The magnetic force on a moving charge is F = q(v x B), where the cross product of velocity and magnetic field determines the direction of deflection. Angular momentum L = r x p similarly uses the cross product. In 3D computer graphics, cross products are used constantly to compute surface normal vectors, which determine how light reflects off a surface, and to set up camera coordinate systems. In engineering and robotics, cross products help calculate moments, determine perpendicular directions, and test whether points are collinear. Finding the area of a triangle with known vertices is also a direct application: the area equals half the magnitude of the cross product of two edge vectors.