Slope

Algebra

Slope measures the steepness and direction of a line as the ratio of vertical change to horizontal change between any two points.

Formula

m = \frac{y_2 - y_1}{x_2 - x_1}
Visualization

Definition

Slope tells you how steep a line is and which direction it runs: a positive slope climbs uphill from left to right, a negative slope runs downhill, and a larger magnitude means a steeper line. Formally, the slope $m$ of a line through points $(x_1, y_1)$ and $(x_2, y_2)$ is $m = (y_2 - y_1)/(x_2 - x_1)$ (provided $x_2$ is not equal to $x_1$), and this ratio is the same no matter which two points on the line you pick, making slope the rate of change of $y$ with respect to $x$. Geometrically, slope equals the tangent of the angle the line makes with the positive x-axis, $m = \tan\theta$, and it is the coefficient of $x$ when the line is written $y = mx + b$. Parallel lines share the same slope, and perpendicular lines have slopes whose product is $-1$ (when both are defined).

Example

A ski run that climbs $3$ feet for every $1$ foot forward has slope $3$; a ramp that drops $1$ foot over $4$ feet has slope $-1/4$. Between the points $(1, 2)$ and $(4, 8)$, $m = (8 - 2)/(4 - 1) = 6/3 = 2$, so for every $1$ unit right, $y$ increases by $2$. A line with slope $m = 3/4$ makes an angle $\theta = \arctan(3/4) \approx 36.87^\circ$ with the x-axis, and its perpendicular has slope $-4/3$.

Key Insight

Think of slope as "rise over run": how far you go up (or down) for every step to the right. If $y$ represents distance and $x$ represents time, slope is speed, the same idea that powers calculus derivatives; more generally, slope generalizes to the gradient vector in multivariable calculus, and in a linear map $\mathbb{R} \to \mathbb{R}$ it is exactly the $1 \times 1$ matrix entry, linking algebra directly to linear transformations.