About the Vector Calculator
Vectors describe quantities with both size and direction: a displacement, a velocity, a force or an electric field. Most work with them comes down to a handful of operations, carried out one component at a time, plus the Pythagorean theorem for length.
This calculator performs those operations exactly. A vector such as ⟨2, −1, 3⟩ has magnitude √14, not just 3.7417, and its unit vector is written ⟨√14/7, −√14/14, 3√14/14⟩ with the roots in the numerators, the form most textbooks expect. For dot products, angles and projections, use the dot product calculator; for perpendicular vectors in space, use the cross product calculator.
What is a vector?
A vector is an ordered list of components, such as ⟨3, 4⟩ in the plane or ⟨1, 2, 2⟩ in space. It can be drawn as an arrow; moving the arrow without turning it does not change the vector. The magnitude is the arrow's length, and the direction is where it points.
Two vectors are added by adding matching components, which corresponds to placing the arrows tip to tail. Multiplying by a scalar stretches or shrinks the arrow, and a negative scalar reverses it. A unit vector has length exactly 1 and is used to describe a pure direction.
How to use the Vector Calculator
- Choose the operation: magnitude and unit vector, add, subtract, scalar multiple, linear combination or components.
- Type vectors as (x, y) or (x, y, z); fractions such as 1/2 are fine.
- Enter any scalars the operation needs.
- For components, enter the magnitude and the angle from the positive x-axis in degrees.
- Press Calculate and read the result with each step.
Formulas
Magnitude
Unit vector
Linear combination
Components from magnitude and angle
Worked example: |⟨3, 4⟩| and unit vector
The worked example finds the magnitude and unit vector of . The magnitude is , and dividing each component by 5 gives .
Its direction angle is from the positive x-axis. A quick check confirms the unit vector: .
The solution below is generated by the same engine that powers the calculator above.
Final answer
How we read your problem
Vector magnitude and unit vector using exact components.
Step-by-step solution
Square the components and add them
Take the square root for the magnitude
Divide each component by the magnitude for the unit vector
Check: the unit vector has length 1
Direction angle from the positive x-axis
Formulas used
Magnitude
Unit vector
Linear combination
Vectors are added, subtracted and scaled one component at a time. The magnitude comes from the Pythagorean theorem, and dividing by it gives a unit vector of length 1 pointing the same way.
Verification
- The unit vector's components square and add to 1.
Detailed explanation
Exact magnitudes and rationalised unit vectors
When the sum of squares is not a perfect square, the magnitude is left as a simplified root. For the sum is , so the magnitude is . The unit vector divides each component by , and rationalising gives .
Fractions in the vector are handled the same way. For the sum of squares is , the magnitude is , and the unit vector is .
Linear combinations
A linear combination scales each vector, then adds them. With , , and , the scaled vectors are and , and their sum is .
Combinations like this appear when solving for a resultant force, when expressing one vector in terms of others, and throughout linear algebra, where the set of all combinations of some vectors is called their span.
Resolving into components
Physics problems often give a vector as a magnitude and an angle, such as a 10 N force at 30° above the horizontal. Its components are N horizontally and N vertically.
Once forces are in component form, they can be added directly. Converting back uses the magnitude formula and , which places the angle in the correct quadrant.
Standard unit vectors i, j and k
Many textbooks write vectors with the standard unit vectors , and . The vector is the same as , so enter it in the calculator as (2, -1, 3).
Writing a vector this way is itself a linear combination: the components are the coefficients of i, j and k. In the plane only i and j are needed, and a term that is missing simply has a coefficient of zero, as in .
Common mistakes
- Forgetting to square negative components, or squaring −1 as −1.
- Dividing only some components by the magnitude when forming the unit vector.
- Adding vectors with different numbers of components.
- Using arctan(y/x) for the direction without checking the quadrant.
- Mixing up the magnitude of a sum with the sum of the magnitudes.
Tips
- Check a unit vector by confirming that its components square and add to 1.
- Multiplying by k multiplies the length by |k|.
- Write vectors in column form when adding by hand so components line up.
- Use the dot product calculator for angles and projections between vectors.
- Use the cross product calculator to find a vector perpendicular to two others in space.
Frequently asked questions
How do I find the magnitude of a vector?
Square each component, add the squares and take the square root. The magnitude of ⟨3, 4⟩ is √(9 + 16) = 5.
How do I find a unit vector?
Divide every component by the vector's magnitude. The unit vector of ⟨3, 4⟩ is ⟨3/5, 4/5⟩.
Does the zero vector have a unit vector?
No. Its magnitude is 0, so dividing by it is undefined, and it has no direction.
How do I subtract two vectors?
Subtract matching components: ⟨1, 2⟩ − ⟨4, −5⟩ = ⟨1 − 4, 2 + 5⟩ = ⟨−3, 7⟩.
What is a linear combination of vectors?
It is a sum of scalar multiples, a·u + b·v. For example, 2⟨1, 2⟩ − 3⟨3, −1⟩ = ⟨−7, 7⟩.
How do I find the components of a force at an angle?
Multiply the magnitude by cos θ for the x-component and by sin θ for the y-component, with θ measured from the positive x-axis.
Can I enter 3D vectors with fractions?
Yes. Type a vector such as (1/2, 3, -2/3); results stay exact.
Work with vectors
Choose an operation above and enter your vectors to get exact results with every step.