Slope calculator: rise, run, line equations and graphs
Choose two points, rise and run, a point with slope, or a point with a directed angle. Enter coordinates in consistent units. In the point modes, distance is optional. Radians accept a controlled multiple of π such as pi/2 or 2*pi/3.
Choose the measurements you know
Two distinct points define a line. Their signed horizontal and vertical changes are Δx = x₂ − x₁ and Δy = y₂ − y₁. If you already know those changes, use Rise and run. If you know one point and the slope or a directed angle, you can determine the line and optionally locate a point at distance d. Keep both coordinate axes in compatible units before forming a ratio.
Calculate slope, percentage grade and angles
For P₁ = (1, 2) and P₂ = (4, 6), Δx = 3 and Δy = 4, so m = 4/3 and the grade is about 133.33%. The distance is 5. Grade is 100 times the signed slope, not an angle in degrees. The left-to-right tilt is arctan(m). Line inclination is reported modulo a half-turn, while the directed angle uses atan2(Δy, Δx) and follows the ordered points. Reversing the points changes the directed angle by a half-turn without changing slope.
Find the equation and intercepts
A nonvertical line through P₁ satisfies y − y₁ = m(x − x₁). Its y-intercept is b = y₁ − mx₁, giving y = mx + b. In the example above, b = 2/3 and the normalized integer equation is 4x − 3y = −2. For rational directions and coordinates, these forms and any unique intercepts are exact. A noncardinal directed angle can produce approximate coefficients. Rise and run alone give a direction, not a unique intercept.
Recognize horizontal, vertical and coincident cases
A horizontal line has zero rise and slope 0. A vertical line has zero run, so its slope and percentage grade are undefined. Given a point on a vertical line, its equation is x = x₁. Coincident points or a zero rise/run vector give no unique direction. A zero optional distance in a point mode is different: a direction was supplied, and the endpoint equals the start.
Locate endpoints from a point and distance
Distance along a line is different from horizontal run. With slope m, the rightward unit vector is (1, m)/√(1 + m²); adding and subtracting d times that vector gives the two possible endpoints. With a directed angle θ measured counterclockwise from the positive x-axis, use the single vector d(cos θ, sin θ). A positive 90° angle goes up and a negative 90° angle goes down, even though both describe vertical lines.
Read the graph and precision correctly
The plotted axes use an equal scale and positions relative to the start, so large coordinates do not hide small changes through floating-point subtraction. Numbers and fractions support up to 50 coefficient digits per component and exponent magnitudes up to 40. Numeric radians are limited to absolute values up to 1,000,000; exact π multiples are reduced before calculation. Copy, CSV and print include labelled formulas and full working. These formulas describe a Euclidean plane.
Use Fraction Calculator to reduce a rise/run ratio, Ratio Calculator to compare slopes with matching units, and Percentage Calculator to check the grade conversion. The rise/run triangle connects this result to Triangle Calculator and Root Calculator. Use Scientific Calculator to check an arctangent with the same angle unit. For a straight-line distance in three dimensions or a surface distance on Earth, use the Distance Calculator.
ISO 80000-2:2019 gives the notation context, without certifying the tool. BIPM SI Brochure describes plane angles and consistent length units. OpenStax — Understand Slope of a Line covers slope, rise/run and vertical lines; OpenStax — Find the Equation of a Line derives point-slope and slope-intercept forms. These are planar calculations for consistent coordinate units.
Common questions
What does significant digits mean?
It controls rounding of approximate displayed answers, counting from the first nonzero digit. At 3 significant digits, 123.456 becomes 123 and 0.00123456 becomes 0.00123. Exact fractions remain exact. Rounding does not improve measurement accuracy.
Does a 100% grade mean a 100° angle?
No. A 100% grade means m = 1: equal rise and run, with a 45° left-to-right tilt. Grade and angle use different formulas.
Why is vertical slope undefined?
Its horizontal change is zero, so dividing rise by run is impossible. If a point on the line is known, the equation is x = x₁. A vertical line does not have a finite percentage grade.
Why are there two distance endpoints?
A slope identifies an undirected line. A point at a positive distance may lie on either side of the start. Supply a directed angle if you need just one direction. At distance zero the endpoint is the start.
Can rise and run alone determine the intercept?
No. The same rise/run ratio belongs to many parallel lines. Supply a point on the line to determine its intercept and equation.
Can I enter radians or an exact multiple of π?
Yes. Choose radians and enter a decimal, fraction or controlled form such as pi/2. Exact cardinal angles are recognized as horizontal or vertical. A decimal close to π/2 remains a near-vertical angle.
Explore related tools
- Right Triangle Calculator
- Pythagorean Theorem Calculator
- Surface Area Calculator
- Circle Calculator
- Distance Calculator
- Area Calculator
- Volume Calculator
- Triangle Calculator
- Confidence Interval Calculator
- Z-score Calculator
- Permutation and Combination Calculator
- Mean, Median, Mode & Range Calculator
- Statistics Calculator
- Probability Calculator
- Sample Size Calculator
- Number Sequence Calculator
- Standard Deviation Calculator
- Random Number Generator
- Scientific Notation Calculator
- Big Number Calculator
- Root Calculator
- Log Calculator
- Matrix Calculator
- Rounding Calculator
- Exponent Calculator
- Fraction Calculator
- Scientific Calculator
- Percentage Calculator
- Percent Error Calculator
- Quadratic Formula Calculator
- Least Common Multiple Calculator
- Greatest Common Factor Calculator
- Factor Calculator
- Ratio Calculator