Find the slope and equation of a line.
A slope calculator finds the slope of a line passing through two points on a coordinate plane. Enter the coordinates (x1, y1) and (x2, y2), and the calculator computes the slope (m), the y-intercept (b), the slope-intercept equation (y = mx + b), and the distance between the two points.
Slope represents the rate of change between two points, describing how steep a line is and whether it rises or falls. Understanding slope is fundamental to algebra, geometry, calculus, and countless real-world applications from road grades to stock price trends.
The slope formula is m = (y2 - y1) / (x2 - x1). This calculates the "rise over run," or how much the line goes up (or down) for every unit it moves to the right. A positive slope means the line rises from left to right. A negative slope means it falls. A slope of zero means the line is horizontal.
Once the slope is found, the y-intercept is calculated by substituting one point into y = mx + b and solving for b. The distance between the two points uses the distance formula: d = the square root of ((x2 - x1)² + (y2 - y1)²), which is an application of the Pythagorean theorem.
Points: (2, 3) and (8, 15)
Slope = (15 - 3) / (8 - 2) = 12 / 6 = 2. Y-intercept: 3 = 2(2) + b, so b = -1. Equation: y = 2x - 1. Distance = the square root of (36 + 144) = the square root of 180 = approximately 13.42.
A slope of 0 means the line is perfectly horizontal. The y-values are the same for both points, so there's no rise. The equation is simply y = b (a constant). Don't confuse zero slope (horizontal line) with undefined slope (vertical line). They are very different.
Undefined slope occurs when the two points have the same x-coordinate, creating a vertical line. The formula produces a division by zero (x2 - x1 = 0). Vertical lines are written as x = a (a constant), not in y = mx + b form. They cannot be expressed with a numeric slope.
Parallel lines have equal slopes (m1 = m2). Perpendicular lines have slopes that are negative reciprocals of each other (m1 x m2 = -1). For example, a line with slope 2 is perpendicular to a line with slope -1/2. A line with slope 3 is parallel to any other line with slope 3.
"Rise over run" is the intuitive way to think about slope. The rise is the vertical change (y2 - y1) and the run is the horizontal change (x2 - x1). If you go up 3 and right 4, the slope is 3/4. If you go down 2 and right 5, the slope is -2/5. The sign tells you the direction.
No. As long as you're consistent, the result is the same. If you use point A as (x1, y1), use point A's coordinates in both the numerator and denominator. Swapping the points negates both the numerator and denominator, so the slope remains unchanged.
Slope appears everywhere. Road grades are expressed as percentage slope (a 6% grade rises 6 feet per 100 feet). Roof pitch is rise over run (a 4/12 pitch rises 4 inches per 12 inches of horizontal run). In business, slope represents the rate of change in revenue, costs, or growth over time.
Let ChatGPT, Claude, or Perplexity do the thinking for you. Click a button and see what your favorite AI says about Formula Bot.
Compute symbolic derivatives instantly with step-by-step rules and an interactive graph of f(x) and f'(x).
Convert between units of length, weight, temperature, volume, speed, time, and area instantly.
Add, subtract, multiply, and divide fractions instantly with step-by-step simplification to lowest terms.
Compute mean, median, mode, standard deviation, variance, quartiles, and a full five-number summary from any dataset.
Calculate compound interest with year-by-year breakdowns, future value, and effective annual rate.
Compute combinations (nCr), permutations (nPr), and factorials (n!) instantly with step-by-step formula expansions.
Perform complex number arithmetic, find conjugates, magnitude, and polar form with step-by-step solutions.
Compute indefinite and definite integrals instantly with AI-powered step-by-step solutions.
Convert numbers between binary, octal, decimal, and hexadecimal instantly with all representations shown at once.
Evaluate limits of functions instantly with a table of approaching values from left, right, or both sides.
Calculate percentages three ways: find X% of Y, what percent X is of Y, or percentage change.
Compute the line of best fit (y = mx + b), R-squared, correlation coefficient, predictions, and residuals from any dataset.
Find real and complex roots of quadratic, cubic, and quartic polynomials with step-by-step solutions.
Compute sigma notation sums instantly with individual terms and partial sums displayed step by step.
Find GCD, LCM, and prime factorizations instantly with step-by-step Euclidean algorithm and trial division.
Simplify algebraic expressions instantly with a breakdown of the rules applied and an expanded form.
Compute determinant, inverse, transpose, multiplication, eigenvalues, and rank — with step-by-step explanations.
Compute dot product, cross product, magnitude, unit vectors, and angle between vectors — with step-by-step formulas.
Solve linear systems (Ax = b) and quadratic equations (ax^2+bx+c = 0) instantly with step-by-step solutions and verification.
Calculate tips and split bills with ease.
Calculate your grade point average instantly.
Calculate area for any shape and convert between units.
Find square roots with step-by-step solutions.
Find out what you need on your final exam.
Solve quadratic equations step by step.
Find the missing side of a right triangle.
Calculate annuity payments and values.
Calculate dividend yield and income projections.
Solve long division with detailed steps.
Calculate your exact age in years, months, and days.
Calculate how your investments grow over time.
Calculate sale prices and savings instantly.
Convert and calculate with scientific notation.
Calculate logarithms with any base.
Round numbers to any decimal place.
Calculate markup percentage and profit margins.
Add, subtract, multiply, and divide mixed numbers.
Calculate powers and exponents step by step.
Count and round significant figures.
Find the midpoint between two coordinate points.
Calculate percent error for experiments and data.
Find the GCF and LCM of any numbers.
Convert decimals to fractions in lowest terms.
Sign up for free and unlock unlimited calculations, saved history, and more.
Get Started Free