Vector Calculator
Calculate magnitude, unit vector and direction angles for a 3D vector
Magnitude
How we calculated it
About the Vector Calculator
A vector combines magnitude with direction and is often represented by components such as x, y and z. Vectors are used for force, velocity, displacement and many geometric calculations where direction matters.
This calculator can combine vectors, scale them and derive quantities such as magnitude. The meaning of the components depends on the coordinate system chosen for the problem.
How to Use the Vector Calculator
- Enter vector components in a consistent coordinate system.
- Choose the supported vector operation.
- Calculate the result and review both components and magnitude where relevant.
- Keep units and axis directions consistent across all vectors being combined.
How the Calculation Works
Vector addition and subtraction operate component by component. For v=(x,y,z), magnitude |v|=√(x²+y²+z²).
Scalar multiplication multiplies every component by the same scalar. Direction can be represented through normalized components by dividing each component by the vector magnitude when the magnitude is non-zero.
Worked examples
Vector Calculator Worked Examples
Default
<3, 4, 12> has a magnitude of 13. Its unit vector is <0.23077, 0.30769, 0.92308>.
Diagonal
<1, 1, 1> has a magnitude of 1.732051 and makes 54.736° with each axis.
Mixed signs
<2, −3, 6> has a magnitude of 7.
3D vectors
Angles are to the x, y and z axes.
| Vector | Magnitude | Unit vector | Direction angles |
|---|---|---|---|
| <3, 4, 12> | 13 | <0.2308, 0.3077, 0.9231> | 76.66°, 72.08°, 22.62° |
| <1, 0, 0> | 1 | <1, 0, 0> | 0.00°, 90.00°, 90.00° |
| <1, 1, 1> | 1.7321 | <0.5774, 0.5774, 0.5774> | 54.74°, 54.74°, 54.74° |
| <2, -3, 6> | 7 | <0.2857, -0.4286, 0.8571> | 73.40°, 115.38°, 31.00° |
| <0, 5, 0> | 5 | <0, 1, 0> | 90.00°, 0.00°, 90.00° |
| <-1, 2, 2> | 3 | <-0.3333, 0.6667, 0.6667> | 109.47°, 48.19°, 48.19° |
How the calculator works
The magnitude of a 3D vector is √(x² + y² + z²). The unit vector divides each component by the magnitude, giving a vector of length 1 in the same direction. The direction angles are the arccosines of the unit vector's components, the angles the vector makes with each axis.
Using vectors
Vectors represent forces, velocities, displacements and directions in 3D graphics. The unit vector keeps direction without size, which is useful for lighting and movement in games. For a 2D vector, enter 0 for z. The squares of the three direction cosines always add to 1, which is a handy check.
Common Mistakes
- Adding components for magnitude. Square, add, then take the root.
- Zero vector. It has no direction or unit vector.
- Mixing 2D and 3D. Set z to 0 for flat vectors.
Result guide
Understanding Your Vector Calculator Result
The component result tells you direction and signed contribution along each axis, while magnitude gives the overall size without direction.
Before you rely on the answer
Assumptions and Limitations
- Vectors use the same coordinate axes and units.
- Magnitude is based on Euclidean geometry.
- A zero vector cannot be normalized because its magnitude is zero.
Practical tip
Using This Result in Practice
Draw the axis directions before assigning signs. In mechanics problems, most vector mistakes come from changing the positive direction halfway through the calculation rather than from the arithmetic itself.
Related calculations
Useful Calculations to Continue With
If you need the scalar product between two vectors, use the Dot Product Calculator.
If you need a perpendicular vector from two three-dimensional vectors, use the Cross Product Calculator.
Common questions
Vector Calculator FAQ
What is vector magnitude?
Its length: √(x² + y² + z²).
What is a unit vector?
A vector of length 1 pointing the same way.
What are direction angles?
Angles between the vector and each axis.
Can I use 2D vectors?
Yes. Enter 0 for z.
What is the zero vector?
<0, 0, 0>, with no direction.
