Sub topic 6
Perpendicular Slopes Are Negative Reciprocals
Assume you can plot points, calculate slope, use fractions, and recognize a right angle. In this chapter, you will connect the geometric idea of perpendicular lines to an algebraic test involving slopes.
Two lines are perpendicular when they meet at a right angle, or an angle of \(90^\circ\). If two nonvertical lines have slopes \(m1\) and \(m2\), they are perpendicular exactly when
\[ m1m2=-1 \]
Therefore, the slopes are negative reciprocals. To find the perpendicular slope, reverse the fraction and change its sign.
| Given slope | Perpendicular slope |
|---|---|
| \(2\) | \(-\frac12\) |
| \(-\frac34\) | \(\frac43\) |
| \(\frac15\) | \(-5\) |
Why the product is \(-1\)
A line with slope \(m\) rises \(m\) units for every 1 unit it moves right. A direction vector for that line is \((1,m)\).
Suppose two lines have direction vectors \((1,m1)\) and \((1,m2)\). Their dot product is
\[ (1)(1)+m1m2=1+m1m2 \]
Perpendicular direction vectors have a dot product of zero. Thus,
\[ 1+m1m2=0 \]
which gives
\[ m1m2=-1 \]
This explains both parts of the rule:
- Reciprocal: the fraction is turned upside down.
- Negative: the sign changes.
For example, the negative reciprocal of \(\frac25\) is \(-\frac52\).
Checking whether two lines are perpendicular
First find each slope if the equations do not already show them. Then multiply the slopes.
Consider the lines
\[ y=3x+2 \]
and
\[ y=-\frac13x+7 \]
Their slopes are \(3\) and \(-\frac13\). Their product is
\[ 3\left(-\frac13\right)=-1 \]
Therefore, the lines are perpendicular.
If two slopes have a product other than \(-1\), the lines are not perpendicular. For example, slopes \(2\) and \(-2\) have opposite signs, but
\[ 2(-2)=-4 \]
They are not perpendicular. Opposite signs alone are not enough.
Finding a perpendicular slope from two points
Use the slope formula
\[ m=\frac{y2-y1}{x2-x1} \]
Suppose a line passes through \((1,4)\) and \((5,6)\). Its slope is
\[ m=\frac{6-4}{5-1}=\frac24=\frac12 \]
The perpendicular slope is the negative reciprocal:
\[ m_{\perp}=-2 \]
You can verify the result because
\[ \frac12(-2)=-1 \]
A small program can perform this check exactly with fractions.
from fractions import Fraction
def slope(p, q):
x1, y1 = p
x2, y2 = q
if x1 == x2:
return None # vertical line
return Fraction(y2 - y1, x2 - x1)
def perpendicular(m):
if m == 0:
return None # perpendicular line is vertical
return -1 / m
m = slope((1, 4), (5, 6))
print(m) # 1/2
print(perpendicular(m)) # -2Horizontal and vertical lines
The negative-reciprocal rule works directly only when both slopes are nonzero and finite.
- A horizontal line has slope \(0\).
- A vertical line has an undefined slope.
- Horizontal and vertical lines are perpendicular.
So the perpendicular to \(y=4\) is a vertical line. The perpendicular to \(x=-2\) is a horizontal line. You cannot write the vertical line's slope as a fraction, so handle this case separately.
Exercise
Are lines with slopes -5/2 and 2/5 perpendicular?
Show answer
Yes. Their product is (-5/2)(2/5) = -1, so the slopes are negative reciprocals.