# Real-life graphs

## In a nutshell

Graphs can be used to represent a number of real-life scenarios and relationships. Straight line graphs show a relationship with a constant change, and the gradient of the line or line segment represents the rate of change.

## Real-life graphs

##### Example 1

*Consider the following graph:*

*The graph tracks distance travelled against time. Read off the graph to find the distance travelled from the start in two hours.*

*Since time is on the $x$-axis, read off from $x=2$ to find the corresponding $y$-coordinate on the graph. Going up from $x=2$ until you meet the line, then going across until you meet the $y$-axis, you will find that this corresponding $y$-coordinate is $100$. Hence, in the first two hours, $\underline{100\text{ km}}$ has been covered.*

## Gradients

The gradient of any line segment represents the rate at which the $y$-variable changes with respect to the $x$-variable. This rate of change essentially means that as the $x$-variable increases by one, the $y$-variable will increase by the value of the gradient. **Note: ***if the gradient is negative, then the $y$-variable decreases as the $x$-variable increases.*

Some rates of change will be familiar to you: the rate of change of distance with respect to time is known as speed. The rate of change of speed with respect to time is known as acceleration.

##### Example 2

*According to this graph, find the speed of the motion between hour two and hour three.*

*In a distance-time graph, the gradient gives the speed. The gradient between hour two and hour three is found by using the coordinates on the graph when time is *$2$* and when time is *$3$*:*

$\text{speed}=\frac{\text{change in }y}{\text{change in }x}$

$=\frac{4-2}{2-3}$**

$=\frac{2}{-1}$**

$=-2$

*Thus the speed is *$\underline{-2}$**__ kilometres per hour__. Strictly speaking, this is velocity, since the negative indicates a direction. What this means is that the speed is $2$* kilometres per hour but back in the direction toward the start position.*

Horizontal lines indicate no change since the gradient is zero.

## Plotting a real-life graph

You can plot a real-life graph if you are given information about the scenario.

##### Example 3

*A bathtub is full once the depth is at $40$ cm. The bath starts empty and the tap is run for $15$ minutes such that the water runs at a constant rate. Once the depth reaches $25$ cm, the tap is turned down such that the water is running at a lower, but still constant, rate. The tap runs at this state for $10$ minutes until the depth of the water is at $35$ cm. The tap is then turned off for $5$ minutes. For the following $5$ minutes, the tap is still off, but also water is let out of the bath until the depth is $30$ cm. Finally, the tap is turned on for another $10$ minutes until it is full (at a depth of $40$ cm). Draw a graph that reflects this scenario.*

*This graph will have time in minutes on the $x$-axis and water depth in cm on the $y$-axis. It will be made up of line segments (since each stage has a consistent flow of water) that join the points $(0,0)$ to $(15,25)$ to $(25,35)$ to $(30,35)$ to $(35,30)$ to $(45,40)$*: