Math Core

Lesson 1.2 · Vectors and 3D Space

Vectors in space

Many quantities need both a size and a direction to describe them: a velocity, a force, a displacement. A vector packages those two pieces of information into one object. In three dimensions vectors become the main language of the course, used for lines, planes, curves, gradients and fields, so it pays to get fluent with them now.

Vectors and their components

Geometrically, a vector is a directed line segment, an arrow. Two arrows with the same length and the same direction represent the same vector, no matter where they start. We write vectors in boldface (v\mathbf{v}) or with an arrow (v⃗\vec{v}).

If you slide a vector so its tail sits at the origin, its head lands at some point (a1,a2,a3)(a_1, a_2, a_3). Those coordinates are the components of the vector, and we write

a=⟨a1,a2,a3⟩.\mathbf{a} = \langle a_1, a_2, a_3 \rangle.

The angle brackets distinguish the vector from the point (a1,a2,a3)(a_1, a_2, a_3). The arrow from the origin to that point is the position vector of the point. On this site, when a problem asks you to enter a vector, type its components as a triple in parentheses, like (3, 4, -12).

The position vector a = ⟨2, 3, 4⟩ runs from the origin to the point (2, 3, 4). Its components are the edge lengths of the dashed box.

If an arrow starts at A(x1,y1,z1)A(x_1, y_1, z_1) and ends at B(x2,y2,z2)B(x_2, y_2, z_2), subtracting "head minus tail" gives its components:

AB→=⟨x2−x1, y2−y1, z2−z1⟩.\overrightarrow{AB} = \langle x_2 - x_1,\ y_2 - y_1,\ z_2 - z_1 \rangle.

Length, addition and scalar multiples

The magnitude (length) of a\mathbf{a} is the distance from the origin to (a1,a2,a3)(a_1, a_2, a_3):

∣a∣=a12+a22+a32.|\mathbf{a}| = \sqrt{a_1^2 + a_2^2 + a_3^2}.

The only vector with length 00 is the zero vector 0=⟨0,0,0⟩\mathbf{0} = \langle 0, 0, 0 \rangle, which has no direction.

Addition. Geometrically, a+b\mathbf{a} + \mathbf{b} is found by the triangle law: place the tail of b\mathbf{b} at the head of a\mathbf{a}; the sum runs from the tail of a\mathbf{a} to the head of b\mathbf{b}. Equivalently, it is the diagonal of the parallelogram with sides a\mathbf{a} and b\mathbf{b}. In components you simply add:

a+b=⟨a1+b1, a2+b2, a3+b3⟩.\mathbf{a} + \mathbf{b} = \langle a_1 + b_1,\ a_2 + b_2,\ a_3 + b_3 \rangle.

Scalar multiplication. For a real number cc, the vector ca=⟨ca1,ca2,ca3⟩c\mathbf{a} = \langle ca_1, ca_2, ca_3 \rangle has length ∣c∣ ∣a∣|c|\,|\mathbf{a}|. It points the same way as a\mathbf{a} if c>0c > 0 and the opposite way if c<0c < 0. Subtraction is a−b=a+(−1)b\mathbf{a} - \mathbf{b} = \mathbf{a} + (-1)\mathbf{b}; geometrically it is the arrow from the head of b\mathbf{b} to the head of a\mathbf{a} when both start at the same point.

These operations obey the familiar algebra rules: a+b=b+a\mathbf{a} + \mathbf{b} = \mathbf{b} + \mathbf{a}, (a+b)+c=a+(b+c)(\mathbf{a} + \mathbf{b}) + \mathbf{c} = \mathbf{a} + (\mathbf{b} + \mathbf{c}), c(a+b)=ca+cbc(\mathbf{a} + \mathbf{b}) = c\mathbf{a} + c\mathbf{b}, (c+d)a=ca+da(c + d)\mathbf{a} = c\mathbf{a} + d\mathbf{a}, and so on. Each one follows immediately from the corresponding rule for real numbers, applied component by component.

Definition

Parallel vectors

Two nonzero vectors a\mathbf{a} and b\mathbf{b} are parallel if one is a scalar multiple of the other: b=c a\mathbf{b} = c\,\mathbf{a} for some scalar c≠0c \ne 0.

Standard basis vectors and unit vectors

The three standard basis vectors are

i=⟨1,0,0⟩,j=⟨0,1,0⟩,k=⟨0,0,1⟩.\mathbf{i} = \langle 1, 0, 0 \rangle, \quad \mathbf{j} = \langle 0, 1, 0 \rangle, \quad \mathbf{k} = \langle 0, 0, 1 \rangle.

Every vector can be written in terms of them: ⟨a1,a2,a3⟩=a1i+a2j+a3k\langle a_1, a_2, a_3 \rangle = a_1\mathbf{i} + a_2\mathbf{j} + a_3\mathbf{k}. So 3i−k3\mathbf{i} - \mathbf{k} is just another name for ⟨3,0,−1⟩\langle 3, 0, -1 \rangle.

A unit vector has length 11. Dividing any nonzero vector by its length produces the unit vector pointing in the same direction.

Unit vector and vectors of a given length

For a≠0\mathbf{a} \ne \mathbf{0}, the unit vector in the direction of a\mathbf{a} is

u=a∣a∣.\mathbf{u} = \frac{\mathbf{a}}{|\mathbf{a}|}.

The vector of length LL in the direction of a\mathbf{a} is L u=L∣a∣ aL\,\mathbf{u} = \dfrac{L}{|\mathbf{a}|}\,\mathbf{a}.

