# Vectors and Vector Arithmetic

Pure numbers are very useful in many situations. They can tell us about various important properties. Examples might include the temperature in a room (measured in degrees Celsius or Fahrenheit), the speed at which we are travelling in a moving vehicle (measured in miles or kilometres per hour), or the weight of an object (measured in pounds or kilogrammes). These numbers are often an indication of where a value lies on some *scale* (for example the graduated glass tube in a thermometer, the speed dial in a speedometer, or the range of outputs that can be displayed by a set of digital scales). In cases such as this, the number represents one possible value in a finite range of values. Numbers used in this way are referred to as *scalar values*, and the number alone is sufficient to provide us with the information we require.

Quantities such as speed and temperature can be represented by scalar values

There are other situations where a scalar value alone does *not* give us all of the information we need. The pilot of an aircraft, for example, obviously needs to know how fast they are going. Unlike the driver of a motor vehicle, however, the pilot does not have a road to follow, and therefore needs to know in which *direction* they are flying. Indeed, things get even more complicated for a pilot. There are many other factors to consider, such as the aircraft's current *altitude* (i.e. the height above the ground) and the aircraft's *attitude* (the combination of *yaw*, *roll* and *pitch*). Indeed, think about *any* object moving across a planar surface, or through some three-dimensional space. A scalar value can give us the relative *speed* of the object, but what about its *direction*?

Airspeed is just one of several factors important to a pilot

The combination of a moving object's speed and direction at any given moment in time is called its *velocity*. Let's assume for argument's sake that we know an object's velocity. Let's also assume that we know where that object currently is in terms of its *x* and *y* coordinates in a plane, or its *x*, *y* and *z* coordinates in some three-dimensional space. Armed with this information, and providing the object's velocity remains constant, we can work out where it will be at some later point in time. An object's velocity can be stored as a set of numbers that tell us how far it will travel in a given period of time (e.g. one second, or one hour) relative to each axis of a two-dimensional plane or three-dimensional space. This set of numbers is referred to as a *vector*.

The use of vectors is not limited to describing velocity. Vectors can also be used to describe the magnitude and direction of a *force*, or of *acceleration* (i.e. the change in velocity over time). For the moment, let's keep things relatively simple by concentrating on two-dimensional vectors. We will confine ourselves to thinking about how we get from point **A** to point **B** (assume that points **A** and **B** are two distinct points on a plane). Any movement from **A** to **B** requires some degree of displacement relative to each of the plane's *x* and *y* axes (even if the displacement relative to one of the axes has a value of zero). An example may help to clarify matters. The graphic below shows a vector represented by a grey arrow connecting points **A** and **B**. The direction of the arrow indicates that the movement takes place in the direction from **A** to **B** (as opposed to the opposite direction, from **B** to **A**). Point **A** has the coordinates *x*=1, *y*=1, while point **B** has coordinates *x*=6, *y*=4.

A movement from point **A** to point **B** is represented by the vector (5, 3)

The displacement along the *x*-axis is represented by the *red* arrow, which has a length of *five* (5) units. The displacement along the *y*-axis is represented by the *blue* arrow, which has a length of *three* (3) units. The vector can be written as an *ordered pair*, representing the displacement along the *x* and *y* axes respectively, as (5, 3). The term *ordered pair* simply reflects the convention of always writing the *x* displacement first, followed by the *y* displacement. You should be able to see from the above that the vector's ordered pair can be derived by subtracting the *x* and *y* start point coordinates from the *x* and *y* end point coordinates, i.e. 6 - 1 = 5, 4 - 1 = 3. Conversely, given a starting point of (1, 1) and a vector (5, 3), we can find the end point coordinates by adding the vector's ordered pair to the start point coordinates, i.e. 1 + 5 = 6, 1 + 3 = 4.

Although you may have already grasped the point, we would emphasise here that a vector is often an independent entity. In other words, it simply represents movement in a given direction and of a given magnitude. As such, it can be applied to *any* starting point. To demonstrate this, consider the graphic below in which the same vector is applied to two *different* starting points. In both cases, applying the vector (3, 2) increases the *x*-coordinate by *three*, and the *y*-coordinate by *two*. Note that the *magnitude* of a vector is represented by its *length*. Note also that while drawing vectors makes it very easy for us to visualise them, we will at some point need to start working with a non-visual form of vector notation in order to be able to carry out vector arithmetic more efficiently.

The vector (3, 2) is applied to points **A** and **C**

