Skip to content
5 MIN LESSON · MATHEMATICS

Vector Algebra: Components, Dot Product and Cross Product

Vectors and their types, addition, components along i, j and k, direction cosines, the section formula, the scalar (dot) product and projections, and the vector (cross) product with areas.

Scalars and vectors

A scalar has magnitude only (length, mass, time). A vector has magnitude and direction (displacement, velocity, force). A vector is drawn as a directed line segment AB→ from its initial point A to its terminal point B. Its length is its magnitude, written |AB→| or |a|.

Types of vectors

Type

Meaning

Zero (null) vector

magnitude 0, no definite direction

Unit vector

magnitude 1; the unit vector along a is a divided by its own magnitude, written â

Co-initial vectors

same initial point

Collinear (parallel) vectors

parallel to the same line, whatever their magnitudes

Equal vectors

same magnitude and same direction

Negative of a vector

same magnitude, opposite direction

Adding vectors

  • Triangle law: place the tail of b at the head of a; a + b goes from the tail of a to the head of b.

  • Parallelogram law: for co-initial a and b, the diagonal of the parallelogram they form is a + b.

Addition is commutative and associative. Multiplying by a scalar λ scales the magnitude by |λ| and reverses the direction if λ < 0.

Components

î, ĵ and k̂ are unit vectors along the x, y and z axes. The position vector of the point P(x, y, z) is

r = xî + yĵ + zk̂, with |r| = √(x² + y² + z²).

The vector from A(x₁, y₁, z₁) to B(x₂, y₂, z₂) is AB→ = (x₂ − x₁)î + (y₂ − y₁)ĵ + (z₂ − z₁)k̂.

Vectors are added and scaled component by component. Two vectors are equal exactly when their components are equal.

Direction cosines. If r makes angles α, β, γ with the axes, then l = cos α, m = cos β, n = cos γ are its direction cosines, with l = x/|r|, m = y/|r|, n = z/|r| and l² + m² + n² = 1. Any numbers proportional to them are direction ratios.

Example. For a = 2î − ĵ + 2k̂: |a| = √(4 + 1 + 4) = 3, the unit vector is (2/3)î − (1/3)ĵ + (2/3)k̂, and the direction cosines are 2/3, −1/3, 2/3.

Section formula

If R divides the join of points with position vectors a and b in the ratio m : n:

  • internally: r = (mb + na) ⁄ (m + n)

  • externally: r = (mb − na) ⁄ (m − n)

The midpoint is (a + b)/2.

The scalar (dot) product

a · b = |a| |b| cos θ, where θ (0 ≤ θ ≤ π) is the angle between them. The result is a scalar.

In components: if a = a₁î + a₂ĵ + a₃k̂ and b = b₁î + b₂ĵ + b₃k̂, then

a · b = a₁b₁ + a₂b₂ + a₃b₃

Properties:

  • a · b = b · a (commutative), and it distributes over addition.

  • a · b = 0 if and only if a and b are perpendicular (for non-zero vectors).

  • î · î = ĵ · ĵ = k̂ · k̂ = 1 and î · ĵ = ĵ · k̂ = k̂ · î = 0.

  • a · a = |a|².

Angle between vectors: cos θ = (a · b) ⁄ (|a| |b|).

Projection of a on b: (a · b) ⁄ |b|.

Example. a = î + 2ĵ − k̂, b = 3î − ĵ + k̂. a · b = 3 − 2 − 1 = 0, so the vectors are perpendicular.

Example. Projection of a = 2î + 3ĵ + 2k̂ on b = î + 2ĵ + k̂: (2 + 6 + 2)/√6 = 10/√6.

The vector (cross) product

a × b = |a| |b| sin θ n̂

where n̂ is a unit vector perpendicular to both a and b, pointing in the direction given by the right-hand rule (curl the fingers from a to b; the thumb points along n̂). The result is a vector.

In components, as a determinant:

a × b = (a₂b₃ − a₃b₂)î − (a₁b₃ − a₃b₁)ĵ + (a₁b₂ − a₂b₁)k̂

Properties:

  • a × b = −(b × a): not commutative.

  • a × b = 0 if and only if a and b are parallel (or one is zero).

  • î × ĵ = k̂, ĵ × k̂ = î, k̂ × î = ĵ, and î × î = ĵ × ĵ = k̂ × k̂ = 0.

Areas:

  • Area of a parallelogram with adjacent sides a and b = |a × b|.

  • Area of a triangle with adjacent sides a and b = ½ |a × b|.

Example. a = î + ĵ, b = ĵ + k̂. a × b = (1 × 1 − 0 × 1)î − (1 × 1 − 0 × 0)ĵ + (1 × 1 − 1 × 0)k̂ = î − ĵ + k̂. The parallelogram they form has area √3, and the triangle √3/2.

Summary

  • Vectors have magnitude and direction; |a| = √(a₁² + a₂² + a₃²); l² + m² + n² = 1.

  • a · b = |a||b| cos θ = a₁b₁ + a₂b₂ + a₃b₃; zero for perpendicular vectors.

  • a × b = |a||b| sin θ n̂; zero for parallel vectors; |a × b| is the parallelogram's area.

Practise this topic →

Discussion

Sign in to join the discussion.

Sign in

No comments yet. Be the first to share your thoughts.