Enter two vectors with the same number of components. The calculator multiplies matching components, adds those products, and explains what the scalar says about their angle.
Result
Multiply corresponding components and add the three products
a⋅b=32
Conditions
Both vectors have three components.
The entries are treated as real numbers.
The result is a scalar, not a vector.
Steps
Pair corresponding components Match first with first, second with second, and third with third.(1)(4)+(2)(5)+(3)(6)
Evaluate each product The component products are 4, 10, and 18.4+10+18
Add the products The sum is the scalar dot product.a⋅b=32
✓
Independent check
The geometric check gives ||a||||b||cos(theta)=sqrt(14)sqrt(77)(32/sqrt(1078))=32.
Scope
What this dot product covers
The dot product of equal-dimensional vectors a and b is a·b=a_1b_1+...+a_nb_n. It is a scalar, and for nonzero vectors it also equals ||a||||b||cos(theta).
Use vectors from two through six dimensions
Accept equal-length vectors and display every matching component product before the sum.
Examples: 2D, 3D, n-dimensional component lists
Keep exact fractional entries
Multiply integers, finite decimals, or simple fractions without replacing exact values too early.
Examples: 1/2, -3/4, 0.25
Interpret orthogonality and angle type
For nonzero vectors, identify perpendicular, acute, or obtuse relationships from the dot product sign.
Examples: a·b=0, a·b>0, a·b<0
Compute the angle when it is defined
Use cos(theta)=(a·b)/(||a||||b||) only when neither vector is the zero vector.
Examples: theta=90 degrees, cosine similarity
How to use it
Enter enough information for one clear task
1
Enter vector A
Separate components with commas or spaces and keep their coordinate order fixed.
2
Enter vector B with the same length
Each component needs a matching position. The dot product is not defined here for unequal dimensions.
3
Inspect the component products
Check signs before adding, especially when one vector contains negative entries.
4
Use the scalar appropriately
Interpret zero as orthogonality only for vectors in an inner-product space, and compute an angle only when both magnitudes are nonzero.
Worked inputs
Examples to try
Use these examples to recognize the method, compare equivalent forms, and check your own work.
Two-dimensional vectors
Multiply matching coordinates and add.
(2,3)⋅(4,−1)
Expected result
2(4)+3(−1)=5
Three-dimensional vectors
Add all three component products.
(1,2,3)⋅(4,5,6)
Expected result
4+10+18=32
Orthogonal vectors
The positive and negative products cancel.
(3,4)⋅(4,−3)
Expected result
12−12=0
Fractional components
Keep both products exact before adding.
(21,−1)⋅(4,23)
Expected result
2−23=21
Vector dotted with itself
The self-dot product is the squared magnitude.
(−2,1,2)⋅(−2,1,2)
Expected result
4+1+4=9
Obtuse relationship
A negative dot product means the angle is obtuse for nonzero vectors.
(1,0)⋅(−2,3)
Expected result
−2
Zero vector
Every component product is zero, but the angle is undefined.
(0,0,0)⋅(5,−2,1)
Expected result
0
Complete example
Use the dot product to find an angle
Both vectors are nonzero, so the component formula gives the scalar product and the geometric formula gives their angle.
a=(1,2),b=(2,1)
1
Calculate the dot product
Multiply corresponding components and add.
a⋅b=1(2)+2(1)=4
2
Calculate both magnitudes
Each vector has squared magnitude 5.
∥a∥=∥b∥=5
3
Solve for the cosine
Divide the dot product by the product of the magnitudes.
cosθ=554=54
4
Find the angle
Apply inverse cosine and label the decimal as an approximation.
θ=cos−1(54)≈36.87∘
a⋅b=4,θ≈36.87∘
Verification: The Cauchy-Schwarz bound gives |4|<=sqrt(5)sqrt(5)=5, and cos(theta)=0.8 lies in the valid interval from negative 1 to 1.
Avoidable errors
Common mistakes and how to fix them
Returning a vector instead of a scalar
Problem: Report the component products as (4,10,18).
Why it matters: The dot product adds those products and produces one scalar.
Better approach: Sum every matching component product after computing it.
Using vectors with different lengths
Problem: Ignore the unmatched component of a 3D vector.
Why it matters: The component definition requires one partner for every coordinate.
Better approach: Use equal-dimensional vectors or convert the data to a clearly defined common space.
Confusing dot product with cross product
Problem: Expect a perpendicular 3D vector as the result.
Why it matters: A dot product is scalar; a 3D cross product is a different operation with a vector result.
Better approach: Choose the operation by the desired output and interpretation.
Finding an angle with a zero vector
Problem: Divide by ||0|| when applying the cosine formula.
Why it matters: The zero vector has magnitude zero, so the denominator vanishes and its direction is undefined.
Better approach: Report the dot product as zero but the angle as undefined.
Trust the result for the right reasons
Checks, assumptions, and limits
How results are checked
Vector dimensions are compared before components are multiplied.
The component sum is recomputed from exact parsed values.
The bound |a·b|<=||a||||b|| is checked before an angle is reported.
Angle output is withheld when either magnitude is zero.
When to stop and revise the input
This release accepts finite real integers, decimals, and simple fractions.
Both vectors must contain the same number of components.
Symbolic vector components and weighted inner products are outside this tool's scope.
An angle from a rounded cosine is approximate and is labeled accordingly.
Common questions
Calculate the dot product of two vectors FAQ
Is the scalar product the same as the dot product?
Yes in this Euclidean-vector context. Both names refer to multiplying corresponding components and summing to produce one scalar.
What does a dot product of zero mean?
Two nonzero Euclidean vectors with dot product zero are orthogonal. If one vector is zero, the product is still zero but an angle is not defined.
Can the dot product be negative?
Yes. For two nonzero vectors, a negative dot product means their angle is greater than 90 degrees and less than 180 degrees.
Why must the vectors have the same dimension?
The component formula pairs each coordinate of one vector with the coordinate in the same position of the other. Unequal lengths leave unmatched components.
How is the dot product related to vector length?
A vector dotted with itself equals the square of its Euclidean magnitude: a·a=||a|| squared.
Sources and curriculum alignment
This page follows standard introductory mathematics notation and learning sequences. Use these references to continue with a complete course treatment.