Parallel and Perpendicular Lines

Learning goals

  • Match slopes for parallel lines with different intercepts
  • Take the negative reciprocal for a perpendicular slope
  • Treat vertical and horizontal lines as the exception to the product rule
  • Classify two lines by comparing their slopes
  • Write the required line through a point with point-slope form

Parallel lines: equal slopes

If two nonvertical lines have the same slope, their heights change at the same rate. Their vertical gap stays fixed as you move across. Different slopes make that gap change: one line rises 22 units per unit across, for example, while the other rises 33. The second line gains 11 unit on the first for each unit to the right. Extending the lines in both directions lets that difference reach zero, where the lines cross. Equal slopes keep the gap fixed: a nonzero gap means the lines never meet, while a zero gap means the two equations describe the same line.

Two parallel lines with slope one halfThe lines y = (1/2)x + 2 and y = (1/2)x - 1 drawn on a grid, with two vertical markers showing the gap between them is the same at two different x-values.xy033y = (1/2)x + 2y = (1/2)x - 1
Two parallel lines. Both have slope 1/2, so they climb at the same rate, and the vertical gap between them stays a constant 3 units at every x. Equal slope with different y-intercepts is the parallel case.

Why equal slopes mean parallel#

Try it first on the two lines drawn above, y=12x+2y = \tfrac{1}{2}x + 2 and y=12x−1y = \tfrac{1}{2}x - 1. A meeting point is an xx where both right-hand sides agree, so set them equal:

12x+2=12x−1.\tfrac{1}{2}x + 2 = \tfrac{1}{2}x - 1.

Subtract 12x\tfrac{1}{2}x from both sides:

2=−1.2 = -1.

That is false for every xx, so no meeting point exists: the lines never cross, exactly as the picture shows. Now compare a pair with different slopes, y=12x+2y = \tfrac{1}{2}x + 2 and y=2x−1y = 2x - 1. Setting those equal gives 12x+2=2x−1\tfrac{1}{2}x + 2 = 2x - 1, so 3=32x3 = \tfrac{3}{2}x and x=2x = 2: one definite crossing. Last, compare the first line with itself, y=12x+2y = \tfrac{1}{2}x + 2 against y=12x+2y = \tfrac{1}{2}x + 2. Setting those equal gives 2=22 = 2, true for every xx, so every point is shared: the equations describe one line. The general calculation below has the same three outcomes.

Take two nonvertical lines and write each in slope-intercept form, y=m1x+b1y = m_1 x + b_1 and y=m2x+b2y = m_2 x + b_2. The lines meet at any point where their yy-values agree, so set the right-hand sides equal and see which xx can satisfy both:

m1x+b1=m2x+b2.m_1 x + b_1 = m_2 x + b_2.

Gather the xx-terms on one side:

(m1−m2) x=b2−b1.(m_1 - m_2)\,x = b_2 - b_1.

What happens next depends on whether the slopes are equal. Suppose first that they differ, so m1≠m2m_1 \neq m_2. Then m1−m2m_1 - m_2 is not zero, and you may divide by it:

x=b2−b1m1−m2.x = \frac{b_2 - b_1}{m_1 - m_2}.

That is one definite number, a single xx where the lines cross. So two lines with different slopes cross at exactly one point, and they are not parallel.

Now suppose the slopes are equal, m1=m2m_1 = m_2. Then m1−m2=0m_1 - m_2 = 0, and the equation collapses to 0=b2−b10 = b_2 - b_1. If the intercepts differ, b1≠b2b_1 \neq b_2, this says 00 equals a nonzero number, which is impossible: no xx works, the lines share no point, and they are parallel. If instead the intercepts are also equal, b1=b2b_1 = b_2, then every xx works, and the two equations describe the same line.

So among nonvertical lines, equal slopes with different intercepts is precisely the parallel case, and it is the only way two such lines can fail to cross.

