# A 3-mile cab ride costs $3.00. A 6-Mile cab ride costs$4.80. How do you find a linear equation that models cost (c) as a function of distance (d)?

Oct 7, 2017

$c = 0.6 d + 1.2$

#### Explanation:

The $3$ mile cab ride includes a basic charge as well as the cost for the distance covered.

For a $6$ mile trip, the cost is $4.80 which means that : The cost of $3$miles is $4.80-$3.00 =$1.80

Therefore the cost for $1$ mile is $1.80div3=$0.60

The basic fee for hiring the cab is $3.00-$1.80 = $1.20 So the total cost, $c$for a trip of $d$miles will be: $c = 0.6 d + 1.2$Check: If $d = 3$$c = 0.6 \left(3\right) + 1.2 = 3$If $d = 6$$c = 0.6 \left(6\right) + 1.2 = 4.8$Oct 7, 2017 #### Answer: Use $m = \frac{{c}_{2} - {c}_{1}}{{d}_{2} - {d}_{1}}$with the two given points to find the slope $m$. Plug this slope $m$(along with one of the points) into ${c}_{0} = m {d}_{0} + b$to find the intercept $b$. #### Explanation: Our goal is an equation of the form $c = m d + b$. The given data says that when our input (distance) is 3 miles, our output (cost) is$3.00. This gives us the data point $\left({d}_{1} , {c}_{1}\right) = \left(3 , 3\right) .$ Similarly, since a 6-mile cab ride costs $4.80, this gives us the data point $\left({d}_{2} , {c}_{2}\right) = \left(6 , 4.8\right)$. If our model is linear (which we are told it is), then these two points must be on the line. And two points is all we need to define a line, so these two points can help us write the equation for this linear model. Step 1: Use $m = \frac{{c}_{2} - {c}_{1}}{{d}_{2} - {d}_{1}}$to find the rate $m$that the cab charges per mile. For any two points, the slope of the line between them is the ratio of "how far the points are from each other vertically" to "how far they are from each other horizontally". In other words, rise over run. In this question, since cost is modeled as a function of distance, cost will be plotted along the vertical axis (rise), and distance will be along the horizontal axis (run). $m = \frac{{c}_{2} - {c}_{1}}{{d}_{2} - {d}_{1}} = \frac{4.8 - 3}{6 - 3}$$\textcolor{w h i t e}{m = \frac{{c}_{2} - {c}_{1}}{{d}_{2} - {d}_{1}}} = \frac{1.8}{3} \text{ } = 0.6$So for each extra mile we travel, the cost will go up by$0.60.

Step 2: Use ${c}_{0} = m {d}_{0} + b$ to find the base cost $b$ for each cab ride.

Knowing that the cost per mile is $0.60, we can use this with one of the given data points to find the base charge $b$. I'll pick the point $\left(3 , 3\right)$, but it would also work to use $\left(6 , 4.8\right) .$$\text{ "c_0" } = m \left({d}_{0}\right) + b$$\text{  "3" } = 0.6 \left(3\right) + b$$\text{  "3" "="  "1.8"   } + b$$1.2 = \text{               } b$So each cab ride starts with a base charge of$1.20.

Step 3: Place the known values for $m$ and $b$ into the general equation $c = m d + b .$

We now have enough information to write a formula for the cost $c$ as a function of distance $d$:

$c = m d + b$

becomes

c=0.6d+1.2" "or" "c=$0.60d+$1.20

In other words, the cost $c$ of a cab ride is the cost per mile ($0.60) times the number of miles $d$, plus the base charge of$1.20.