How to Write an Equation from a Graph?

How to Write an Equation from a Graph?
Algebra 1

Write an Equation from a Graph

Given a line on a graph, you can recover its equation by reading two things off the grid: the y-intercept and the slope. Drop them into \(y = mx + b\) and you’ve captured the line. We’ll read several together, with a solver, practice, and a worksheet maker a tap away.

Tutor-style math help

Write an Equation from a Graph: what to notice and how to work it

Equations skill
Equation solving is undoing operations while keeping both sides balanced. Each legal move keeps the left side and right side equal.

What to notice first

Clean up the equation first, then isolate the variable. Multi-step equations usually become easier after distributing and combining like terms.

Common student mistake

Do not move a term without showing the inverse operation on both sides. Written balance steps prevent sign errors.

Key formulas and cues

\(a=b\Rightarrow a+c=b+c\)
\(a=b\Rightarrow ac=bc\)
\(\text{undo operations in reverse order}\)
\(\text{check by substitution}\)
3x+520 same move on both sides

A reliable path

  1. Simplify each sideDistribute and combine like terms before moving variables.
  2. Collect variablesUse inverse operations to get variable terms on one side and constants on the other.
  3. Check in the originalSubstitute the solution into the original equation, not only the simplified line.

Worked examples

Two-step equation

Example: \(3x+5=20\)
  1. Subtract 5 from both sides.
  2. Divide both sides by 3.
  3. Check 3(5) + 5 = 20.
Answer: \(x=5\)

Variables on both sides

Example: \(4x-7=2x+9\)
  1. Subtract 2x from both sides.
  2. Add 7 to both sides.
  3. Divide by 2.
Answer: \(x=8\)
Try one before moving on
Try: Solve \(2x-4=18\).
Answer: \(x=11\).
Next step: do the matching worksheet or quiz while the method is still fresh, then come back and explain the first step in your own words.
Illustration of students learning Write an Equation from a Graph

When a line is drawn on a coordinate grid, you can recover its equation just by reading the picture. Two features do it: where the line crosses the y-axis (that’s \(b\)) and how steeply it climbs or falls (that’s \(m\)). Put them into \(y = mx + b\) and you’ve turned a graph back into algebra.

In short: read the y-intercept off the graph, count the slope as rise over run between two clear points, then write \(y = mx + b\). A line crossing at \((0,1)\) that rises 2 for every 1 across is \(y = 2x + 1\).

The big idea

Read Two Things Off the Grid

The y-intercept is the spot where the line meets the vertical axis — read its y-value directly. For the slope, pick two points the line passes through cleanly (lattice points), then count the vertical change over the horizontal change between them.

How to do it (3 steps):

  1. Find the y-intercept \(b\) where the line crosses the y-axis.
  2. Count the slope \(m\) (rise over run) between two grid points.
  3. Write \(y = mx + b\).
Tutor tip: Choose two points where the line passes exactly through grid corners. Reading a slope off “between the lines” leads to guessing.
Reading the line

From graph to \(y = 2x + 1\)

This line crosses the y-axis at \((0,1)\), so \(b = 1\). From \((0,1)\) to \((2,5)\) it rises 4 and runs 2, so \(m = 2\). The equation is \(y = 2x + 1\).

⚡ Read a line’s equation
y = 2x + 1(0, 1)

Worked Examples

Read the intercept, count the slope — the line below shows each one on the grid.

Example A — Positive slope

A line crosses at \((0,1)\) and passes \((2,5)\).

  1. Read the y-intercept: \(b = 1\).
  2. Count the slope: \(m = \dfrac{5 – 1}{2 – 0} = 2\).
  3. Write it: \(y = 2x + 1\).

Answer: \(y = 2x + 1\)

y = 2x + 1(2, 5)

Example B — Negative slope

A line crosses at \((0,3)\) and passes \((1,1)\).

  1. Read the y-intercept: \(b = 3\).
  2. Count the slope: \(m = \dfrac{1 – 3}{1 – 0} = -2\) (falls to the right).
  3. Write it: \(y = -2x + 3\).

Answer: \(y = -2x + 3\)

y = −2x + 3(1, 1)

Example C — Through the origin

A line crosses at \((0,0)\) and passes \((2,6)\).

  1. The line crosses at the origin, so \(b = 0\).
  2. Count the slope: \(m = \dfrac{6 – 0}{2 – 0} = 3\).
  3. Write it: \(y = 3x\).

Answer: \(y = 3x\)

y = 3x(2, 6)

Example D — A gentle slope

A line crosses at \((0,2)\) and passes \((4,4)\).

  1. Read the y-intercept: \(b = 2\).
  2. Count the slope: \(m = \dfrac{4 – 2}{4 – 0} = \tfrac12\).
  3. Write it: \(y = \tfrac12 x + 2\).

Answer: \(y = \tfrac12 x + 2\)

y = ½x + 2(4, 4)

Where You’ll Use It

Reading a line off a graph is how you turn a chart into a usable formula — a trend line on a scatter plot, a distance-time graph, a supply curve. Once you have \(y = mx + b\), you can predict values the graph doesn’t directly show.

Slip-Ups That Cost Easy Points

  • Reading run over rise. Slope is vertical change over horizontal change — count up/down first.
  • Missing a negative slope. If the line falls to the right, \(m\) is negative.
  • Guessing between gridlines. Use points where the line hits exact lattice corners.
  • Stopping at the slope. Include the y-intercept; the equation needs both \(m\) and \(b\).

Your Turn: Write the Equation

Each line crosses at the first point and passes through the second. Write \(y = mx + b\). Reveal to check.

  1. \((0,0)\) and \((2,6)\)
  2. \((0,5)\) and \((5,0)\)
  3. \((0,-4)\) and \((2,2)\)
  4. \((0,2)\) and \((4,4)\)
Show answers
  1. \(\color{blue}{y = 3x}\)
  2. \(\color{blue}{y = -x + 5}\)
  3. \(\color{blue}{y = 3x – 4}\)
  4. \(\color{blue}{y = \tfrac12 x + 2}\)
Keep practicing

Make Your Own Worksheet

Generate fresh read-the-graph problems with a full answer key — print or save as a PDF.

New problems every click — never the same sheet twice
Step-by-step answer key so you can self-check
📉

Frequently Asked Questions

How do I write a line’s equation from a graph?

Read the y-intercept where the line crosses the y-axis, count the slope as rise over run between two grid points, then write \(y = mx + b\).

Which two points should I pick for the slope?

Choose points where the line passes exactly through grid intersections, so the rise and run are whole numbers you can count confidently.

How do I know if the slope is negative?

If the line goes down as you move to the right, the slope is negative; if it goes up, it’s positive.

What if the line is horizontal or vertical?

A horizontal line is \(y = b\) (slope 0); a vertical line is \(x = a\) (undefined slope) and can’t be written as \(y = mx + b\).

Related Topics

Continue Your Study

Ready for the next step? Pick up right where this lesson leaves off:

Related to This Article

What people say about "How to Write an Equation from a Graph? - Effortless Math"?

No one replied yet.

Leave a Reply

X
51% OFF

Limited time only!

Save Over 51%

Take It Now!

SAVE $55

It was $109.99 now it is $54.99

The Ultimate Algebra Bundle 2026: From Pre-Algebra to Algebra II