Every nonzero vector factors as a=∣a∣ u\mathbf{a} = |\mathbf{a}|\,\mathbf{u}: magnitude times direction. This split is how you'll build a velocity from a speed and a heading, or a force from its strength and line of action.

Worked example: From two points to a unit vector

Let P(2,−1,4)P(2, -1, 4) and Q(5,3,−8)Q(5, 3, -8). Find PQ→\overrightarrow{PQ}, its length, and the unit vector in its direction.

Solution. Head minus tail: PQ→=⟨5−2,3−(−1),−8−4⟩=⟨3,4,−12⟩\overrightarrow{PQ} = \langle 5 - 2, 3 - (-1), -8 - 4 \rangle = \langle 3, 4, -12 \rangle. Its length is 9+16+144=13\sqrt{9 + 16 + 144} = 13, so the unit vector is

u=113⟨3,4,−12⟩=⟨313,413,−1213⟩.\mathbf{u} = \frac{1}{13}\langle 3, 4, -12 \rangle = \left\langle \frac{3}{13}, \frac{4}{13}, -\frac{12}{13} \right\rangle.

Worked example: Combining vectors

Let a=⟨1,−2,3⟩\mathbf{a} = \langle 1, -2, 3 \rangle and b=4i−k\mathbf{b} = 4\mathbf{i} - \mathbf{k}. Find 2a−3b2\mathbf{a} - 3\mathbf{b} and ∣a+b∣|\mathbf{a} + \mathbf{b}|.

Solution. First write b=⟨4,0,−1⟩\mathbf{b} = \langle 4, 0, -1 \rangle. Then

2a−3b=⟨2,−4,6⟩−⟨12,0,−3⟩=⟨−10,−4,9⟩.2\mathbf{a} - 3\mathbf{b} = \langle 2, -4, 6 \rangle - \langle 12, 0, -3 \rangle = \langle -10, -4, 9 \rangle.

Also a+b=⟨5,−2,2⟩\mathbf{a} + \mathbf{b} = \langle 5, -2, 2 \rangle, so ∣a+b∣=25+4+4=33|\mathbf{a} + \mathbf{b}| = \sqrt{25 + 4 + 4} = \sqrt{33}.

Worked example: Balancing forces

Three forces act on an object: F1=⟨3,−1,2⟩\mathbf{F}_1 = \langle 3, -1, 2 \rangle N, F2=⟨−5,4,1⟩\mathbf{F}_2 = \langle -5, 4, 1 \rangle N, and an unknown F3\mathbf{F}_3. The object is in equilibrium. Find F3\mathbf{F}_3 and its magnitude.

Solution. Equilibrium means the net force is zero: F1+F2+F3=0\mathbf{F}_1 + \mathbf{F}_2 + \mathbf{F}_3 = \mathbf{0}. Since F1+F2=⟨−2,3,3⟩\mathbf{F}_1 + \mathbf{F}_2 = \langle -2, 3, 3 \rangle, we need F3=⟨2,−3,−3⟩\mathbf{F}_3 = \langle 2, -3, -3 \rangle N, with magnitude 4+9+9=22≈4.69\sqrt{4 + 9 + 9} = \sqrt{22} \approx 4.69 N.

Common mistake

Magnitude does not distribute over addition: in general ∣a+b∣≠∣a∣+∣b∣|\mathbf{a} + \mathbf{b}| \ne |\mathbf{a}| + |\mathbf{b}|. In the example above, ∣a∣=14|\mathbf{a}| = \sqrt{14} and ∣b∣=17|\mathbf{b}| = \sqrt{17}, but ∣a+b∣=33|\mathbf{a} + \mathbf{b}| = \sqrt{33}, which is smaller than 14+17≈7.86\sqrt{14} + \sqrt{17} \approx 7.86. The triangle inequality ∣a+b∣≤∣a∣+∣b∣|\mathbf{a} + \mathbf{b}| \le |\mathbf{a}| + |\mathbf{b}| is all you get, with equality only when the vectors point the same way. Always add the components first, then take the length.

Practice

Practice 1

Find the components of PQ→\overrightarrow{PQ} for P(1,4,−2)P(1, 4, -2) and Q(−3,6,5)Q(-3, 6, 5). Enter the vector as a triple.

Enter a point like (2, -3)

Practice 2

Find ∣⟨2,−3,6⟩∣|\langle 2, -3, 6 \rangle|.

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 3

Let a=⟨2,0,−1⟩\mathbf{a} = \langle 2, 0, -1 \rangle and b=⟨−1,4,3⟩\mathbf{b} = \langle -1, 4, 3 \rangle. Find 3a−2b3\mathbf{a} - 2\mathbf{b}.

Enter a point like (2, -3)

Practice 4

Find the unit vector in the direction of 4i−4j+2k4\mathbf{i} - 4\mathbf{j} + 2\mathbf{k}.

Enter a point like (2, -3)

Practice 5

Find the vector of length 1010 that points in the direction opposite to ⟨1,2,−2⟩\langle 1, 2, -2 \rangle.

Enter a point like (2, -3)

Practice 6

Find the value of cc that makes ⟨3,c,−6⟩\langle 3, c, -6 \rangle parallel to ⟨−1,2,2⟩\langle -1, 2, 2 \rangle.

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 7

Find all values of tt for which ∣⟨t,2,t−1⟩∣=3|\langle t, 2, t - 1 \rangle| = 3.

Separate answers with commas, e.g. 2, -5

Practice 8

The points A(1,0,2)A(1, 0, 2), B(3,1,−1)B(3, 1, -1) and C(4,5,0)C(4, 5, 0) are three consecutive vertices of parallelogram ABCDABCD. Find the fourth vertex DD.

Enter a point like (2, -3)