ironfern @ docs ~/geometry/grade-9/coordinates/slope-line-equation $

Slope Form and Two-Point Equation

The most useful forms for writing the equation of a line are those that make the geometric meaning of the parameters visible — the slope tells you how steeply the line rises, and specifying two points pins down the line uniquely.

Slope and Angle of Inclination

📐Definition — Slope of a Line

The slope (or gradient) of a non-vertical line \ell is the number

k=tgαk = \operatorname{tg}\alpha

where α\alpha is the angle of inclination — the angle measured counterclockwise from the positive xx-axis to the line, with 0°α<180°0° \leq \alpha < 180° and α90°\alpha \neq 90°.

Equivalently, for any two distinct points (x1,y1)(x_1, y_1) and (x2,y2)(x_2, y_2) on \ell with x1x2x_1 \neq x_2:

k=y2y1x2x1("rise over run")k = \frac{y_2 - y_1}{x_2 - x_1} \quad \text{("rise over run")}

Sign of the slope:

  • k>0k > 0: the line rises from left to right (0°<α<90°0° < \alpha < 90°)
  • k<0k < 0: the line falls from left to right (90°<α<180°90° < \alpha < 180°)
  • k=0k = 0: the line is horizontal (α=0°\alpha = 0°)
  • Vertical lines have no slope (undefined, α=90°\alpha = 90°)

Slope-Intercept Form

Theorem — Slope-Intercept Form (Theorem 12.1)

Every non-vertical line with slope kk and yy-intercept bb (the point where it crosses the yy-axis) has equation:

y=kx+b\boxed{y = kx + b}

Conversely, every equation of this form represents a non-vertical line with slope kk and yy-intercept bb.

Proof. A line with slope kk passing through (0,b)(0, b): for any point (x,y)(x, y) on it (with x0x \neq 0), the slope condition gives ybx0=k\frac{y - b}{x - 0} = k, so yb=kxy - b = kx, i.e., y=kx+by = kx + b. When x=0x = 0: y=by = b \checkmark. \blacktriangleleft

Point-Slope Form

If a line has slope kk and passes through a known point (x0,y0)(x_0, y_0), then any other point (x,y)(x, y) on the line satisfies:

yy0=k(xx0)\boxed{y - y_0 = k(x - x_0)}

This follows immediately from the definition of slope. Expanding gives y=kx+(y0kx0)y = kx + (y_0 - kx_0), i.e., slope-intercept form with b=y0kx0b = y_0 - kx_0.

Two-Point Equation

Theorem — Two-Point Equation (Theorem 12.2)

The line through two distinct points A(x1,y1)A(x_1, y_1) and B(x2,y2)B(x_2, y_2) with x1x2x_1 \neq x_2 has equation:

yy1y2y1=xx1x2x1\boxed{\frac{y - y_1}{y_2 - y_1} = \frac{x - x_1}{x_2 - x_1}}

Proof. A point P(x,y)P(x, y) lies on line ABAB if and only if AP\overrightarrow{AP} and AB\overrightarrow{AB} are collinear (parallel), i.e., their slopes are equal:

yy1xx1=y2y1x2x1\frac{y - y_1}{x - x_1} = \frac{y_2 - y_1}{x_2 - x_1}

Cross-multiplying gives the two-point equation. \blacktriangleleft

Note: If x1=x2x_1 = x_2 (vertical line), the equation is simply x=x1x = x_1.

Parallel and Perpendicular Lines

Theorem — Parallelism and Perpendicularity (Theorem 12.3)

Let 1\ell_1 and 2\ell_2 be two non-vertical lines with slopes k1k_1 and k2k_2. Then:

  • 12\ell_1 \parallel \ell_2 (parallel, distinct)     k1=k2\iff k_1 = k_2 (and the lines have different yy-intercepts)
  • 12\ell_1 \perp \ell_2 (perpendicular)     k1k2=1\iff k_1 \cdot k_2 = -1, equivalently k2=1k1k_2 = -\dfrac{1}{k_1}