For vertical lines, compare their equations directly. The lines x=cx=c with different values of cc never meet, so they are parallel: a point cannot have both x=3x=3 and x=5x=5, for example. Two copies of x=3x=3 describe the same line, not a parallel pair. There is no slope number to compare in either case.

Worked example 1 Decide whether two lines are parallel

Are the lines y=−3x+5y = -3x + 5 and 6x+2y=16x + 2y = 1 parallel? To decide, compare their slopes. The first line is already in slope-intercept form, and its slope is m1=−3m_1 = -3.

The second line is in standard form, so solve it for yy to expose its slope. Subtract 6x6x from both sides, then divide every term by 22:

2y=−6x+1,y=−3x+12.2y = -6x + 1, \qquad y = -3x + \tfrac{1}{2}.

Its slope is m2=−3m_2 = -3 as well. The two slopes are equal, −3=−3-3 = -3, and the intercepts differ, 5≠125 \neq \tfrac{1}{2}, so the lines are parallel and not the same line.

Check your understanding

Are the lines y=25x+1y = \tfrac{2}{5}x + 1 and 2x−5y=202x - 5y = 20 parallel, perpendicular, or neither?

Answer choices

Perpendicular lines: negative reciprocal slopes

A line of slope 22 is perpendicular to a line of slope −12-\tfrac12. A line of slope −34-\tfrac34 is perpendicular to a line of slope 43\tfrac43. In each pair, flipping one slope’s fraction and changing its sign gives the other. These numbers are negative reciprocals.

Two nonvertical lines with slopes m1m_1 and m2m_2 are perpendicular exactly when

m1m2=−1.m_1m_2=-1.

Both slopes must then be nonzero, and you can also write m2=−1/m1m_2=-1/m_1. A horizontal line’s perpendicular partner is vertical, so two nonvertical perpendicular lines cannot be horizontal. The reason comes from turning a slope triangle through a right angle.

Rotating a slope triangle a quarter turn to get the perpendicular slopeLine L1 with a slope triangle of run 2 and rise 1, rotated ninety degrees about the point P to produce the perpendicular line L2, whose triangle has a rise of 2 and a run of 1 to the left.90°Prun = brise = arise = brun = -aL1: slope a/bL2: slope -b/a
Turning a slope triangle a quarter turn. The line L1 has slope a/b, drawn here with run b = 2 and rise a = 1. Rotating its triangle ninety degrees about P swaps the legs: the run of 2 becomes a rise of 2, and the rise of 1 becomes a run of 1 to the left. The turned line L2 has slope b over negative a, that is negative b/a, and the two lines meet at a right angle.

Why perpendicular slopes are negative reciprocals#

The triangle above has run 22 and rise 11, giving slope 12\tfrac12. Turn it 9090 degrees counterclockwise about PP. The step right 22 turns into a step up 22; the step up 11 turns into a step left 11. Thus the new rise is 22 and the new run is −1-1:

m2=2−1=−2,12(−2)=−1.m_2=\frac{2}{-1}=-2,\qquad \frac12(-2)=-1.

If the original rise is −1-1 instead, the downward step turns to the right. The rotated triangle has run 11 and rise 22, giving slope 22, and again −12(2)=−1-\tfrac12(2)=-1.

Now the general case. Take a line L1L_1 that is neither horizontal nor vertical. Write its slope as m1=a/bm_1=a/b, using a positive run bb and matching nonzero rise aa. The sign of aa tells whether the line rises or falls to the right.

Choose a point PP on the line and turn the line and its slope triangle 9090 degrees counterclockwise about PP. The turned line L2L_2 passes through PP at a right angle to L1L_1. This covers any line perpendicular to L1L_1: choose their meeting point as PP, and the quarter turn gives that perpendicular line, since there is only one perpendicular through PP.

Track the slope triangle through the turn. A quarter turn counterclockwise sends a step ”bb to the right” to a step ”bb up”. The same turn sends the step ”aa up or down” to a horizontal step of −a-a: an upward step (aa positive) turns to a step left, and a downward step (aa negative) turns to a step right. Starting again at PP, the rotated triangle has run −a-a and rise bb, which makes the slope of L2L_2

