Mathematics & StatisticsLast updated: 2026-09-28

Vector Calculator (Dot Product)

Compute the dot product, magnitudes and the angle between 2D or 3D vectors with fully substituted working. Includes the cosθ = (a·b) ÷ (|a||b|) step and perpendicular detection via a·b = 0 — handy for math and physics.

Open My tools

a = (a₁, a₂, a₃)

Components of vector a

b = (b₁, b₂, b₃)

Components of vector b

Try an example

Enter the components of a and b to see the dot product, magnitudes and angle.

ShareXfB!L

How to use

  1. 1

    Pick the dimension

    Choose 2D (two components) or 3D (three).

  2. 2

    Enter the components

    Fill in the components of vectors a and b. Perpendicular and parallel examples are included.

  3. 3

    Read values and working

    The dot product, magnitudes and angle appear with substituted formulas. a·b = 0 means perpendicular.

Features

  • Dot products of 2D and 3D vectors with substituted component-form working
  • Magnitudes |a| and |b| plus the angle from cosθ in degrees and radians
  • Sign-based classification: acute, perpendicular (a·b = 0) or obtuse
  • Clear handling of zero vectors; inputs are never transmitted

Use cases

Check math homework

Compare hand-worked dot products and angles with the substituted steps.

Physics work calculations

Find the angle between force and displacement for W = F·s·cosθ.

Test perpendicularity

Confirm a·b = 0 for perpendicular vectors quickly and numerically.

Details

The dot product works component-wise, a·b = a₁b₁ + a₂b₂ (+ a₃b₃), and the magnitude is |a| = √(a₁² + a₂² + a₃²). The angle θ between vectors follows from rearranging the definition a·b = |a||b|cosθ into cosθ = (a·b) ÷ (|a||b|). The tool substitutes your components into every one of these formulas.

The sign of the dot product reveals how two vectors relate: a·b > 0 means an acute angle (pointing in similar directions), a·b = 0 means perpendicular, and a·b < 0 means obtuse. In particular a·b = 0 is the standard perpendicularity test, and it appears in physics as a force doing zero work when it acts perpendicular to the displacement.

Conditions: the angle is defined only when both |a| and |b| are greater than zero — the angle against a zero vector is undefined and reported as such. Components accept plain numbers with absolute values up to one million in 2D or 3D. Inputs are never transmitted; all computation happens locally in your browser.

FAQ

What is a dot product?

It is an operation that turns two vectors into the single number |a||b|cosθ. Component-wise it is a·b = a₁b₁ + a₂b₂ (+ a₃b₃), and both formulas give the same value. The result is a number, not a vector.

How do I find the angle between vectors?

Rearrange the definition a·b = |a||b|cosθ into cosθ = (a·b) ÷ (|a||b|) and apply the inverse cosine. The tool shows the substitution through to the angle in degrees and radians.

What does a·b = 0 mean?

It means the angle between the vectors is 90° — they are perpendicular. If either vector has magnitude zero the angle is undefined, so such a pair is not called perpendicular.

What does the sign of the dot product tell me?

a·b > 0 gives an acute angle (0°–90°), a·b = 0 is perpendicular, and a·b < 0 is obtuse (90°–180°) — one number that summarizes how much two directions agree.

All processing happens in your browser. Your files are never uploaded.

Verified: Known values ((3,4)·(4,3)=24, 3D dot 20, perpendicular 90°, parallel 0°), zero-vector handling and the English page are covered by browser tests

Did you know?

A zero dot product means perpendicular — the same test that games and architecture use to check how light strikes a surface, and why a force perpendicular to motion does no work.

Optional usage measurement settings

Only with your consent, a random browser ID and tool/learning events are sent to measure return visits. This is pseudonymous measurement. Inputs, answers, keys, files and search terms are excluded. Consent expires after 90 days. Declining does not limit any feature.

Measurement is off.

Retention and privacy