### Video Transcript

In this video, we will learn how to find and write the equation of a straight line in its general form. Weβll see how to do this when weβre given the coordinates of two points which lie on the line. And weβll also see how we can do this from the graph of a straight line. You should already be familiar with how to calculate the slope of a straight line either from two points or from its graph, although we will review this in our examples.

So the general form of the equation of a straight line then. The exact letters you use most often may vary depending on where in the world you are. But the two most commonly used forms are π¦ equals ππ₯ plus π or sometimes π¦ equals ππ₯ plus π. The values of π and π or π have important meanings in terms of the graph of the line.

The value π first of all, which is the coefficient of π₯ in this equation, refers to the slope of the line. For every one unit the line moves to the right, the line will move π units up. If π is negative, then this will mean that the line has a negative slope. It slopes downwards from left to right.

There are lots of different ways that people think about calculating the slope. The first is as change in π¦ over change in π₯. Thatβs the vertical change over the horizontal change between two points that lie on the line. Formally, if those two points have the coordinates π₯ one, π¦ one and π₯ two, π¦ two, then this can be written as π¦ two minus π¦ one over π₯ two minus π₯ one. The difference in the π¦-values over the difference in the π₯-values.

Or another more casual way that people sometimes like to think of this value π is as the rise over the run. Rise being a vertical change and run being a horizontal change. It doesnβt really matter which way you prefer to think of it as long as youβre comfortable with calculating the slope of the line.

Going back to our general form, the value of π or π refers to the π¦-intercept of the line. Thatβs the π¦-value at which the line intercepts the π¦-axis. For this reason then, because the values of π and π or π represent the slope and π¦-intercept of a straight line, an equation given in this form is sometimes referred to as the slopeβintercept form.

To find the equation of a straight line in this general form, we just need to determine the values of these two constants. Letβs see how we can do this in the context of an example.

Find the equation of the line that passes through the points π΄: five, 11 and π΅: 10, 21.

In this question then, weβve been given the coordinates of two points that lie on the line. Weβre going to find the equation of this line in its general form. Thatβs π¦ equals ππ₯ plus π or sometimes π¦ equals ππ₯ plus π, where π represents the slope of the line and π represents the π¦-intercept.

Weβre going to calculate the slope or gradient of this line first of all. And we can do this using the formula change in π¦ over change in π₯ or more formally π¦ two minus π¦ one over π₯ two minus π₯ one, where π₯ one, π¦ one and π₯ two, π¦ two represent the coordinates of the two points on the line. We can think of point π΄ as π₯ one, π¦ one and point π΅ as π₯ two, π¦ two, although it doesnβt actually matter which way round we do this, as long as weβre consistent about the order we subtract for both π₯ and π¦.

So substituting the values for these two coordinates, we have 21 minus 11 for the change in π¦ and 10 minus five for the change in π₯. That gives 10 over five, which is equal to two.

Now, itβs really important to remember that we must divide the change in π¦ by the change in π₯. A really common mistake is to do this the other way round, so to divide the change in π₯ by the change in π¦. But in this case, that would give five over 10, which is equal to a half. We would get the reciprocal of the slope we actually need. The other common mistake is to subtract one set of values in the wrong order. We must make sure that we always subtract in the same order for both π₯ and π¦. If we donβt, weβll end up with the exact negative of the slope we want, which again will be incorrect.

Now that we know the slope of the line is two, we can substitute this value of π into the equation. So we know that the equation of our line is in the form π¦ equals two π₯ plus π. To determine the value of π, we use the fact that each of these points, points capital π΄ and capital π΅, lie on our line, which means we have two pairs of π₯- and π¦-values which must satisfy this equation.

We donβt need to use both of them. Letβs just consider point π΄, which tells us that when π₯ is equal to five, π¦ is equal to 11. We can therefore substitute these values of π₯ and π¦ into our equation π¦ equals two π₯ plus π to enable us to find the value of π. Doing so gives 11 equals two multiplied by five plus π. This is a relatively straightforward equation to solve. Two multiplied by five is 10. And then if we subtract 10 from each side, we find that the value of π is one. So we can substitute this value of π into the equation of our straight line. And we now have that the equation of this line in its general form is π¦ equals two π₯ plus one.

Now, we use the coordinates of point π΄ here. But itβs just worth pointing out we could equally have used the coordinates of point π΅, which tell us that when π₯ is equal to 10, π¦ is equal to 21. We would then have a different equation to solve. But it gives the same solution of π equals one. The equation of the straight line passing through the two given points then is π¦ equals two π₯ plus one.