m2=riserun=b−a=−ba.m_2 = \frac{\text{rise}}{\text{run}} = \frac{b}{-a} = -\frac{b}{a}.

Compare that with m1=abm_1 = \dfrac{a}{b}: the fraction has been flipped and its sign changed, so m2m_2 is the negative reciprocal of m1m_1. Multiplying the two slopes confirms it directly:

m1⋅m2=ab⋅(−ba)=−abab=−1.m_1 \cdot m_2 = \frac{a}{b} \cdot \left(-\frac{b}{a}\right) = -\frac{ab}{ab} = -1.

For the reverse direction, suppose two nonvertical lines have slopes whose product is −1-1. Their slopes are nonzero and have opposite signs, so they differ. The parallel-line proof above shows they meet at one point PP. Rotate the first line 9090 degrees about PP. By the calculation above, the rotated line has the second line’s slope. It also passes through PP, so it is the second line itself: a point and a slope fix one line. Their angle is therefore a right angle.

With this rule you can quickly find a perpendicular slope and test whether two given lines are perpendicular.

Worked example 2 Find a perpendicular slope, then test a pair of lines

First, find the slope of any line perpendicular to 2x−3y=62x - 3y = 6. Solve for yy to read its slope. Subtract 2x2x and divide by −3-3:

−3y=−2x+6,y=23x−2,-3y = -2x + 6, \qquad y = \tfrac{2}{3}x - 2,

so this line has slope 23\tfrac{2}{3}. A perpendicular line has the negative reciprocal slope: flip 23\tfrac{2}{3} to 32\tfrac{3}{2} and change the sign,

m⊥=−32.m_{\perp} = -\frac{3}{2}.

Second, are y=23x+1y = \tfrac{2}{3}x + 1 and y=−32x+4y = -\tfrac{3}{2}x + 4 perpendicular? Multiply their slopes and check for −1-1:

23⋅(−32)=−66=−1.\frac{2}{3} \cdot \left(-\frac{3}{2}\right) = -\frac{6}{6} = -1.

The product is −1-1, so yes, the two lines meet at a right angle.

Two perpendicular lines with slopes 2 and negative one halfThe lines y = 2x - 3 and y = -(1/2)x + 2 meeting at the point (2, 1), with a small right-angle square at the intersection.xy0(2, 1)y = 2x - 3y = -(1/2)x + 2
Two perpendicular lines. One has slope 2 and the other has slope negative one half, and 2 times negative one half is negative 1. They cross at (2, 1), and the small square marks the right angle there. Drawing the axes to the same scale is what makes the right angle look square.

Check your understanding

What is the slope of any line perpendicular to the line through the points (1,2)(1, 2) and (5,4)(5, 4)?

Answer choices

The horizontal and vertical case

A horizontal line and a vertical line meet at a right angle, just as the two coordinate axes do. Their slopes are 00 and undefined, so the product test cannot be used: there is no second slope number to multiply. Applying the negative-reciprocal rule to slope 00 would give −1/0-1/0, which has no value. Instead, use the picture: a horizontal line’s perpendicular partner is vertical.

Testing whether two lines are parallel, perpendicular, or neither

Check for a vertical line first, since the slope tests below need a real slope on both sides. If either line is vertical: two vertical lines are parallel when their equations differ and the same line when they match, a vertical line and a horizontal line are perpendicular, and a vertical line paired with any other slanted line is neither.

Once both lines have a real slope, the rest of the routine is short. Find the slope of each line, putting each equation into slope-intercept form or applying the slope formula to two points if that is what you are given. Then compare the two slopes: if they are equal, the lines are parallel (or the same line, when the intercepts match too). If their product is −1-1, the lines are perpendicular. If neither test holds, the lines are neither, crossing at some angle that is not a right angle.

Worked example 3 Classify three pairs of lines

Classify each pair as parallel, perpendicular, or neither.

Pair A: y=4x−1y = 4x - 1 and y=4x+6y = 4x + 6. Both slopes are 44, and the intercepts differ, so the lines are parallel.

Pair B: y=32x+5y = \tfrac{3}{2}x + 5 and 2x+3y=92x + 3y = 9. Convert the second: 3y=−2x+93y = -2x + 9, so y=−23x+3y = -\tfrac{2}{3}x + 3. The slopes are 32\tfrac{3}{2} and −23-\tfrac{2}{3}, and their product is

32⋅(−23)=−1,\frac{3}{2} \cdot \left(-\frac{2}{3}\right) = -1,

so the lines are perpendicular.

Pair C: y=2x+1y = 2x + 1 and y=−2x+1y = -2x + 1. The slopes are 22 and −2-2. They are not equal, so the lines are not parallel, and their product is 2⋅(−2)=−42 \cdot (-2) = -4, not −1-1, so they are not perpendicular either. This pair is neither. The slopes look related, but a sign flip alone is not the same as a negative reciprocal, which also flips the fraction.

Check your understanding

The lines 3x+4y=83x + 4y = 8 and 4x−3y=124x - 3y = 12 are which of the following?

Answer choices

The figure starts with Pair C: y=2x+1y=2x+1 and y=−2x+1y=-2x+1. Their slopes multiply to −4-4, so the crossing is not a right angle. Try these changes in order:

  1. Make line B’s slope −12-\tfrac12 by setting Rise B to −1-1 and Run B to 22. The lines are now perpendicular; the readout confirms the right angle.
  2. Set Crosses B to −2-2, then match line A by setting Rise B to 22 and Run B to 11. Equal slopes and different intercepts make the lines parallel, so the crossing dot disappears.
  3. Keep those equal slopes and return Crosses B to 11. Now both equations describe the same line. There is still no single crossing dot, but the readout explains that every point is shared.

Parallel, perpendicular, or neither?

y = 2x + 1. y = -2x + 1. The slopes 2 and -2 are different, so they cross exactly once. They cross at (0, 1). A coordinate plane with two straight lines drawn across it, and a dot marking where they cross when they do. Use the controls below the figure to change the rise, the run or the crossing point of either line. -6 -4 -2 2 4 6 -6 -4 -2 2 4 6
Rise A Run A Crosses A Rise B Run B Crosses B

y = 2x + 1. y = -2x + 1. The slopes 2 and -2 are different, so they cross exactly once. They cross at (0, 1).

Two lines on one coordinate plane, one solid and one dashed, each with its own rise, run and y-intercept. A dot marks where they cross at a single point. It is absent for parallel lines, which never meet, and also for two equations that turn out to be the same line, which meet everywhere and so have no single crossing point to mark.

Writing equations of parallel and perpendicular lines

To construct a parallel line through a point outside a given nonvertical line, keep its slope. To construct a perpendicular line when the given slope is nonzero, take the negative reciprocal. Then substitute the new slope and the given point into point-slope form. A perpendicular line may pass through a point either on or off the original line.

When the given line is vertical or horizontal instead, skip point-slope form and use what you already know about writing x=cx = c and y=cy = c equations, together with this lesson’s exception: a vertical line’s parallel partner is vertical, and its perpendicular partner is horizontal. Through the point (5,1)(5, 1), the line parallel to x=−2x = -2 is x=5x = 5 (still vertical, now through x=5x = 5), and the line perpendicular to x=−2x = -2 is y=1y = 1 (horizontal, at the point’s height).

Check your understanding

What is the equation of the line through (4,−3)(4, -3) that is perpendicular to y=6y = 6?

Answer choices

Worked example 4 A line through a point, parallel to a given line

Write the equation of the line through (2,−1)(2, -1) that is parallel to y=3x+4y = 3x + 4, in slope-intercept form.