Two vectors are *equal* (i.e. they are effectively the same vector) if, and *only if*, they have the same magnitude and direction. In other words, the arrows representing the vectors must point the same way, and be of the same length (the length represents the magnitude of the vector). Looking at the above figure, you may well conclude that the red and blue arrows representing the displacement in the *x* and *y* directions respectively can themselves be considered to be vectors. This is indeed the case. In fact, the vector (3, 2) is the result of adding these two vectors - (3, 0) and (0, 2) - together. Vector addition is dealt with elsewhere, but for now it is useful to know that *any* two dimensional vector that is not perpendicular to either axis is the result of adding two additional vectors - one that acts in the *x* direction, and one that acts in the *y* direction. These two vectors can be regarded as the legs of a right-angled triangle for which the *resultant* vector forms the hypotenuse.

Various forms of notation are used for vectors. We have already seen one of the simplest forms of notation for a two-dimensional vector using brackets. Both of the vectors shown in the above illustration, for example, can be written simply as (3, 2). This simply gives an ordered pair of *x* and *y* values that gives us the horizontal and vertical distances between the tail of the arrow and its head. Bear in mind that a vector such as (3, 2) is not tied to a specific starting point. It is what we call a *free vector*, because it can be applied to any given point of origin. If we wish to denote a vector that specifically indicates movement from one known fixed point to another, we use a somewhat different notation.

The directed line segment between points **A** and **B** in the above illustration, for example, is the visual representation of a vector. A vector that has a fixed point of origin is not a free vector. It is usually referred to as a *position vector*. We can refer to the position vector that describes the movement from point **A** to point **B** using the notation *AB*→. The arrow above the characters *AB* denotes the direction of movement (i.e. from point **A** to point **B**, and not the other way round). Of course, this notation does not give us the information we need in order to work out how far we must move in each of the *x* and *y* directions in order to get to point **B** from point **A**. We would therefore probably write something like the following, which expresses the vector in *row vector* form:

*AB*→ = (3, 2)

This tells us that in order to get from our point of origin (point **A**) to our designated end point (point **B**), we need to increase the value of our *x*-coordinate by *three*, and increase the value of our *y*-coordinate by *two*. Note that this form of notation is also used in a three-dimensional space. The only difference is that a third vector value is added to represent the required increase (or decrease) in the value of the *z*-coordinate. Position vectors are used in navigational systems, where they are used to describe the distance and direction of an object (an aircraft or a ship, for example) from a fixed reference point. They can also be found in many other situations, including the study of mechanics and astrodynamics, and in computer games and simulations. Note that an ordered pair of *x* and *y* coordinates for any point in a Cartesian coordinate system also represents a vector. The same can be said of an ordered triple of *x*, *y* and *z* coordinates for any point in a three-dimensional coordinate system. These vectors give the magnitude and direction of a point's displacement from the origin (essentially, they are position vectors).

Free vectors can be named using lower-case characters. In the illustration below, the free vector *c* appears twice (note that vector names are often printed in bold type). A second free vector, *-c*, is also shown. This vector has the same *magnitude* as vector *c*, but acts in the opposite direction. A minus sign ("-") in front of a vector name usually indicates that a vector with the same name, and having the same magnitude, already exists. The minus sign simply indicates that the new vector works in the opposite direction to the original vector. We could of course simply give the new vector a completely different name, but it is sometimes convenient to be able to refer to two vectors in a way that makes it obvious that one vector negates (i.e. cancels out) the other. Note that for the left-most instance of vector *c* in the illustration, we have also shown its *component vectors* (vectors *a* and *b*).

Vector *c* is a free vector

Using row vector form, we can define the different vectors in the above illustration as follows:

*a* = (3, 0)

*b* = (0, 2)

*c* = (3, 2)

**- c** = (-3, -2)

When we start to look at vector arithmetic, we will find that it is convenient to store vector information in a *matrix*. We can use matrices to store a significant amount of vector information in a relatively compact form, and can then manipulate that information using matrix arithmetic. If you are unfamiliar with matrix arithmetic, it might be useful to have a look at the relevant pages in the Algebra section of this website. Vector information is stored within matrices as vertical columns, as shown below.

AB→ = | 3 | ||

2 |

You might be able to deduce from the above that vector *c* is the sum of its component vectors, *a* and *b*. Although vector addition is dealt with in more detail elsewhere, it is worth noting here that the result of adding two vectors together is always another vector (called the *resultant*). The *magnitude* of the resultant (i.e. its length) can be calculated using Pythagoras' theorem, since the resultant is effectively the hypotenuse of a right-angled triangle for which the component vectors form the legs. In order to calculate the length of vector *c*, for example, we could perform the following calculation:

**| c|** = √(

**|**

*a*|^{2}+

**|**

*b*|^{2}) = √(3

^{2}+ 2

^{2}) = √(13) = 3.606

We have (rather sneakily!) introduced a new form of notation here. For our calculation, what we are interested in using is the *magnitude* of the vectors, not the vectors themselves. The standard notation for expressing the magnitude of a vector in a mathematical expression is to place vertical bars on either side of the vector's name. The magnitude of vector *a* is thus be expressed as **| a|**.