Letβs now consider a second example using a table of values.

Write the equation of the line that passes through the points indicated in the table of values.

Now, this table is just a different way of presenting the coordinates of two points that lie on the line. Weβre told that when π₯ is equal to three, π¦ is equal to 12. So we have the point three, 12. And when π₯ is equal to seven, π¦ is equal to zero. So we also have the point seven, zero.

We know that the general equation of a straight line is π¦ equals ππ₯ plus π, where π represents the slope and π represents the π¦-intercept. To calculate the slope first of all, we can use the formula change in π¦ over change in π₯. Subtracting the coordinates of our first point from the coordinates of our second then, we have zero minus 12 for the change in π¦ and seven minus three for the change in π₯.

Remember, we must make sure we subtract our coordinates in the same order. We donβt simply subtract the smaller from the larger. This gives negative 12 over four, which simplifies to negative three. So the equation of our line is π¦ equals negative three π₯ plus π, and we need to determine the value of π. To do this, we can use the coordinates of either point as they each lie on the line.

Letβs use the point seven, zero. We substitute seven for π₯ and zero for π¦, giving the equation zero equals negative three multiplied by seven plus π. That simplifies to zero equals negative 21 plus π. And adding 21 to each side, we find that π is equal to 21. We can then substitute this value of π into the equation of our line, and we have our answer. π¦ equals negative three π₯ plus 21.

Sometimes if the values of either the slope π or π¦-intercept π are fractional, it may be preferable to give our answer in an equivalent form that doesnβt involve fractions. For example, suppose we found the equation of a straight line and it was π¦ equals a half π₯ minus four. In order to eliminate the fraction of one-half, we could multiply the entire equation by the denominator of two. If we do this though, we must remember to multiply every single term in the equation by two.

So on the left-hand side, weβd have two π¦. And on the right-hand side, weβd have π₯ minus eight. A really common mistake would be to forget to multiply the constant term by two. The equation of this line is equivalent to π¦ equals a half π₯ minus four, but it doesnβt involve any fractions.

Now, itβs more usual in this instance to give our answers in the form ππ₯ plus ππ¦ plus π equals zero, which just means we group all of the terms on the same side of the equation. And we have zero on the other side. We could do this by subtracting two π¦ from each side of the equation to give the equation π₯ minus two π¦ minus eight is equal to zero. Or equivalently, we could subtract π₯ and add eight to each side to give the equation negative π₯ plus two π¦ plus eight equals zero, which is the exact negative of the previous equation we wrote down.

Another commonly used form is to group the π₯ and π¦ terms on one side of the equation and the constant term on the other. So an example of this would be the equation negative π₯ plus two π¦ equals negative eight. All of these are simply rearrangements of the original equation, so theyβre all equivalent. We just need to make sure we read any questions carefully and give our answers in the required form. Letβs look at an example of this.

Find the equation of the line that passes through the points π΄: negative 10, two and π΅: zero, five, giving your answer in the form of ππ¦ plus ππ₯ plus π is equal to zero.

Now, weβve been asked to find the equation of this straight line in a specific form, with all of the terms on the same side of the equation. But weβll begin by using the general form of the equation of a straight line. Thatβs π¦ equals ππ₯ plus π, where π is the slope of the line and π is its π¦-intercept.

Now, itβs important to be aware here that this value π is not necessarily the same in our general equation and in the requested form. Weβre told that the line passes through the point with coordinates zero, five. So the π¦-intercept of our line is zero, five. And we can work out straightaway that the value π in our general form is five.

To work out the value of π, we can use the formula change in π¦ over change in π₯. Subtracting the coordinates of π΄ from those of π΅, and we have five minus two over zero minus negative 10. We need to be really careful here because we are subtracting a negative value. A common mistake would be to just have zero minus 10 in the denominator. But that wouldnβt actually be subtracting the π₯-coordinate of π΄ from the π₯-coordinate of π΅.

Simplifying, we have three in the numerator. And in the denominator, zero minus negative 10 is zero plus 10, which is 10. So the slope of the line is three-tenths. Substituting the values of π and π into the equation of our straight line then, and we have π¦ equals three-tenths of π₯ plus five.

Now, this isnβt in the required form because weβre asked to collect all the terms on the same side of the equation. And although the question doesnβt explicitly say this, the values of π, π, and π that we use should be integers. We have a fraction of three-tenths. But we can eliminate this by multiplying each side by the denominator of 10. Doing so and remembering we need to multiply every term in the equation, including the constant term, by 10, we get 10π¦ equals three π₯ plus 50. Grouping all the terms on the left-hand side by subtracting three π₯ and subtracting 50 gives the equation 10π¦ minus three π₯ minus 50 equals zero, which is in the requested form.