Parallel means the same slope, and the given line has slope 33, so the new line also has slope 33. Now use point-slope form with the point (2,−1)(2, -1):

y−(−1)=3(x−2),y+1=3x−6.y - (-1) = 3(x - 2), \qquad y + 1 = 3x - 6.

Subtract 11 from both sides to reach slope-intercept form:

y=3x−7.y = 3x - 7.

As a check, the slope is 33 as required, and at x=2x = 2 the equation gives y=6−7=−1y = 6 - 7 = -1, so the line passes through (2,−1)(2, -1).

Worked example 5 A line through a point, perpendicular to a given line

Write the equation of the line through (4,1)(4, 1) that is perpendicular to y=2x−5y = 2x - 5, in slope-intercept form.

The given line has slope 22, so a perpendicular line has the negative reciprocal slope: flip 22 to 12\tfrac{1}{2} and change the sign, giving m=−12m = -\tfrac{1}{2}. Use point-slope form with the point (4,1)(4, 1):

y−1=−12(x−4),y−1=−12x+2.y - 1 = -\tfrac{1}{2}(x - 4), \qquad y - 1 = -\tfrac{1}{2}x + 2.

Add 11 to both sides:

y=−12x+3.y = -\tfrac{1}{2}x + 3.

The slope −12-\tfrac{1}{2} is the negative reciprocal of 22, and at x=4x = 4 the equation gives y=−2+3=1y = -2 + 3 = 1, so the line runs through (4,1)(4, 1) as required.

Worked example 6 Perpendicular to a line given in standard form

Write the equation of the line through (−3,2)(-3, 2) that is perpendicular to 3x+y=73x + y = 7.

First get the slope of the given line by solving for yy: y=−3x+7y = -3x + 7, so its slope is −3-3. The perpendicular slope is the negative reciprocal of −3-3: flip to −13-\tfrac{1}{3} and change the sign, giving m=13m = \tfrac{1}{3}. Now use point-slope form with (−3,2)(-3, 2):

y−2=13(x−(−3))=13(x+3).y - 2 = \tfrac{1}{3}\bigl(x - (-3)\bigr) = \tfrac{1}{3}(x + 3).

Distribute and add 22:

y−2=13x+1,y=13x+3.y - 2 = \tfrac{1}{3}x + 1, \qquad y = \tfrac{1}{3}x + 3.

The slope 13\tfrac{1}{3} times the original −3-3 gives −1-1, confirming perpendicularity, and the line passes through (−3,2)(-3, 2) since 13(−3)+3=2\tfrac{1}{3}(-3) + 3 = 2.

Check your understanding

Which is the equation of the line through (2,7)(2, 7) that is perpendicular to y=12x−8y = \tfrac{1}{2}x - 8?

Answer choices

Common mistakes

Practice

Multiple Choice Questions (MCQ)

Progressively harder sets of questions. Each opens on its own page.

Core practice

Practice problems at the level of the course, to be worked out on paper. Hints one at a time, then the answer or the full worked solution, with your progress kept in this browser.

Core practice Work it out on paper 10 problems Start →
More practice (optional)

Extra sets, as hard as the Challenge set. Each one opens on its own page.

More resources (optional)
A bit of history (optional)

How can a builder check whether a wall stands upright? One simple tool is a weight hanging from a cord. Let the weight stop swinging, and the taut cord shows the vertical direction. Comparing the wall with that cord reveals a lean.

The Latin word perpendiculum meant a plumb line. It came from perpendere, built on pendere, meaning “to weigh, to hang.” Through Latin and French, it gave English the word perpendicular. The name still carries the image of a hanging cord, but perpendicular lines in geometry can point in any direction, as long as they meet at a right angle. The Paris Observatory’s etymological dictionary traces this history.

Parallel followed a different language route. Its Greek ancestor came from words meaning “beside one another,” and reached English through French and Latin. Etymonline records the origin of parallel.

Your progress

See all your progress →