Finding a Linear Equation

πŸ†Practice finding the equation of a straight line

Finding a linear equation is actually about graphing the linear function using y=mx+b y=mx+b or y=mx y=mx .

We can find the linear equation in 5 5 ways:

  • Using a point on the line and the slope of the line.
  • Using two points that lie on the line.
  • Using the graph of the function itself.
  • Using parallel lines, that is, if the requested line is parallel to another line and we know the slope of the other line.
  • Using perpendicular lines, that is, if the requested line is perpendicular to another line and we know the slope of the other line.

The first three methods are based in one way or another on the general formula for finding the linear equation:

yβˆ’y1=mΓ—(xβˆ’x1) y-y1=m\times\left(x-x1\right)

The last two methods also use this formula, but they also take into account two additional rules:

  • For parallel lines, the slopes are equal, that is m1=m2 m1=m2
  • For perpendicular lines, the slopes have the relationship m1Γ—m2=βˆ’1 m1\times m2=-1
Start practice

Test yourself on finding the equation of a straight line!

einstein

Find the equation of the line passing through the two points \( (-2,-6),(4,12) \)

Practice more now

Find the Linear Equation

The first method: using the slope and the point.

We substitute into the linear equation y=mx+b y=mx+b
The given slope m m and the values of the given point. This is how we will find b b and can determine the linear equation.

Example

Given a point through which the line passes: (2,4) \left(2,4\right) and the slope: βˆ’2 -2
Find the linear equation.

Solution:

We substitute the slope and the given point into the linear equation:
4=βˆ’2Γ—2+b 4=-2\times2+b

We obtain:
4=βˆ’4+b 4=-4+b
To find b b Β 
b=8 b=8

Now, we have both the slope given in the question and b b .
We can determine that the linear equation is:
y=βˆ’2x+8 y=-2x+8


Join Over 30,000 Students Excelling in Math!
Endless Practice, Expert Guidance - Elevate Your Math Skills Today
Test your knowledge

The second method: using the colon

In this way, we'll first find the slope using 2 2 points according to the formula.
After that, we'll find the linear equation using the first form (by the slope and a point)
The formula to find the slope using 2 2 points is:

m=(Y2βˆ’Y1)(X2βˆ’X1) m=\frac{\left(Y2-Y1\right)}{\left(X2-X1\right)}


Example

Given the following two points through which the line passes:
(3,7),(6,1) \left(3,7\right),\left(6,1\right)
Find the linear equation.

Solution:
First, find the slope using the formula. Replace the given points and you will get:

m=1βˆ’76βˆ’3 m=\frac{1-7}{6-3}

m=βˆ’63 m=\frac{-6}{3}

m=βˆ’2 m=-2

Now that we have found the slope, we can use the point-slope form. We will choose a point from the given ones and place the slope and the chosen point into the linear equation template.

We obtain:

7=βˆ’2Γ—3+b 7=-2\times3+b

7=βˆ’6+b 7=-6+b

b=13 b=13

Now, we have both the slope we found and b b , and we can determine that the linear equation is:
y=βˆ’2x+13 y=-2x+13


Do you know what the answer is?

The third method: using parallel lines

When you are given a parallel line to another line you are looking for, you should know that the slope of the parallel line is the same as the slope of the line you are looking for. Therefore, you can take the slope of the parallel line and assume it is the slope of the line you are seeking. Pay attention: you can identify the slope only in an explicit equation where Y is isolated, stands alone on one side of the equation, and its coefficient is 1 1 .

Usually, you will be given a point and then you can find the linear equation using a point and a slope
(the point-slope form).


Example

Find the linear equation that passes through the point: (6,5) \left(6,5\right) and is parallel to the line y=3xβˆ’7 y=3x-7

Solution:

We are given that the line is parallel to the line y=3xβˆ’7 y=3x-7 .
This information tells us that the slope of our line is the same as the slope of the corresponding line, and therefore the slope of the equation of the line we are looking for is 3 3 .
Now, we have the slope 3 3 and the point 5,6 5,6 .
By substituting into the linear equation formula, we will find b b and thus we will find the linear equation (the first form).

Pay attention!
We easily extracted the slope since the equation of the parallel line is given explicitly with Y Y on one side of the equation and its coefficient is 1 1 .
If we are given an equation that is not in the explicit form, like this one for example: 5=3y+6 5=3y+6
We need to get to an explicit equation: to isolate Y Y completely and only then identify the slope.


Check your understanding

The Fourth Method: Using Perpendicular Lines

The product of the slopes of perpendicular lines isβˆ’1 -1 .
Therefore, when we are given a line perpendicular to the line we are looking for, we know that the product of the two slopes is βˆ’1 -1 and this is how we will find the slope.


Example

The requested line is perpendicular to the line y=2xβˆ’6 y=2x-6
What is the slope of the required line?

Solution:
Define the slope of the requested line as mm .
Since both lines are perpendicular, we can derive the slope of the perpendicular line βˆ’2 -2
and write the equation where the product of the two slopes is equal to βˆ’1 -1 :

We obtain:

2Γ—m=βˆ’1 2\times m=-1

Find mm :
m=βˆ’0.5 m=-0.5

The slope of the required line is βˆ’0.5 -0.5 .
Now, we will find the equation of the line based on the slope and the given point.

Note:

Here too, it is important to first observe what the equation of the perpendicular line expresses.

Do you think you will be able to solve it?

The Fifth Method: Using the Graph

When you're given the graph of a function, you can find the linear equation.
First, choose 22 points on the graph.
This way, you'll find the slope of the function (according to the second method).
Then, find the linear equation based on any point you choose, which the straight line passes through, and of course, the slope you found (the first method).


Example of Finding a Linear Equation

Given two pairs of lines:

Y=3X+2 Y=3X+2

Y=3Xβˆ’5 Y=3X-5

Y=2Xβˆ’6 Y=2X-6

Y=βˆ’0.5X+9 Y=-0.5X+9

The first pair is a pair of parallel lines because the slopes m1=m2=3 m1=m2=3 are equal.

The second pair is a pair of perpendicular lines because their slopes satisfy 2Γ—βˆ’0.5=βˆ’1 2\times-0.5=-1 . That is, m1Γ—m2=βˆ’1 m1\times m2=-1


Test your knowledge
Start practice