Home / Learn / Maths / Line forms converterTool #L236 (formerly #1378)

Equation of a straight line in every form: drag two points, plus angle between lines and distance from a point

Drag two points and see the slope and every form of the line's equation update together: two-point, point-slope, slope-intercept, intercept, general and normal form. Add a second line and a point for the angle between lines and the perpendicular distance, drawn.

Keep it one tap away for everyday use.

Bookmark Line forms converter?

Press Ctrl + D now. Your browser opens its own bookmark box, where you choose the name and folder.

  1. Drag A, B
  2. Slope
  3. All forms
  4. Practise
Nothing is uploadedWorks offline once open

Drag the points

Drag A and B (and C, D and P when the extra part is on). Points snap to whole numbers.

The same line, every form

Try this

  • Put A and B one above the other. The slope is undefined, the line is x = constant, and slope-intercept form disappears.
  • Drag B until the line passes through the origin. The intercept form no longer works: both intercepts are 0.
  • Turn on the second line. Make CD parallel to AB (same slope), then perpendicular (slopes multiply to −1).
  • Drag P onto the line AB: the distance becomes 0. Then move it away and compare the distance with the length of the dashed perpendicular.

Check yourself

Fresh questions every time. Fractions like −3/4 are fine. Nothing is saved.

What it does

A straight line can be written in several ways, and textbooks switch between them all the time. On this page you drag two points A and B on a grid and see one line written every way at once:

  • the slope m = (y₂ − y₁)/(x₂ − x₁) as a fraction, and the inclination θ with tan θ = m;
  • two-point form and point-slope form, y − y₁ = m(x − x₁);
  • slope-intercept form, y = mx + c;
  • intercept form, x/a + y/b = 1, where the line cuts the axes (green dots);
  • general form, Ax + By + C = 0, with whole numbers and no common factor;
  • normal form, x cos ω + y sin ω = p, where p is how far the line is from the origin.

Special cases are explained rather than hidden: a vertical line has no slope, a horizontal line has no x-intercept, and a line through the origin has no intercept form.

Tick the box to add a second line CD and a point P. The page then works out the angle between the two lines, says when they are parallel or perpendicular, finds where they meet, and draws the perpendicular from P to AB with its length and its foot F.

It follows the Class 11 chapter straight lines, building on Class 10 coordinate geometry.

The distance and section formulas come first in section formula; two lines meeting is a pair of linear equations in linear pairs, and curves come next in conic explorer.

How to use it

  1. Drag A and B. They snap to whole numbers from −10 to 10, so every equation has whole numbers or simple fractions.
  2. Read the forms card: each line shows the general formula, then your numbers.
  3. Tick Add a second line CD and a point P and drag C, D (orange) and P (red).

A worked example

The page starts with A(−4, −1) and B(2, 3).

  • Slope m = (3 − (−1))/(2 − (−4)) = 4/6 = 2/3; inclination 33.69°.
  • Point-slope form: y + 1 = (2/3)(x + 4). Slope-intercept form: y = (2/3)x + 5/3.
  • Intercept form: x/(−5/2) + y/(5/3) = 1. General form: 2x − 3y + 5 = 0.
  • Normal form: x cos 123.69° + y sin 123.69° = 1.3868, and 5/√13 ≈ 1.3868.

With the extra part on, CD from C(−6, 6) to D(6, 0) is x + 2y − 6 = 0 with slope −1/2. tan θ = |(2/3 + 1/2)/(1 − 1/3)| = 7/4, so θ ≈ 60.26°; the lines meet at (8/7, 17/7) ≈ (1.143, 2.429). P(5, −5) is |2×5 − 3×(−5) + 5|/√13 = 30/√13 ≈ 8.3205 from AB.

Tips

  • Parallel lines have equal slopes; perpendicular lines have slopes that multiply to −1 (unless one is vertical).
  • To go from general form to slope-intercept form, solve for y: m = −A/B and c = −C/B.
  • The distance formula’s top line, Ax₀ + By₀ + C, is 0 exactly when P is on the line.

Check yourself

Five fresh questions: a slope from two points, a y-intercept, a distance from a point to a line, a perpendicular slope and an x-intercept from the general form. Nothing is saved.

FAQ

Is normal form still taught? Some syllabuses dropped it; it is shown for anyone who needs it and can be skipped.

Is this from the NCERT book? It covers the same topics with fibub’s own examples. fibub is not part of NCERT.

Where the numbers come from

  • Standard coordinate geometry of the straight line: slope, inclination, the two-point, point-slope, slope-intercept, intercept, general and normal forms, tan θ = |(m₁ − m₂)/(1 + m₁m₂)| and the distance |Ax₀ + By₀ + C|/√(A² + B²). Written for fibub.
  • Checked on hand-worked examples (computed again in Python) and on 300 random lines: both points satisfy the equation, the foot of the perpendicular lies on the line at the stated distance, and the normal form holds.

Standard scientific values, such as constants, atomic weights and melting points, are facts found in every textbook; we name where ours were checked. If you are an author or publisher and want a value, a credit or a table changed or removed, tell us and we will act quickly.

Last updated 2026-11-09.

Change log for Line forms converter

  1. Add #1378 Line forms converter Details on GitHub

Every change to fibub

Related tools

Trig ratio explorer #L70 Drag the angle of a right triangle and see sin, cos and tan as ratios of its sides, with the exact values at 0°, 30°, 45°, 60° and 90°, the identities checked live, and the full unit circle for Class 11. Linear pairs #L74 Type two equations and see their lines cross, run parallel or lie on top of each other. The ratio test says how many solutions there are, and the substitution and elimination methods are worked step by step with exact fractions. Section formula #L77 Drag two points on a grid and see the distance formula, the point that divides the segment in any ratio m : n, and the midpoint, worked with your numbers. Add a third point for the centroid and the area of the triangle. Conic explorer #L91 Slide the numbers in the equation of a circle, ellipse, parabola or hyperbola and watch the curve change, with its foci, directrices, eccentricity and latus rectum marked. Move a point P to see the focus distances that define each curve, and tilt a plane through a double cone to see where all four come from. 3D point plotter #L237 Turn a set of x, y and z axes round with your finger, place two points and see the dashed box that shows each coordinate. The octant of each point and the 3D distance formula are worked with your numbers, and the section formula puts a third point between them. Parabolic dish #L238 Shine parallel rays into a dish shaped like the parabola x² = 4ay and watch every one reflect through the focus, while a circle-shaped mirror blurs them. Light from the focus comes out as a straight beam, and a real dish's focus is found from its width and depth.