### Learning Objectives

In this section you will:

### 2.4.1 – Finding a Linear Equation

#### The Point-Slope Formula

Given the slope and one point on a line, we can find the equation of the line using the point-slope formula.

$y-{y}_{1}=m\left(x-{x}_{1}\right)$

This is an important formula, as it will be used in other areas of college algebra and often in calculus to find the equation of a tangent line. We need only one point and the slope of the line to use the formula. After substituting the slope and the coordinates of one point into the formula, we simplify it and write it in slope-intercept form.

### The Point-Slope Formula

Given one point and the slope, the point-slope formula will lead to the equation of a line:

$y-{y}_{1}=m\left(x-{x}_{1}\right)$

### Example 1 – Finding the Equation of a Line Given the Slope and One Point

Write the equation of the line with slope $\,m=-3\,$ and passing through the point $\,\left(4,8\right).\,$ Write the final equation in slope-intercept form.

Using the point-slope formula, substitute $\,-3\,$ for m and the point $\,\left(4,8\right)\,$ for $\,\left({x}_{1},{y}_{1}\right).$

$\begin{array}{ccc}\hfill y-{y}_{1}& =& m\left(x-{x}_{1}\right)\hfill \\ \hfill y-8& =& -3\left(x-4\right)\hfill \\ \hfill y-8& =& -3x+12\hfill \\ \hfill y& =& -3x+20\hfill \end{array}$

#### Analysis

Note that any point on the line can be used to find the equation. If done correctly, the same final equation will be obtained.

### Try It

Given $\,m=4,$ find the equation of the line in slope-intercept form passing through the point $\,\left(2,5\right).$

$y=4x-3$

### Example 2 – Finding the Equation of a Line Passing Through Two Given Points

Find the equation of the line passing through the points $\,\left(3,4\right)\,$ and $\,\left(0,-3\right).\,$ Write the final equation in slope-intercept form.

First, we calculate the slope using the slope formula and two points.

$\begin{array}{ccc}\hfill m& =& \frac{-3-4}{0-3}\hfill \\ & =& \frac{-7}{-3}\hfill \\ & =& \frac{7}{3}\hfill \end{array}$

Next, we use the point-slope formula with the slope of $\,\frac{7}{3},$ and either point. Let’s pick the point $\,\left(3,4\right)\,$ for $\,\left({x}_{1},{y}_{1}\right).$

$\begin{array}{ccc}\hfill y-4& =& \frac{7}{3}\left(x-3\right)\hfill \\ \hfill y-4& =& \frac{7}{3}x-7\phantom{\rule{2em}{0ex}}\text{Distribute the }\frac{7}{3}.\hfill \\ \hfill y& =& \frac{7}{3}x-3\hfill \end{array}$

In slope-intercept form, the equation is written as $\,y=\frac{7}{3}x-3.$

#### Analysis

To prove that either point can be used, let us use the second point $\,\left(0,-3\right)\,$ and see if we get the same equation.

$\begin{array}{ccc}\hfill y-\left(-3\right)& =& \frac{7}{3}\left(x-0\right)\hfill \\ \hfill y+3& =& \frac{7}{3}x\hfill \\ \hfill y& =& \frac{7}{3}x-3\hfill \end{array}$

We see that the same line will be obtained using either point. This makes sense because we used both points to calculate the slope.

### 2.4.2 – Writing and Interpreting an Equation for a Linear Function

Now that we know both the slope-intercept form and point-slope form of a line, we can choose which form to use to write equations for linear functions based on the information we are given. That information may be provided in the form of a graph, a point and a slope, two points, and so on. Look at the graph of the function $\,f\,$ in Figure 1.

We are not given the slope of the line, but we can choose any two points on the line to find the slope. Let’s choose $\,\left(0,7\right)\,$ and $\,\left(4,4\right).\,$

$\begin{array}{ccc}\hfill m& =& \frac{{y}_{2}-{y}_{1}}{{x}_{2}-{x}_{1}}\hfill \\ & =& \frac{4-7}{4-0}\hfill \\ & =& -\frac{3}{4}\hfill \end{array}$

Now we can substitute the slope and the coordinates of one of the points into the point-slope form.

$\begin{array}{ccc}\hfill y-{y}_{1}& =& m\left(x-{x}_{1}\right)\hfill \\ \hfill \text{ }y-4& =& -\frac{3}{4}\left(x-4\right)\hfill \end{array}$

If we want to rewrite the equation in the slope-intercept form, we would find

$\begin{array}{ccc}\hfill y-4& =& -\frac{3}{4}\left(x-4\right)\hfill \\ \hfill y-4& =& -\frac{3}{4}x+3\hfill \\ \hfill y& =& -\frac{3}{4}x+7\hfill \end{array}$

If we want to find the slope-intercept form without first writing the point-slope form, we could have recognized that the line crosses the y-axis when the output value is 7. Therefore, $\,b=7.\,$ We now have the initial value $\,b\,$ and the slope $\,m\,$ so we can substitute $\,m\,$ and $\,b\,$ into the slope-intercept form of a line.

