Main content

### Course: Pre-algebra > Unit 13

Lesson 7: Writing slope-intercept equations- Slope-intercept equation from graph
- Writing slope-intercept equations
- Slope-intercept equation from graph
- Slope-intercept equation from slope & point
- Slope-intercept equation from two points
- Slope-intercept from two points
- Slope-intercept form problems
- Slope-intercept form from a table
- Slope-intercept form review

© 2024 Khan AcademyTerms of usePrivacy PolicyCookie Notice

# Slope-intercept form from a table

Learn how to write an equation of the line that matches up to a table of values. Created by Sal Khan.

## Want to join the conversation?

- This just seems really confusing, is there any other easier way to learn this?(16 votes)
- It's really all about substituting. Taking your time helps a lot. It is difficult at first, and probably even harder to explain without confusing someone (I have experience!), but I advise you find some good websites to explain this...

Do you remember doing function tables with the input and output when you were a kid? It's almost the same exact thing...

You need to focus on the relationship between x and y -- trial and error helps, too.

y =*___x + ____*

If y always = 2.....

y = 0x + 2 (no matter what x equals, y always equals 2 ---- so when you multiply x by 0 and then add 2, regardless of the x-value, y is ALWAYS equal to 2.)

0x = 0, just like 0 times 1 = 0 ---> anything times 0 is 0.

y = 2

Hope this helps a little! Sorry, if it doesn't! Good luck, anyway!(17 votes)

- Dude, its like 2AM and im so confused about this 😭(9 votes)
- I am so confused, is there a simple way to solve this?(6 votes)
- I'm afraid this is the simpler way. Need a hand?(6 votes)

- At0:47, why is the slope 0 and not 2? Somebody explain, please!(4 votes)
- The slope is easiest to understand in a graph. A slope of 2 means that the graph line goes up 2 units when you go right 1 unit. See for example this image: http://prepfortests.com/files/images/geometry/cartesianline.png Here if you go from x = 0 to x = 1, y changes from -3 to -1. In other words, you go up 2 units, so the slope is 2.

In the video however, the y value is always equal to 2. If you graph this, you simply get a horizontal line, as in this image: http://cdn-6.ask-math.com/images/Linegraph-1.png What is the slope in that image? Well, how much does the line go up when you go right 1 unit? If you go from x = 0 to x = 1 for example, y always stays 2. So you go up 0 units, and the slope is 0.(7 votes)

- So when u look at a table do u want to see how much it goes by each time(5 votes)
- At0:38Sal says that Y is always zero, but wouldn't it be two?(5 votes)
- This is because the slope means how much you move in order to get to the next point. Since, the number remains as 2 no matter how much the x-value changes, it would be 0. However, if it was actually 2, the y-coordinates would change 2 units to the right for each change in the x-intercept(4 votes)

- I thought Y is the intercept and X is the slope. Why is it different in the Video?(4 votes)
- Actually, m is the slope and b is the y-intercept. Y is simply to show where on the y-axis, the line is supposed to be located. Hope I helped!(4 votes)

- what if there are 6 sets of coordinates?(4 votes)
- It doesn't matter what 2 coordinates you pick out. For example, let's pick out 2 coordinates, like (2, 4) and (7, 2). (2, 4) is the starting point and (7, 2) is the ending point. We first solve the slope which is shown below here:

2-4=-2 <--- numerator

7-2=5 <---- denominator

Now that we have solved for the slope, which is -2/5, let's solve for the y-intercept. Let's use (7, 2) to plug into the equation.

2=-2/5(7)+b ----> 2=-14/5+b ----> 24/5=b

Now this is your slope-intercept equation: y=-2/5x+24/5(2 votes)

- Does it matter what point you choose to solve for (b) ?(4 votes)
- Nope not at all, since all the coordinates for the function are the input and output. It doesn't matter because the points on the line follow the same pattern or function.(3 votes)

- how do i write an equation with graph points like y intercept =-5 and slope = 3(3 votes)
- The general format of slope-intercept form equations is y=mx+b

m is where you substitute the slope

b is where you substitute the y-intercept

So, if I had y-intercept = 7 and slope = -2, the equation would be:

y=-2x+7(5 votes)

## Video transcript

A line goes through
the following points, and the equation of that line
is written in y equals mx plus b form. Also known as
slope-intercept form. What is the equation
of the line? So the first thing we
want to think about, what is the slope of this line? What is m here? So what is our change in
y for given change in x? So this is an
interesting example here. And I encourage you to pause the
video and try it out yourself. Because no matter how much we
change x, y is not changing. y is a constant, 2. So your change in y between any
two points is going to be 0. It doesn't matter
what your change in x is, your change in x could be
1, your change in x could be 4, your change in y is always 0. So y is not changing
as you change x. So your slope for this
relationship is actually 0. Y is equal to 0x
plus-- and then, you could just realize that
the equation of this is just that y is
always equal to 2. So it's 0x plus 2, which is the
same thing as y is equal to 2. You could substitute back in. You could say OK, well, if
y is equal to 0x plus b, that means that y is equal to b. Well, y is always equal to 2,
no matter what thing you pick, so b is equal to 2. So either way, this
just boils down to y is equal to 0x plus 2,
or y is just equal to 2. Let's do another one of these. Maybe one where the y
is actually changing. So here, the y is clearly
actually changing. So let me copy and paste this. I want to put on my scratch pad. We can work it out. So we'll stick it
right over here. And then we are told a line
goes through the-- OK, so same thing. The line goes
through these points with the equation of a line. So the main idea
here is, you only need 2 points for
an equation of line. They've given us
more than necessary. So I'd like to pick
the two points that make things a
little bit simpler. So I'll pick the
point 4, 2 and 7, 0. I just picked those
two points because they have nice, clean numbers
associated with it. So what is our change in x here? So our change in x here, if we
go from 4 to 7, our change in x is equal to 3. And what's our change in y here? So we went up from 4 to 7. We increased by 3. Our y decreased by 2. Change in y is
equal to negative 2. So our slope, which is equal to
change in y over change in x, is equal to negative 2/3. And if you wanted to
relate that to the formulas that you normally
see for slope, you're just looking at your end point. So this is y2 minus
y1, which is negative 2 over x2 minus x1,
which is 7 minus 4. But that just boils
down to negative 2/3. And so our equation is going
to be y is equal to negative 2/3 x plus b. So let's substitute one
of these points in here, to figure out what
our b must be. And once again, I
want to figure out something where this is going
to become nice and clean. But this isn't going to
be really clean for any of these numbers
right over here. If we had a 3 for x, or a
6 for x, or a 0 for x, then things would work out nicely. But they don't give
us any of those. So let's just try
the 7 and the 0. So when x is equal to 0--
sorry, when x is equal to 7-- y is equal to 0. So when x is equal to 7, I'll
just do it in the same color, y is equal to 0. So 0 is equal to negative
2/3 times 7 plus b, or 0 is equal to negative
14/3 plus b. Add 14/3 to both sides,
you get 14/3 is equal to b. So this is going to be
y is equal to negative-- I'm going to go back
to the other screen-- so y is equal to
negative 2/3 x plus 14/3. So let me do that. So y is equal to
negative 2/3 x plus 14/3. Let's check our answer. We got it right.