No history yet

Vector Basics

More Than Just a Number

Some quantities in the world can be described with a single number. Your height, the temperature outside, the price of a coffee — these are all scalars. They only have magnitude, or size.

But what if you need to describe movement? If you say you walked 5 miles, that’s a scalar. But if you say you walked 5 miles northeast, you've described both a distance and a direction. That's a vector.

Vectors are mathematical objects that have both magnitude and direction. They are essential in physics, engineering, and computer graphics to describe forces, velocities, and displacements.

A scalar has magnitude. A vector has magnitude and direction.

We often represent vectors as arrows. The length of the arrow shows its magnitude, and the way it points shows its direction. In a 2D Cartesian coordinate system (a simple x-y graph), we can describe a vector by its components along each axis.

The vector vv in this graph can be written as (4,3)(4, 3). This means it has a component of 4 units along the positive x-axis and 3 units along the positive y-axis.

Vector Operations

We can perform mathematical operations with vectors, just like with numbers. But the rules are a little different.

Scalar Multiplication

The simplest operation is scalar multiplication. This means multiplying a vector by a scalar (a regular number). This changes the vector's magnitude, or length. If you multiply by a negative number, it also reverses the vector's direction.

For example, if we have our vector v=(4,3)v = (4, 3), then multiplying it by 2 gives a new vector, 2v2v. This new vector points in the same direction but is twice as long.

2v=2×(4,3)=(2×4,2×3)=(8,6)2v = 2 \times (4, 3) = (2 \times 4, 2 \times 3) = (8, 6)

Multiplying by -1 would give v=(4,3)-v = (-4, -3), a vector of the same length pointing in the exact opposite direction.

Lesson image

Vector Addition and Subtraction

To add two vectors, we can place them head-to-tail. The resulting vector, called the resultant, goes from the tail of the first vector to the head of the second. This shows the combined effect of the two vectors.

Component-wise, addition is straightforward. You just add the corresponding components. Let's say we have two vectors: a=(1,4)a = (1, 4) and b=(4,2)b = (4, 2).

a+b=(1+4,4+2)=(5,6)a + b = (1+4, 4+2) = (5, 6)

Subtraction works similarly. To find aba - b, you can think of it as adding a negative vector: a+(b)a + (-b). The vector b-b has the same magnitude as bb but points in the opposite direction. Component-wise, you just subtract.

ab=(14,42)=(3,2)a - b = (1-4, 4-2) = (-3, 2)

Multiplying Vectors

Multiplying two vectors is more complex than adding them. There are two main ways to do it: the dot product and the cross product.

The Dot Product

The dot product takes two vectors and returns a single number (a scalar). It's a way of measuring how much one vector points in the direction of another. If two vectors are perpendicular, their dot product is zero. If they point in the same direction, their dot product is the product of their magnitudes.

To calculate it, you multiply the corresponding components and add the results. For our vectors a=(1,4)a = (1, 4) and b=(4,2)b = (4, 2):

ab=(1)(4)+(4)(2)=4+8=12a \cdot b = (1)(4) + (4)(2) = 4 + 8 = 12

The dot product is useful for calculating work in physics, where only the force in the direction of motion matters, and for determining the angle between two vectors.

The Cross Product

The cross product, on the other hand, takes two vectors and produces a new vector. This operation is only defined for vectors in three dimensions.

The resulting vector is perpendicular to both of the original vectors. Its direction is determined by the "right-hand rule": if you point your index finger in the direction of the first vector and your middle finger in the direction of the second, your thumb points in the direction of the cross product.

The magnitude of the cross product vector is equal to the area of the parallelogram formed by the two original vectors. It's largest when the vectors are perpendicular and zero when they are parallel.

Lesson image

Calculating the cross product is more involved. For two 3D vectors u=(u1,u2,u3)u = (u_1, u_2, u_3) and v=(v1,v2,v3)v = (v_1, v_2, v_3), the formula is:

u×v=(u2v3u3v2,u3v1u1v3,u1v2u2v1)u \times v = (u_2v_3 - u_3v_2, u_3v_1 - u_1v_3, u_1v_2 - u_2v_1)

The cross product is crucial for calculating things like torque, angular momentum, and magnetic forces.

Quiz Questions 1/6

Which of the following is a vector quantity?

Quiz Questions 2/6

Given two vectors, a=(2,5)a = (2, 5) and b=(3,1)b = (3, -1), what is the resultant vector of 2a+b2a + b?