# Q&A: What is the Easiest Way to Graph a Linear Equation?

*Cross-posted from here.*

## Question

In the case of plotting the graph of a linear equation with integer coefficients in 2 variables it seems the most difficult part might be finding an integer point to start with.

Take the equation $6x+21y=20,$ or similar. One could use Euclid’s algorithm (or similar) to find an integer point and step off another point, but this is not feasible to teach at high school.

What procedure should I teach students, that will handle such equations?

## Answer

If you’re just trying to get students to graph lines, then while it’s a good idea to start students off graphing lines whose equations permit obvious integer points, I think it’s a mistake to necessitate integer points when the equations get more complicated.

For instance, the line $y= x + \sqrt{2}$ could easily show up in a high school math course, but there aren’t any integer points that lie on it.

Personally, I think the easiest procedure for graphing lines is to just plot the $x$ and $y$-intercepts and draw a line through them

In your case, for the line $6x+21y=20,$ it’s easy to see that the $x$ and $y$ intercepts are as follows:

And when you write the intercepts in mixed number form (or decimal form) it’s easy to see where they go on a graph.

That said, if both of the intercepts come out to $0,$ then you need to either plug in a nonzero number for one of the variables or use the slope to find another point.