Combining, Dividing & Defining 2D and 3D Vectors
I have written about Vectors back in Feb 2020 (in this post called Introduction to Vectors) but seeing as that was so long ago I wanted to refresh my mind on the topic by writing a bit of a meatier post (as we covered more of this than we did at UWE).
// Notes taken from my lectures at the University of Kent 2022
Starting at the beginning, what is a vector? A vector is a line that has been given a length and a direction whereas a line only has a length. When we represent a vector mathematically, we do so with a lowercase letter that has been underlined i.e. . We say that any line that shares the same length and direction are the same vector and if we have a line going in the opposite direction then that is minus the vector i.e. . If the line is twice as long then it is twice the vector or . If the line is half as long then we say half the vector or . If the line is in a different direction or is a different size then it is a different vector.
Combining Vectors
We can combine vectors which is essentially the same as saying that you start at one point, travel along the first vector, then the second until you reach a second point at the end of the second vector. The vectors are lowercase underlined and the points are uppercase. The journey along these two vectors would be written which can also be written (with an arrow above). Vector & are not interchangable as we are going from point to point .
The straight line that we get by joining & is the resultant and is NOT a vector. A resultant is a sort of “as the crow flies” distance between the starting and and points of the journey. If the vector can be drawn anywhere on the page then they are called “free vectors” as opposed to “position vectors” which are in a specific place on the page/grid.
When we use position vectors we need to be able to describe where about the vector is on the grid. To do this we can use grid points i.e. Point equals or we can use & notation i.e. , or we can use column vectors (which is essentially like a matrix) i.e. . To see this in action, let’s also say that equals or , or .
When calculating position vectors we can only travel from the origin to () or from the origin to () so if we wanted to travel from to we would need to do so via the origin i.e. or . Even though we’ve travelled all the way down to the origin and then back up again, the resultant is simply the distance between the two points. The resultant in this instance is .
To find the length, size, magnidude or modulus of a vector we use pythagoras. The notation for this is . To find the size of we can say . To find the length of the resultant then we would use pythagoras on our previous calculation so meaning .
The last thing to dsicuss in the first prt of this post is to talk about what a unit vector is. A unit vector is a vector that has a length of 1 unit and has to be either parallel or inline with the original vector. If we calculated a vector that has a length of 5 i.e. then meaning a unit vector would be a of the original i.e. .
Dividing a Line (Midpoint)
When finding the midpoint of a line we need to know how to get from the origin to and then the origin to . So we would determine that and . We then need to find where is the midpoint of the line . We know how to get from to because and if is the midpoint, then we know it’s half way along i.e. . We need to go from to and then to the midpoint ( to ). If then
// The example above shows how we go about dividing a line in half and the way we need to think about doing it which will make understanding how to divide a line generically (not exactly in half) a bit easier to comprehend.
Dividing a Line (Generic)
As with the midpoint method we need to go from to and then to the point which is somewhere between and .
Equation of a Line
When dealing with vectors there are two methods for finding the equation of a line.
- 1 fixed point and vector gradient
- 2 fixed points
One Fixed point and a gradient
Gradient is the change in divided by the change in or . For a gradient of you would go up one and across two. Let’s look at a fixed point example. Let’s say that our fixed point is and that the gradient is or . If we want to get from the origin to our point then we know that . What we’re aiming to do is to calculate our resultant which will get us to any point on the line.
At this stage we know how to get to point and we know our gradient so by knowing that we can get to any point on the line. If we go from the origin to and then some multiple of the gradient, we’ll get to our desirde point on the line .
Resultant: get to the fixed point and add a multiple of the gradient.
Two Fixed points
When using two fixed points we’re using points are on the line and not at the ends of the line. We know the two points and but we need to get to any point on the line . If we can get from to , getting from to is just a multiple of that.
In the example above we know that and that point so and . The line goes through the points and to get to we have to go from the origin to (travelling along ) and then to get to we plus a multiple of to .
and
The resultant of (which is the same as )
3D Vectors
So far we’ve looked at 2D vectors to understand the principles but now we’re going to look at 3D vectors. This means that we have the usual accross () and up and down () and now in/out () axis to consider.
Let
The direction ratio is which is also the gradient (shown by the orange line in the image).
Three methods for finding the equation of a line
We looked previously at finding the equation of a line using either a fixed point and a gradient or by using two fixed points which is the vector equation of a line. Now we are going to introduce another two methods for finding the equations of a line.
- Vector (Which we’ve seen already)
- Parametric
- Cartesian
All these methods are equivalent to each other in that they all describe the same line.
We’ve got our vector equation of a line i.e. .
Parametric Form
From this vector expression, if we split the three dimensions (, and or , and ) into their respective parts we would get:
Because we have specified what our , and equal we don’t need to include the , or in each expression. This is the parametric form of our lines equation.
Cartesian Form
When writing out the Cartesian form we take the parametric form and rearrange for .
This is nearly it for writing out our equation in Cartesian form, the only issue is that we can’t have a negative denominator so for the element of our equation we will need to multiply both the top and the bottom by . So .
// Conversely, if we’re going from Cartesian form back to Parametric form, we need to ensure the letter is positive (not the denominator as we’ve just seen).
Our final Cartesian form expression for this example would therefore be .