In this explainer, we will learn how to use the concept of slopes to determine whether two lines are parallel or perpendicular and use these geometric relationships to solve problems.
The slope of a line is one of the defining features of a straight line, describing how “steep” it is as well as giving us certain fundamental information about the properties of the straight line. The slope of a line can always be calculated from any two distinct points on the line (provided that it is not a vertical line). Suppose that there are two points on a straight line with known coordinates and . Then, the slope is the vertical displacement of these points, divided by the horizontal displacement. Expressed algebraically, we would say that the slope is found by the formula
We will briefly give an example to demonstrate this concept. Suppose we were given the straight line passing through the two points with coordinates and . The straight line having these properties is plotted below, with the two known coordinates marked.
The slope of can then be found by using the given formula and substituting and . We now calculate the slope as follows:
This is the algebraic way of calculating the slope, and we have not given much thought as to the geometric interpretation. Suppose that we took the two known points on the given line and then created a third point that forms a right triangle, as shown in the diagram below. This new point has the coordinate , and we have chosen a right triangle (rather than an equilateral or any other form) because right triangles serve as the basis for much of the fundamental results in trigonometry.
This construction allows us to now think of the slope as a combination of geometric properties, much like we alluded to it at the beginning of this explainer. We can see that the vertical line segment has a displacement that is determined by the calculation and that the horizontal line segment has a displacement given by . The two lengths associated with these distances are simply the positive values taken from these two displacements (if either of them is negative). Both of these displacements are sides of the specific right triangle that we have drawn, which provides another way of thinking about this straight line. This approach offers many benefits, the key one being that the distance between the two points can be calculated by finding the hypotenuse of the triangle by using the Pythagorean theorem.
By framing the slope in terms of the concept of a right triangle, we can use known results from trigonometry to understand other properties of the straight line. A property that we will often be interested in is the acute angle that the line makes with the horizontal axis. We have labeled this angle in the diagram above as . Two lines and are parallel if they never meet each other; and if this is the case, then we would say that . By the transversal of parallel lines property, the angle made between and the horizontal axis is the same as the angle made between the straight line of interest and any other horizontal line since any such line must be parallel to the horizontal axis.
Since we can use any horizontal line, we can use the line . In our specific example, we can find the angle between the straight line and the horizontal axis by finding the angle , as shown below, where we have made the assumption that .
Fortunately, this angle can be found by using known trigonometric relations. We recall that the vertical component of the right triangle has displacement , and this side is opposite to the angle . We also know that the horizontal component of the right triangle has displacement , and that this side is adjacent to the angle acute . We can then recall that the tangent is the ratio of the opposite side and the adjacent side in a right triangle, implying that which can be phrased more simply as , where is the slope of the straight line. In our specific example, this gives
We can then take the inverse tangent of both sides of this equation to find that . Calculated in degrees, this gives the angle .
We can also use such approaches to find the angle between a straight line and the horizontal axis when this angle is not acute. In the explanations given previously, we referred to quantities such as and as being “displacements,” meaning that it is possible for these to be negative (as opposed to a “distance,” which is always positive). This means that it is possible for the slope of a straight line to be negative, which will happen if and are of an opposite sign. In this case, the straight line will go “downhill” as we look from left to right, and the positive angle (i.e., measured clockwise) between the positive direction of the -axis and the straight line is then obtuse.
As you can observe using a calculator, the tangent of an obtuse angle is negative. The relationship we have found before between the slope of a line and the tangent of the positive angle the line makes with the positive direction of the -axis holds also for obtuse angles. Let us summarize this.
Definition: The Slope of a Straight Line through Two Points and the Angle Made with the Horizontal Axis
Consider a nonvertical straight line passing through two points with known coordinates and . Then the slope is
Furthermore, the slope is equal to the tangent of the positive angle made between the straight line and the positive direction of the -axis:
The angle is measured from the positive -axis to the line in a counterclockwise direction.
An acute angle has a positive tangent, while an obtuse angle has a negative tangent. The tangent of an angle of is undefined, and so, vertical lines are said to have undefined slope.
Let us apply this with an example.
Example 1: Finding the Slope of a Line given the Angle It Makes with the Horizontal Axis
Find, to the nearest two decimal places, the slope of the line that makes a positive angle of with the positive direction of the -axis.
Answer
Let us first visualize a line that makes an angle of with the positive direction of the -axis.
Recall that the slope of a straight line, , is equal to the tangent of the positive angle made between the straight line and the positive direction of the -axis. Here, the angle is . Hence, we have which, using a calculator and to the nearest two decimal places, gives
When working with two straight lines, we might be interested in how they might relate to each other, and in particular, whether they cross each other. Two lines will meet at a point unless they are parallel or coincident. As parallel lines are characterized by the fact that they make the same angle to a transversal, we can conclude that two lines with same slope (i.e., two lines that make the same angle with the positive direction of the -axis) are parallel or coincident. If lines have a slope of 0, they are then parallel to the -axis and so parallel to each other, even if they do not cross the -axis. Two lines are parallel but not coincident when they have the same slope but not the same -intercepts, as shown in the diagram.
Perpendicular lines meet at a point and make an angle of with each other. We will then always have one of these lines with a positive slope and the other with a negative slope, as shown in the diagram below with two lines of slopes and , respectively, making an angle and with the positive direction of the -axis respectively.
Because the lines are perpendicular, we have
A property of the tangent function is that
Hence, we have
As and , we have or
It should be noted that the above results do not immediately apply if we are working with straight lines that are either horizontal or vertical. If a straight line is horizontal, then it will have a slope of zero, meaning that we can assign the slope . Immediately, we see why we cannot use the relationship around perpendicular lines, (that ) since this would incur a division by zero. This makes sense because a vertical line is perpendicular to a horizontal line, and the “slope” of a vertical line can be thought of as being infinite. It is, of course, still perfectly valid to work with horizontal or vertical lines in a geometric sense, but we cannot automatically employ the algebraic treatment that we have described above.
Let us summarize the conditions for lines being parallel or perpendicular.
Definition: Conditions for Parallel and Perpendicular Lines
Consider two straight lines that respectively have the slopes and and the -intercepts and . Then, the following is true:
- If and , then the two lines are parallel. This means that the lines never meet and that they make the same angle with the horizontal axis.
- If and , then the two lines are identical.
- If , then the two lines will be perpendicular. This means that they meet exactly once and that the differences between these lines will always be a right angle.
If , then the associated straight line will be horizontal. Any line parallel to this will have the same slope and any line perpendicular to this will not have a defined slope (because any line perpendicular to a horizontal line must be a vertical line).
We will begin by first considering the points and and the straight line passing through these, which is shown on the graph below. We will eventually be adding four more points to this diagram, but for the moment, we will be interested in the slope of this straight line as well as the angle that it makes with the horizontal axis. Before performing any other calculations, we observe that the slope must be negative.
We can find the slope by using the known formula and by setting and . This allows us to calculate
The slope is negative, as expected. We can calculate the angle between this straight line and the horizontal axis by using the known result . This means that we calculate . This negative angle is the angle measured clockwise from the positive -axis to the straight line. The positive angle, , is then
Suppose now that we took the previous two points and gave an additional two points and and then considered the line joining and . Plotted together, we have the new diagram below, and we can see that the new straight line appears to be approximately parallel to the original line.
We can quickly confirm that the two lines are parallel to each other by calculating the slope of the second line. We set and . This allows us to calculate
Given that the two lines have the same slope and have different -intercepts, they are distinct and parallel to each other and therefore will never meet. Given that the lines are parallel, they make the same angle with the horizontal axis. We can then use the previously calculated result to state that the angle between the second straight line and this axis is approximately .
For the final stage, we will consider a third pair of points: and . These are plotted on the diagram below, along with the straight line that joins these two points. The new straight line appears to be perpendicular to the two parallel lines.
We can test this speculation by calculating the slope of the new straight line. We set and and then calculate the slope as follows:
Let the slope of the parallel lines be and this new slope be . We find that
This confirms that the new line is perpendicular to the two parallel lines. To calculate the angle between this new straight line and the horizontal axis, we simply subtract from the angle formed between the parallel lines and the horizontal axis. This gives the result . Equally, we could have calculated the angle by using the relationship . This would have given the same result.
In the next example, we will practice our understanding of how the slope of one straight line can be used to find the slope of another straight line that is perpendicular to the first.
Example 2: Finding the Slope of a Straight Line When Given the Slope of a Perpendicular Line
If and the slope of , find the slope of .
Answer
By saying that , we are saying that line is perpendicular to the line . If we say that these lines respectively have the slopes and , then we recall that they must be in the relationship , given that neither of the two lines are either horizontal or vertical. Since we already know that , we can find the second slope as
Note in the previous example that we were not given enough information to fully understand either of the straight lines. However, once we were told the slope of the first line, we were able to calculate the slope of the second line because we were told that it was perpendicular. Although we were not asked to calculate it, we could have found that the angle that the first line made with the horizontal axis was approximately . The angle made between the perpendicular line and the horizontal axis would have been .
In the next set of examples, we will explore further how the slopes of straight lines can be used to determine whether they are parallel or perpendicular. The following three examples do not contain any reference to the angle made between the featured straight lines and the horizontal axis, although this can of course be calculated as a consequence of having calculated the slopes of the lines.
Example 3: Linking the Slope of a Straight Line with the Angle the Line Makes with the Positive Direction of the 𝑥-Axis
Consider a line with slope 1 and another line that makes an angle of with the -axis in a counterclockwise direction. Which of the following is correct about the two lines?
- The two lines are perpendicular.
- The two lines are parallel.
- They are neither parallel nor perpendicular.
Answer
We start by recalling that the slope of a straight line is equal to the tangent of the positive angle made between the straight line and the positive direction of the -axis. If a line makes an angle of with the -axis in a counterclockwise direction, then its slope is
Therefore, both lines have the same slope, which means that they are parallel. Option B is the right answer.
Example 4: Finding the Slope of a Straight Line in a Parallelogram Using the Relationship between the Slopes of Parallel Lines
If is a parallelogram, where and , find the slope of .
Answer
We recall that, in a parallelogram, the opposite sides are distinct and parallel, and this shape is written where the vertices are connected in order of the letters given. In other words, the point connects to the point , and then the point , and then the point , and then back to point in turn, hence, giving the outline of a parallelogram. This means that is parallel to , and hence, they have the same slope.
To demonstrate this point, the diagram below features a plot of the points and as well as the line connecting them. The black side is a finite segment of the line , which is represented in red. The black sides represent one of the sides of any parallelogram that passes through these two points.
To create a parallelogram, we can select any two points and such that a new line is parallel to the original line . We may pick any values of or that achieve this, providing that and are not part of the same straight line. In the diagram below, we have picked two arbitrary values of and that achieve this, with the line in red. The finite segment of this line that has been shown is another side of the parallelogram. The remaining lines and have also been plotted in blue, thus meaning that the parallelogram can be formed by creating the remaining sides as shown in black.
It is important to reiterate that the values of and that we have taken are completely arbitrary. What matters is that the lines through these points are parallel to the original line, hence, allowing the parallelogram to be drawn. We can now calculate the slope of in the normal way. The slope of a straight line through two points and is found from the formula
By substituting and into this formula, we find that
Given that is parallel to , we know that the slope of this line is also .
Example 5: Comparing the Slopes of Two Lines to Determine If They Are Parallel or Perpendicular
Let be the line through the points and and the line through and . Which of the following is true about the lines and ?
- They are parallel.
- They are perpendicular.
- They are intersecting but not perpendicular.
Answer
We should recall that if two distinct straight lines have slopes and , then this information can be used to determine how the lines relate to each other. If , then the two lines are parallel and will never intersect each other. If , then the two lines will be perpendicular and will intersect each other only once. If neither situation occurs, then the two lines will be neither parallel nor perpendicular and hence will intersect each other exactly once.
We have been given enough information to plot a useful diagram, which is shown below. The two points and are shown in blue and are connected by the blue straight line. The two points and are shown in red, as is the line joining them.
From the diagram alone, it appears that the two lines are at right angles (hence, meaning that they are perpendicular). However, it could quite easily be the case that the two lines are nearly perpendicular, but that this is not possible to distinguish from the diagram. In fact, generally, it is neither wise nor possible to assume that two lines are either parallel or perpendicular given only a sketch. We must now calculate the slope of each line given the available information, which will allow us to check precisely whether they truly are perpendicular.
We will first calculate the slope of the blue line using the points and . The slope is then calculated as follows:
The slope is negative and relatively steep, which is consistent with the diagram. The slope of the second line can be calculated using the points and . Then, the slope is found as follows:
We can check that , which confirms that the two lines are perpendicular.
In the previous three examples, we were not asked to find the angle between the horizontal axis and any of the given straight lines. There is no reason that we could not have done this anyway, given the general results that we derived earlier. In the following example, we will see this concept one final time in the explainer, before we progress to another series of questions that involve solving algebraic equations arising from questions around slopes.
Example 6: Finding the Angle the Perpendicular to a Given Straight Line Makes with the Positive 𝑥-Axis
Let be the line on points and , and the perpendicular to that passes through the origin . What is the measure of the positive angle that makes with the positive -axis? Give your answer to the nearest second.
Answer
To find the positive angle that makes with the positive -axis, we will use
- the fact that and are perpendicular,
- the relationship between the slope of a straight line and the positive angle the line makes with the -axis.
For the first point, recall that perpendicular lines have slopes whose product equals and make angles with the positive -axis whose difference is . We can use either of these facts to find the solution, which leads to two methods.
The First Method
We want to determine the slope of line in order to find the slope of line , and then the angle that makes with the positive -axis. As passes through the points and , its slope is given by
As and are perpendicular, the product of their slopes equals . Thus, we have
Multiplying both sides by gives
Now that we have the slope of , we use the relationship between the slope of a line and the positive angle it makes with the positive -axis: where is the slope and is the angle, which gives
The Second Method
In this method, we start, like in the previous method, by finding the slope of , but then we use it to determine the angle that makes with the positive -axis and then use this angle to find the positive angle makes with the positive -axis.
We found above that the slope of is . Now, we can use the relationship between the slope of a line and the positive angle it makes with the positive -axis: where is the slope and is the angle, which gives
To find the positive angle, , that makes with the positive -axis, we need to add to this angle. We find
This angle is an obtuse angle. This means that line , which is perpendicular to , makes an acute angle, , with the positive -axis. It is thus found by subtracting from the approximate value of :
Example 7: Finding an Unknown Coordinate Using the Relationship between the Slopes of Perpendicular Lines
If the line that passes through the points and is perpendicular to the line passing through the points and , what is the value of ?
Answer
We recall that we can determine whether two straight lines are perpendicular by examining their slopes. Suppose that there are two straight lines that have slopes and . These lines will be perpendicular if they satisfy the equation . This means that if we know the slope of one straight line as , then we can determine whether another straight line having slope is perpendicular to the first line.
We will first find the slope of the line that joints the point to the point . To do this, we define and . Then, the slope of this line is found as follows:
We are told that the line joining to is perpendicular to the line that joints to . Suppose that the slope of this line is . Then, since we are told that the two lines are perpendicular, we know that , which means that .
We now need to find such that the slope of the line joining to is equal to . We take the coordinates for and as given in the question, labeling them as and . We must therefore find , which solves the following:
We can solve this equation by first cross multiplying both the denominator terms, giving
Solving this equation for gives the final result , meaning that we have the point .
We can check that this result is correct by plotting all four points and checking whether the two lines appear to be perpendicular. In the diagram below, the points and are plotted in blue, with the points and being plotted in red. The two lines do appear to be perpendicular.
In summary, we have found that the answer is .
Example 8: Finding an Unknown Coordinate Using the Relationship between the Slopes of Parallel Lines
If the line passing through points and is parallel to the line passing through points and , what is the value of ?
Answer
We recall that two distinct parallel lines will never meet, and this will be the case if they have the same slopes but different -intercepts. We label the slope of the line joining and as , with the slope of the line joining and being labeled as . We are told that the two lines are parallel, which means that the slopes are equal and hence, . We can calculate the slope of each by substituting in the given values into the formula for the slope. This gives and
Since the lines are parallel, we want ; hence, we must solve
Multiplying through by both denominators gives
We expand the left-hand side of the equation, giving
Now, subtracting from both sides of the equation, we obtain
Solving for gives the final result . Therefore, the previous unknown points can now be stated fully, giving and .
We can check that this result is correct by plotting all four points. In the graph below, the points and are plotted in blue, with the points and being plotted in red. The two lines through these do appear to be parallel.
In summary, we have found that .
Example 9: Finding an Unknown Coordinate of the Vertex of a Trapezoid Using the Relationship between the Slopes of Parallel Lines
Given that is a trapezoid, where , and the coordinates of points , , , and are , , , and , respectively, find the coordinates of point .
Answer
By saying that , we are saying that the line joining and must be parallel to the line joining and . If the slope of the first line is labeled as and the slope of the second line is labeled as , then we require that for the two lines to be parallel.
We begin by calculating the known slopes given the information currently available. This is completed as follows: and
We can then solve for the unknown value by equating the two expressions above, as follows:
To solve for , we first multiply both sides of the equation by , which will have the effect of removing the denominator term from the right-hand side, as shown:
We now rearrange the equation, leaving
This gives the final result . The previously unknown point can now be written in full as .
We now have the coordinates for all four points of the trapezoid, which we have plotted below. We can see that the side does appear to be parallel to the line . The final answer is .
Key Points
- The slope of a straight line passing through the points and is given by .
- The angle is measured from the horizontal axis,
rotating counterclockwise until meeting the straight line. For
being the slope of a straight line, the following results
hold:
- For , the angle between this straight line and the horizontal axis is expressed as .
- For , the angle between this straight line and the horizontal axis is expressed as .
- For vertical lines, .
- Consider two straight lines with slopes and
and the -intercepts
and :
- If and , then the two lines are distinct and parallel. This means that the lines never meet and that they make the same angle with the horizontal axis.
- If and , then the two lines are coincident (or identical).
- If , then the two lines are perpendicular.