What is slope?
Slope measures the steepness and direction of a line. It tells you how much the line rises or falls for every unit you move horizontally. A positive slope goes upward from left to right, while a negative slope goes downward. A slope of zero means the line is horizontal, and an undefined slope means the line is perfectly vertical.
How do you calculate slope from two points?
Given two points (x₁, y₁) and (x₂, y₂), the slope formula is: m = (y₂ − y₁) / (x₂ − x₁). This is also described as rise over run — the vertical change divided by the horizontal change. For example, given points (1, 2) and (4, 8): m = (8 − 2) / (4 − 1) = 6 / 3 = 2. The y-intercept is then b = y₁ − m·x₁ = 2 − 2·1 = 0, giving the equation y = 2x.
What is the slope formula?
The slope formula is m = (y₂ − y₁) / (x₂ − x₁), often called rise over run. Once you have the slope m, you can find the full line equation using slope-intercept form: y = mx + b, where b is the y-intercept. This form is the standard way to express a line in algebra and is compatible with graphing calculators and many educational tools. For geometry problems involving right triangles, the Pythagorean theorem calculator is a natural companion.
What are some slope examples?
Example 1 — positive slope: points (0, 1) and (3, 7). m = (7 − 1) / (3 − 0) = 6 / 3 = 2. b = 1. Equation: y = 2x + 1.
Example 2 — negative slope: points (0, 5) and (5, 0). m = (0 − 5) / (5 − 0) = −1. b = 5. Equation: y = −x + 5.
Example 3 — horizontal line: points (−2, 4) and (3, 4). m = (4 − 4) / (3 − (−2)) = 0. Equation: y = 4.
Example 4 — vertical line: points (3, 1) and (3, 7). The denominator is zero, so slope is undefined. Equation: x = 3.
When is slope useful?
Slope is a fundamental concept in algebra and coordinate geometry, making it essential for students learning about linear equations. It's also used in engineering (road gradients, ramp angles), construction (roof pitch, drainage design), economics (rate of change between variables), and physics (velocity on a position-time graph). In real-world terms, a 10% slope means the line rises 1 unit for every 10 horizontal units — the standard way to express road grade or roof pitch. For more complex geometric shapes, use our triangle calculator.
What is slope-intercept form?
Slope-intercept form is y = mx + b, where m is the slope and b is the y-intercept (the point where the line crosses the y-axis). It's the most commonly used form for expressing linear equations because it makes both the slope and y-intercept immediately visible. To convert from two points to slope-intercept form: first find m using the slope formula, then solve for b by substituting one known point: b = y − mx.
What is the difference between positive, negative, zero, and undefined slope?
A positive slope means the line rises from left to right (e.g., m = 3). A negative slope means it falls from left to right (e.g., m = −2). A zero slope (m = 0) is a horizontal line — the y-value never changes. An undefined slope occurs when the two x-values are equal (vertical line), because dividing by zero is undefined. This calculator handles all four cases and shows the correct equation for each.
Two useful properties for algebra: parallel lines always have equal slopes (if a line has m = 3, every parallel line also has m = 3). Perpendicular lines have slopes that are negative reciprocals of each other — if one line has slope m, the perpendicular line has slope −1/m. For example, a line with slope 2 is perpendicular to a line with slope −0.5, since 2 × −0.5 = −1.