Given a line y = mx + b, find the slopes of parallel and perpendicular lines. Parallel lines have the same slope; perpendicular lines have slopes whose product equals -1. The perpendicular slope is computed as -1/m.

Example

Use same slope for parallel lines and negative reciprocal for perpendicular lines. The negative-reciprocal rule assumes a nonzero slope; a horizontal line and a vertical line are also perpendicular, but a vertical line has undefined slope and cannot be written this way.

highlighted = computed this step

Step 1 — Set up

Set up the expression.

y=2x+1y= 2x + 1
Given line y = 2x + 1 has slope m = 2.same tilt / crossing lineliney = 2x + 1 m = 2parallel: same slopeflip slope, then make it negativeperpendicular slopecheck product

Step 2 — Parallel slope

Parallel lines keep the same slope, 2.

m=2m_{\parallel}= \hl{2}
Parallel lines use the same slope: m_parallel = 2.same tilt / crossing lineliney = 2x + 1 m = 2m_parallel = 2 / same slopeflip slope, then make it negativeperpendicular slopecheck product

Step 3 — Negative reciprocal

Use 1/2, with a negative sign.

m=12m_{\perp}=-\frac{ 1 }{ \hl{2} }
Perpendicular slope uses the negative reciprocal.same tilt / crossing lineliney = 2x + 1 m = 2m_parallel = 2 / same slopeflip 2 -> 1/2; negative reciprocalperpendicular slopecheck product

Step 4 — Perpendicular slope

The negative reciprocal is -1/2.

m=12m_{\perp}= \hlmath{\frac{-1}{2}}
Perpendicular slope: m_perp = -1/2.same tilt / crossing lineliney = 2x + 1 m = 2m_parallel = 2 / same slopeflip 2 -> 1/2; negative reciprocalm_perp = -1/2check product

Step 5 — Check

Check perpendicular slopes: 2 x -1/2 = -1.

2×12=-12 \times \frac{-1}{2} = \hl{-1}
Check: 2 * -1/2 = -1.same tilt / crossing lineliney = 2x + 1 m = 2m_parallel = 2 / same slopeflip 2 -> 1/2; negative reciprocalm_perp = -1/22 * -1/2 = -1
parallel-perpendicular Parallel slope = m (same direction). Perpendicular slope = -1/m (negative reciprocal). Verify: m · (-1/m) = -1. For m = 2, perpendicular slope is -1/2.