Piecewise functions are functions where a different formula or rule applies for different parts of the domain.
Example
In this piecewise function the domain is broken into two parts.
Note that where an "end-point" incudes the sign ≤ or ≥ then a filled-in point is used. If the "end-point" includes the sign > or < then a hollow point is used. |
Step Functions
A special type of piecewise function is called a step function.
The graph of this function is a series of horizontal lines for different parts of the domain.
Example
A taxi company charges according to the schedule below:
Fixed fare |
$6
|
Rate per kilometre (or part) |
$1.50
|
Draw a step function graph showing the total fare for journies of x km for values of x from 0 to 10 km