Skip to content
  • Open the math solver
  • Ask the AI tutor
  • Find an AP course
  • Create a quiz
  • Open the calculator
  • Graphing Calculator
  • Browse all calculators
  • Read math guides
↑ ↓Enter to open · Esc to close
Solve a problem
Linear AlgebraLinear AlgebraCollege

Vectors

Vector arithmetic, dot and cross products, unit and orthogonal vectors.

A vector has both size and direction and is written in components such as v=⟨3,4⟩\mathbf{v} = \langle 3, 4 \rangle. Vectors add tip to tail, component by component, and scalar multiplication stretches or shrinks them. The magnitude ∣v∣=32+42=5|\mathbf{v}| = \sqrt{3^2 + 4^2} = 5 is the length.

The dot product u⋅v=u1v1+u2v2+u3v3\mathbf{u} \cdot \mathbf{v} = u_1 v_1 + u_2 v_2 + u_3 v_3 measures how aligned two vectors are and equals ∣u∣∣v∣cos⁡θ|\mathbf{u}||\mathbf{v}|\cos\theta, so a zero dot product means the vectors are perpendicular. In three dimensions the cross product gives a vector perpendicular to both, with length equal to the area of the parallelogram they span.

Key terms

Dot product
Sum of products of components; zero exactly when nonzero vectors are orthogonal.
u⋅v=∑uivi\mathbf{u}\cdot\mathbf{v} = \sum u_i v_i
Unit vector
A vector divided by its length.
v^=v∥v∥\hat{\mathbf{v}} = \frac{\mathbf{v}}{\lVert\mathbf{v}\rVert}

Key ideas

  • Unit vector: v^=v∣v∣\hat{\mathbf{v}} = \frac{\mathbf{v}}{|\mathbf{v}|}.
  • Angle between vectors: cos⁡θ=u⋅v∣u∣∣v∣\cos\theta = \frac{\mathbf{u} \cdot \mathbf{v}}{|\mathbf{u}||\mathbf{v}|}.
  • Projection of u\mathbf{u} onto v\mathbf{v}: u⋅v∣v∣2v\frac{\mathbf{u} \cdot \mathbf{v}}{|\mathbf{v}|^2}\mathbf{v}.
  • Cross product is anti-commutative: u×v=−v×u\mathbf{u} \times \mathbf{v} = -\mathbf{v} \times \mathbf{u}.

Worked example

Find the angle between u=⟨1,2,2⟩\mathbf{u} = \langle 1, 2, 2 \rangle and v=⟨2,0,1⟩\mathbf{v} = \langle 2, 0, 1 \rangle.

  1. Dot product: 2+0+2=42 + 0 + 2 = 4.
  2. Magnitudes: ∣u∣=3|\mathbf{u}| = 3, ∣v∣=5|\mathbf{v}| = \sqrt{5}.
  3. cos⁡θ=435≈0.596\cos\theta = \frac{4}{3\sqrt{5}} \approx 0.596.
  4. θ≈53.4∘\theta \approx 53.4^\circ.

Answer: about 53.4∘53.4^\circ

Common mistakes

  • Multiplying magnitudes instead of components for the dot product.
  • Forgetting the square root in the magnitude.
  • Expecting the dot product to be a vector.

Practice questions

Try each one, then open the answer. Numerical answers on this page are verified by an automated calculation check.

  1. 1.Find ∣⟨6,8⟩∣|\langle 6, 8 \rangle|.

    Show answer

    1010

  2. 2.Find ⟨2,−1,3⟩⋅⟨4,5,1⟩\langle 2, -1, 3 \rangle \cdot \langle 4, 5, 1 \rangle.

    Show answer

    66

  3. 3.For which kk is ⟨k,2⟩\langle k, 2 \rangle perpendicular to ⟨3,−6⟩\langle 3, -6 \rangle?

    Show answer

    k=4k = 4

Keep practising

More in Linear Algebra