← Back to High School Math

Graphing Lines & Slope

High School Math · Algebra 1Preview

1. Introduction

The straight line is the simplest and most useful graph in mathematics. Lines describe constant rates of change: a phone plan that charges a fixed fee plus a price per gigabyte, a car traveling at steady speed, the relationship between Celsius and Fahrenheit. Understanding how to read, graph, and write equations of lines is foundational to all of algebra, geometry, and the study of functions.

Everything starts on the coordinate plane, where each point is named by an ordered pair (x,y)(x, y). A line is the set of all points satisfying a linear equation, and the single most important number attached to a line is its slope — a precise measure of steepness and direction. The slope, together with where the line crosses the yy-axis, completely determines the line.

In this article we build the topic from the coordinate plane up: the meaning and computation of slope, the three major forms of a line's equation (slope-intercept, point-slope, and standard form), how to graph a line quickly, and the slope relationships that define parallel and perpendicular lines. We include derivations of the slope formula, geometric interpretations of intercepts, and worked examples covering real-world linear models. Every linear function you encounter in science, business, and statistics builds on the ideas presented here.

2. Core Concepts

2.1 The coordinate plane

The plane is formed by a horizontal xx-axis and a vertical yy-axis meeting at the origin (0,0)(0, 0). A point (x,y)(x, y) is located by moving xx units horizontally (positive right, negative left) and yy units vertically (positive up, negative down). The axes split the plane into four quadrants, numbered counterclockwise starting from the upper right (Quadrant I: x>0x > 0, y>0y > 0).

The distance between two points (x1,y1)(x_1, y_1) and (x2,y2)(x_2, y_2) is d=(x2x1)2+(y2y1)2d = \sqrt{(x_2 - x_1)^2 + (y_2 - y_1)^2}, though for line work the slope formula is more central.

2.2 Slope as rise over run

Slope, denoted mm, measures how steeply a line rises or falls. It is the ratio of vertical change (rise) to horizontal change (run) between any two points on the line:

m=riserun=y2y1x2x1.m = \frac{\text{rise}}{\text{run}} = \frac{y_2 - y_1}{x_2 - x_1}.

A crucial property of straight lines is that this ratio is the same no matter which two points you choose — that constancy is exactly what makes the line straight. If you move along a line, the vertical change per unit horizontal change never varies.

2.3 Deriving the slope formula

Given two points (x1,y1)(x_1, y_1) and (x2,y2)(x_2, y_2) on a line, consider the right triangle with legs Δy=y2y1\Delta y = y_2 - y_1 and Δx=x2x1\Delta x = x_2 - x_1. Similar triangles along the line guarantee that ΔyΔx\tfrac{\Delta y}{\Delta x} is constant. This constant ratio is the slope. The formula m=y2y1x2x1m = \tfrac{y_2 - y_1}{x_2 - x_1} encodes this geometry algebraically.

2.4 Interpreting the sign and size of slope

  • Positive slope: the line rises from left to right (as xx increases, yy increases).
  • Negative slope: the line falls from left to right.
  • Zero slope: the line is horizontal (yy never changes), equation y=by = b.
  • Undefined slope: the line is vertical (xx never changes, so the run is 00 and we cannot divide), equation x=ax = a.

A larger magnitude m|m| means a steeper line; a small magnitude means a gentle one. Slope 12\tfrac{1}{2} rises one unit for every two units right; slope 33 rises three units per unit right.

2.5 The yy-intercept and slope-intercept form

The yy-intercept is the point where the line crosses the yy-axis, where x=0x = 0. If that point is (0,b)(0, b), the line's equation can be written in slope-intercept form:

y=mx+b.y = mx + b.

This form is the most readable: mm is the slope and bb is the yy-intercept, so you can graph or describe the line at a glance. The slope mm also represents the rate of change of yy with respect to xx.

2.6 The xx-intercept

The xx-intercept is where the line crosses the xx-axis (y=0y = 0). In slope-intercept form, set y=0y = 0: 0=mx+b0 = mx + b, giving x=bmx = -\tfrac{b}{m} (when m0m \neq 0). In standard form Ax+By=CAx + By = C, set y=0y = 0 to find the xx-intercept and x=0x = 0 to find the yy-intercept.

2.7 Point-slope form (derivation)

Given a slope mm and any single point (x1,y1)(x_1, y_1) on the line, point-slope form writes the equation directly:

yy1=m(xx1).y - y_1 = m(x - x_1).

This comes straight from the slope definition: rearranging m=yy1xx1m = \tfrac{y - y_1}{x - x_1} gives the formula. It is the fastest way to start when you know a point and a slope, or two points (compute slope first, then use either point).

2.8 Standard form

Standard form writes a line as Ax+By=CAx + By = C, often with integer coefficients and A0A \ge 0. It is useful for finding intercepts quickly and for systems of equations. Converting from slope-intercept: y=mx+by = mx + b becomes mx+y=b-mx + y = b, or mxy=bmx - y = -b.

2.9 Parallel lines (theorem)

Parallel lines never meet; they have equal slopes, m1=m2m_1 = m_2 (and different intercepts, or they are the same line). This follows from the definition: if two lines have the same steepness and direction, they either coincide or never cross. The converse is also true: equal slopes imply parallel (or identical) lines.

2.10 Perpendicular lines (theorem)

Perpendicular lines meet at a right angle; their slopes are negative reciprocals, meaning m1m2=1m_1 \cdot m_2 = -1, equivalently m2=1m1m_2 = -\tfrac{1}{m_1}. For example, a line with slope 23\tfrac{2}{3} is perpendicular to any line with slope 32-\tfrac{3}{2}. The product of perpendicular slopes is always 1-1 (except for horizontal/vertical pairs, where one slope is 00 and the other is undefined).

2.11 Slope as rate of change

In applied problems, slope represents a constant rate: miles per hour, dollars per item, liters per minute. The intercept represents the starting value (initial fee, initial volume, etc.). The equation y=mx+by = mx + b is the universal template for linear models.

2.12 Scatter plots and lines of best fit (preview)

When data points do not lie exactly on a line, we still use linear models. A line of best fit approximates the trend in a scatter plot. The slope of the best-fit line estimates the average rate of change in the data, and the intercept estimates the value when the independent variable is zero. This connects graphing lines to statistics.

2.13 Distance between parallel lines

Two distinct parallel lines with slope mm and yy-intercepts b1b_1 and b2b_2 are separated vertically by b2b1|b_2 - b_1| in slope-intercept form. For lines in standard form Ax+By=C1Ax + By = C_1 and Ax+By=C2Ax + By = C_2, the perpendicular distance is C2C1A2+B2\tfrac{|C_2 - C_1|}{\sqrt{A^2 + B^2}}. This geometric fact follows from the slope-intercept structure.

Continue reading with Premium

Upgrade to read the full article and unlock all Premium features.

Free

  • Unlimited practice — all difficulties
  • 3 hints / day
  • Community solutions
  • 2 timed mocks / month

Premium

  • Full article + all 57+ theory guides
  • Unlimited hints on practice problems
  • Unlimited timed mock exams & PDF worksheets
Log in