Proof of perpendicularity. If 1\ell_1 has inclination angle α1\alpha_1, then 21\ell_2 \perp \ell_1 means α2=α1+90°\alpha_2 = \alpha_1 + 90° (or α190°\alpha_1 - 90°). Using the tangent of a sum:

k2=tg(α1+90°)=cotα1=1tgα1=1k1k_2 = \operatorname{tg}(\alpha_1 + 90°) = -\cot\alpha_1 = -\frac{1}{\operatorname{tg}\alpha_1} = -\frac{1}{k_1} \qquad \blacktriangleleft

Worked Examples

Example — Example 1 — Line Through Two Points

Write the equation of the line through A(1,3)A(-1, 3) and B(3,1)B(3, -1).

Solution. Compute the slope:

k=133(1)=44=1k = \frac{-1 - 3}{3 - (-1)} = \frac{-4}{4} = -1

Using point-slope form with point A(1,3)A(-1, 3):

y3=1(x(1))=(x+1)y - 3 = -1 \cdot (x - (-1)) = -(x + 1)

y=x1+3=x+2y = -x - 1 + 3 = -x + 2

Verification: A(1,3)A(-1, 3): (1)+2=3-(-1) + 2 = 3 \checkmark. B(3,1)B(3, -1): 3+2=1-3 + 2 = -1 \checkmark.

Answer: y=x+2y = -x + 2. \blacktriangleleft

Example — Example 2 — Perpendicular Line

Find the equation of the line through P(2,5)P(2, 5) perpendicular to the line y=3x4y = 3x - 4.

Solution. The given line has slope k1=3k_1 = 3. The perpendicular slope is:

k2=1k1=13k_2 = -\frac{1}{k_1} = -\frac{1}{3}

Using point-slope form with P(2,5)P(2, 5):

y5=13(x2)y - 5 = -\frac{1}{3}(x - 2)

y=x3+23+5=x3+173y = -\frac{x}{3} + \frac{2}{3} + 5 = -\frac{x}{3} + \frac{17}{3}

Or equivalently: x+3y17=0x + 3y - 17 = 0.

Answer: y=x3+173y = -\dfrac{x}{3} + \dfrac{17}{3} (or x+3y17=0x + 3y - 17 = 0). \blacktriangleleft

Example — Example 3 — Angle of Inclination

A line passes through the origin and makes an angle of 135°135° with the positive xx-axis. Write its equation.

Solution. The slope is k=tg135°=tg(180°45°)=tg45°=1k = \operatorname{tg} 135° = \operatorname{tg}(180° - 45°) = -\operatorname{tg} 45° = -1.

The line passes through the origin, so b=0b = 0. Equation: y=xy = -x.

Answer: y=xy = -x. \blacktriangleleft

Exercises

Exercise

Write the equation of the line:

  1. With slope k=2k = 2 passing through (0,3)(0, -3)
  2. Through the points A(0,4)A(0, 4) and B(6,0)B(6, 0)
  3. Through C(2,1)C(-2, 1) and D(4,4)D(4, 4)
Exercise

For each pair of lines, determine whether they are parallel, perpendicular, or neither.

  1. y=2x+1y = 2x + 1 and y=2x5y = 2x - 5
  2. y=3xy = 3x and y=13x+7y = -\frac{1}{3}x + 7
  3. y=4x2y = 4x - 2 and y=4x+2y = -4x + 2

Hint: Check slopes — same slope means parallel; product of slopes =1= -1 means perpendicular.

Exercise

A triangle has vertices A(0,0)A(0, 0), B(4,0)B(4, 0), C(2,6)C(2, 6).

  1. Find the equation of each side of the triangle.
  2. Find the equation of the median from CC to side ABAB.
  3. Find the equation of the altitude from CC to side ABAB.