Interactive visualiser

The straight line y = mx + c

In y=mx+cy = mx + c, mm is the gradient and cc is where the line crosses the yy-axis. Slide them, drag the gradient triangle along the line, then move a point and get the parallel and perpendicular lines through it, with the working.

Loading the visualiser…

Works on a phone, tablet or computer — nothing to install, no account.

What you are looking at

The blue line is y=mx+cy = mx + c. A dashed triangle on it shows the gradient as rise over run — drag its corner anywhere along the line and the two legs change but their ratio does not, which is what “the gradient is the same everywhere on a straight line” means. The yellow dot is the yy-intercept (0,c)(0, c), and the working restates the equation from those two numbers.

The Parallel and Perpendicular tabs add a point QQ that you can drag on the grid. The parallel line keeps the gradient mm and finds its own intercept from c=y1−mx1c = y_1 - mx_1; the perpendicular line uses m2=−1m1m_2 = -\dfrac{1}{m_1}, and the working checks that m1×m2=−1m_1 \times m_2 = -1. Both equations are written out in full, so the method is on screen next to the picture it describes.

Try this

  1. 1Slide mm from 12\dfrac{1}{2} down through 00 to −2-2: the line flattens, then tips the other way, and the rise in the gradient triangle turns negative.
  2. 2On Parallel, drag QQ onto the blue line itself. The parallel line becomes the same line, drawn dashed, and the working says why.
  3. 3On Perpendicular, set m=0m = 0: the perpendicular to a horizontal line is vertical, x=x = the xx-coordinate of QQ, and it has no gradient to write.
  4. 4Press Play: mm sweeps from −4-4 to 44 and the perpendicular line swings the opposite way, always at right angles.

Mistakes students make

  • Reading the gradient off the picture when the axes have different scales. Count the squares as rise and run in units, not in centimetres.
  • Confusing the yy-intercept with the xx-intercept: cc is the value of yy when x=0x = 0. The line y=2x−6y = 2x - 6 crosses the yy-axis at −6-6 and the xx-axis at 33.
  • Writing the perpendicular gradient as 1m\dfrac{1}{m} or −m-m. It is −1m-\dfrac{1}{m}: for m=12m = \dfrac{1}{2} the perpendicular has gradient −2-2, and the product is −1-1.

In the exam

  • “Find the equation of the line through (2,−1)(2, -1) parallel to y=12x+1y = \dfrac{1}{2}x + 1”: keep m=12m = \dfrac{1}{2}, substitute the point to get c=−1−12×2=−2c = -1 - \dfrac{1}{2} \times 2 = -2, and write y=12x−2y = \dfrac{1}{2}x - 2.
  • Given two points, find m=y2−y1x2−x1m = \dfrac{y_2 - y_1}{x_2 - x_1} first, then substitute one point to find cc. Perpendicular lines are Extended only; parallel lines are on both papers.

Where it is taught

  • Cambridge IGCSE Mathematics 0580/0980 · 3.1 Coordinates and linear graphs · 3.2 Gradient of a line · 3.4 Equation of a straight line (parallel lines; perpendicular lines: Extended)

Teaching this?

Put this visualiser on your lesson board with one tap. Your student sees every drag, live, on their own screen — and Owlileo marks the homework, runs the tests and keeps the parents informed.

Start free →