So the function is $f\left(x\right)=-\frac{3}{4}x+7,$ and the linear equation would be $\,y=-\frac{3}{4}x+7.$

### How To

Given the graph of a linear function, write an equation to represent the function.

1. Identify two points on the line.
2. Use the two points to calculate the slope.
3. Determine where the line crosses the y-axis to identify the y-intercept by visual inspection.
4. Substitute the slope and y-intercept into the slope-intercept form of a line equation.

### Example 3 – Writing an Equation for a Linear Function

Write an equation for a linear function given a graph of $\,f\,$ shown in Figure 2.

Identify two points on the line, such as $\,\left(0,2\right)\,$ and $\,\left(-2,-4\right).\,$ Use the points to calculate the slope.

$\begin{array}{ccc}\hfill m& =& \frac{{y}_{2}-{y}_{1}}{{x}_{2}-{x}_{1}}\hfill \\ & =& \frac{-4-2}{-2-0}\hfill \\ & =& \frac{-6}{-2}\hfill \\ & =& 3\hfill \end{array}$

Substitute the slope and the coordinates of one of the points into the point-slope form.

$\begin{array}{ccc}\hfill y-{y}_{1}& =& m\left(x-{x}_{1}\right)\hfill \\ \hfill y-\left(-4\right)& =& 3\left(x-\left(-2\right)\right)\hfill \\ \hfill y+4& =& 3\left(x+2\right)\hfill \end{array}$

We can use algebra to rewrite the equation in the slope-intercept form.

$\begin{array}{ccc}\hfill y+4& =& 3\left(x+2\right)\hfill \\ \hfill y+4& =& 3x+6\hfill \\ \hfill y& =& 3x+2\hfill \end{array}$

#### Analysis

This makes sense because we can see from Figure 3 that the line crosses the y-axis at the point $\,\left(0,\text{ }2\right),\,$ which is the y-intercept, so $\,b=2.$

### Example 4 – Writing an Equation for a Linear Cost Function

Suppose Ben starts a company in which he incurs a fixed cost of $1,250 per month for the overhead, which includes his office rent. His production costs are$37.50 per item. Write a linear function $\,C\,$ where $\,C\left(x\right)\,$ is the cost for $\,x\,$ items produced in a given month.

The fixed cost is present every month, $1,250. The costs that can vary include the cost to produce each item, which is$37.50. The variable cost, called the marginal cost, is represented by $\,37.5.\,$ The cost Ben incurs is the sum of these two costs, represented by $\,C\left(x\right)=1250+37.5x.$

#### Analysis

If Ben produces 100 items in a month, his monthly cost is found by substituting 100 for $\,x.$

$\begin{array}{ccc}\hfill C\left(100\right)& =& 1250+37.5\left(100\right)\hfill \\ & =& 5000\hfill \end{array}$

So his monthly cost would be \$5,000.

### Example 5 – Writing an Equation for a Linear Function Given Two Points

If $\,f\,$ is a linear function, with $\,f\left(3\right)=-2,$ and $\,f\left(8\right)=1,$ find an equation for the function in slope-intercept form.

We can write the given points using coordinates.

$\begin{array}{ccc}\hfill f\left(3\right)& =& -2\to \left(3,-2\right)\hfill \\ \hfill f\left(8\right)& =& 1\to \left(8,1\right)\hfill \end{array}$

We can then use the points to calculate the slope.

$\begin{array}{ccc}\hfill m& =& \frac{{y}_{2}-{y}_{1}}{{x}_{2}-{x}_{1}}\hfill \\ & =& \frac{1-\left(-2\right)}{8-3}\hfill \\ & =& \frac{3}{5}\hfill \end{array}$

Substitute the slope and the coordinates of one of the points into the point-slope form.

$\begin{array}{ccc}\hfill y-{y}_{1}& =& m\left(x-{x}_{1}\right)\hfill \\ \hfill y-\left(-2\right)& =& \frac{3}{5}\left(x-3\right)\hfill \end{array}$

We can use algebra to rewrite the equation in the slope-intercept form.

$\begin{array}{ccc}\hfill y+2& =& \frac{3}{5}\left(x-3\right)\hfill \\ \hfill y+2& =& \frac{3}{5}x-\frac{9}{5}\hfill \\ \hfill y& =& \frac{3}{5}x-\frac{19}{5}\hfill \end{array}$

### Try It

If $\,f\left(x\right)\,$ is a linear function, with $\,f\left(2\right)=–11,$ and $\,f\left(4\right)=-25,$ write an equation for the function in slope-intercept form.

$y=-7x+3$

Access this online resource for additional instruction and practice with point-slope form.

### Key Concepts

• We can find the equation of a line given the slope and a point. See Example 1.
• We can also find the equation of a line given two points. Find the slope and use the point-slope formula. See Example 2.
• An equation for a linear function can be written from a graph. See Example 3.
• The equation for a linear function can be written if the slope $\,m\,$ and initial value $\,b\,$ are known. See Example 4 and Example 5.

### Glossary

point-slope form
the equation for a line that represents a linear function of the form $\,y-{y}_{1}=m\left(x-{x}_{1}\right)$