# Finding the equation of a straight line - Examples, Exercises and Solutions

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

We can find the linear equation in $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\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$
• For perpendicular lines, the slopes have the relationship $m1\times m2=-1$

## Practice Finding the equation of a straight line

### Exercise #1

Find the equation of the line passing through the two points $(5,0),(\frac{1}{2},4\frac{1}{2})$

### Step-by-Step Solution

First, we will use the formula to find the slope of the straight line:

We replace the data and solve:

$\frac{(0-4.5)}{(5-0.5)}=\frac{-4.5}{4.5}=-1$

Now, we know that the slope is $-1$

We replace one of the points in the formula of the line equation:

$y=mx+b$

$(5,0)$

$0=-1\times5+b$

$0=-5+b$

$b=5$

Now we have the data to complete the equation:

$y=-1\times x+5$

$y=-x+5$

$y+x=5$

### Exercise #2

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

### Video Solution

$y=3x$

### Exercise #3

Find the equation of the line passing through the two points $(\frac{1}{3},1),(-\frac{1}{3},2)$

### Video Solution

$y=-\frac{3}{2}x+1\frac{1}{2}$

### Exercise #4

Find the equation of the line passing through the two points $(9,10),(99,100)$

### Video Solution

$y=x+1$

### Exercise #5

Find the equation of the line passing through the two points $(2,8),(6,1)$

### Video Solution

$y=-1\frac{3}{4}x+11\frac{1}{2}$

### Exercise #1

Find the equation of the line passing through the two points $(12,40),(2,10)$

### Video Solution

$y-4=3x$

### Exercise #2

Find the equation of the line passing through the two points $(15,36),(5,16)$

### Video Solution

$y=2x+6$

### Exercise #3

Find the equation of the line passing through the two points $(5,-11),(1,9)$

### Video Solution

$y+5x=14$

### Exercise #4

Straight line passes through the point $(-5,12)$ and parallel to the line $5y-5x=15$

### Video Solution

$y-x=17$

### Exercise #5

Straight line passes through the point $(-2,-13)$ and parallel to the line $-4+y=5x-6$

### Video Solution

$y=5x-3$

### Exercise #1

Straight line passes through the point $(6,14)$ and parallel to the line $x+3y=4x+9$

### Video Solution

$y=x+8$

### Exercise #2

Straight line passes through the point $(0,1)$ and parallel to the line $2(y+1)=16x$

### Video Solution

$y-8x=1$

### Exercise #3

Two lines haves slopes of -3 and -6.

Which of the lines forms a greater angle with the x axis?

### Video Solution

The line whose slope is -3 forms the greater angle.

### Exercise #4

Two lines have slopes of $-6$ and $\frac{1}{2}$.

Which of the lines forms a smaller angle with the x-axis?

### Video Solution

The line with a slope of $\frac{1}{2}$

### Exercise #5

Two straight lines have slopes of$2,\frac{1}{2}$.

Which of the lines forms a larger angle with the x axis?