Alternatively, we couldβve grouped the terms on the other side of the equation, which would give the equivalent form negative 10π¦ plus three π₯ plus 50 equals zero, the exact negative of the equation weβve given.

So in this example, weβve seen how to give the equation of a straight line in an alternative but equivalent form. In our next example, weβll see how we can use knowledge about the π₯- and π¦-intercepts of a straight line to determine its equation.

What is the equation of the line with π₯-intercept negative three and π¦-intercept four?

Letβs begin by considering a sketch of this line. We know its π₯-intercept is negative three and its π¦-intercept is four. So the line looks a little something like this. We can see that this line has a positive slope. So we can use this fact to sense-check our answer.

First, weβll consider the equation of this line in its general form π¦ equals ππ₯ plus π. Now, we can actually work out the value of π straightaway because weβve been given the π¦-intercept explicitly in the question. The value of π is four. So our equation has the form π¦ equals ππ₯ plus four. To calculate the slope π, we can use change in π¦ over change in π₯ or the more casual rise over run.

From our sketch, we can see that the vertical change or the rise is from zero, which will be the π¦-value on the π₯-axis, to four. Thatβs a change of four units. And the horizontal change is from negative three to zero. Thatβs a change of three units. That gives a slope of four-thirds. This value is positive. So this is indeed consistent with our starting sketch.

Substituting the values of π and π into the general equation of our straight line then, and we have π¦ equals four-thirds π₯ plus four. Now, this would be an acceptable form in which to give our answer, but it does involve fractions. And we often prefer to work without fractions. So letβs find an equivalent form.

To eliminate the fractions, we can multiply the entire equation by the denominator of three. Doing so, and we have three π¦ equals four π₯ plus 12. Remember, we must multiply every term by three, including the constant term. Now, this would be an acceptable form in which to give your answer. Or we could choose to collect the π₯ and π¦ terms on one side and leave the constant term on the other. Subtracting four π₯ from each side of the equation, and we have our answer in this form. Three π¦ minus four π₯ is equal to 12.

In our final example, weβll practice finding the equation of a straight line when weβve been given its graph.

Write the equation represented by the graph shown. Give your answer in the form π¦ equals ππ₯ plus π.

We recall firstly that, in the general form of the equation of a straight line π¦ equals ππ₯ plus π, π represents the slope of the line and π represents the π¦-intercept. We need to determine each of these values from the graph. We can see the π¦-intercept of this line straightaway. It crosses the π¦-axis at four. So the value of π is four.

We can calculate the value of π using the formula change in π¦ over change in π₯. And to do this, we need to identify any two points on the graph. Weβve already identified the π¦-intercept. How about we consider the π₯-intercept? Thatβs the point with coordinates negative two, zero. From the graph, we can see that between these two points, the change in π¦ is four units. Itβs a positive change. And the change in π₯ is two units, again a positive change. So the slope is four over two, which is equal to two.

Now, remember, the slope of the line will be the same no matter which points we used to calculate it. We could equally have used the point negative four, negative four or the point one, six. It doesnβt matter. Weβll get the same slope in each case. Finally, we substitute the values of π and π into the general form, giving our answer to the problem. π¦ equals two π₯ plus four.

Letβs now summarize the key points from this video. Firstly, the general equation of a straight line is the form π¦ equals ππ₯ plus π or sometimes π¦ equals ππ₯ plus π, where π represents the slope of the line and π or π represent its π¦-intercept. For this reason, this form is sometimes referred to as slopeβintercept form. The slope π can be calculated either from two points which lie on the line or from a graph using change in π¦ over change in π₯. This can be formalized as π¦ two minus π¦ one over π₯ two minus π₯ one. Or we can think of it more casually as rise over run.

Once weβve found the slope, the π¦-intercept π or π can be found by substituting the coordinates of any point that we know lies on the line. Or it can be found from a graph. To avoid having fractional values, we can also give the equations of straight lines in alternative equivalent forms, such as ππ¦ plus ππ₯ plus π equals zero or ππ¦ plus ππ₯ equals π. Although we need to be careful that weβre aware that the values of π, π, and π will not all be the same between the three different forms.

When answering questions on finding the equations of straight lines, we need to make sure we read the question carefully and always give our answer in the form that has been requested.