Skip to main content
Mathematics LibreTexts

5.3.3: Piecewise Linear Functions

  • Page ID
    36033
  • \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

    \( \newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\)

    ( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\)

    \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)

    \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\)

    \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)

    \( \newcommand{\Span}{\mathrm{span}}\)

    \( \newcommand{\id}{\mathrm{id}}\)

    \( \newcommand{\Span}{\mathrm{span}}\)

    \( \newcommand{\kernel}{\mathrm{null}\,}\)

    \( \newcommand{\range}{\mathrm{range}\,}\)

    \( \newcommand{\RealPart}{\mathrm{Re}}\)

    \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)

    \( \newcommand{\Argument}{\mathrm{Arg}}\)

    \( \newcommand{\norm}[1]{\| #1 \|}\)

    \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)

    \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\AA}{\unicode[.8,0]{x212B}}\)

    \( \newcommand{\vectorA}[1]{\vec{#1}}      % arrow\)

    \( \newcommand{\vectorAt}[1]{\vec{\text{#1}}}      % arrow\)

    \( \newcommand{\vectorB}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vectorC}[1]{\textbf{#1}} \)

    \( \newcommand{\vectorD}[1]{\overrightarrow{#1}} \)

    \( \newcommand{\vectorDt}[1]{\overrightarrow{\text{#1}}} \)

    \( \newcommand{\vectE}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash{\mathbf {#1}}}} \)

    \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

    Lesson

    Let's explore functions built out of linear pieces.

    Exercise \(\PageIndex{1}\): Notice and Wonder: Lines on Dots

    What do you notice? What do you wonder?

    clipboard_e7f9a94d2b40e7e4f34b29692dfa1ee12.png
    Figure \(\PageIndex{1}\): Scatterplot, horizontal, time in hours after midnight, 0 to 12 by ones, vertical, temperature in degrees Fahrenheit. Fifty points approximate a straight line from point 2 5 comma 50 increasing to 5 point 75 comma 59 and then decreasing from there to 12 comma 52 point 5.

    Exercise \(\PageIndex{2}\): Modeling Recycling

    clipboard_ed4480f0f6907389c447daafbdc6d9956.png
    Figure \(\PageIndex{2}\): A scatterplot, horizontal, year, 1900 to 2015 by fives, vertical, percentage recycled, 15 % to 27 % by threes. Beginning with 1991 comma 16%, points trend linearly upward to 1996 comma 22%, then linearly upward at a less steep rate to 2011 comma 26 %, then two points trend down.
    1. Approximate the percentage recycled each year with a piecewise linear function by drawing between three and five line segments to approximate the graph.
    2. Find the slope for each piece. What do these slopes tell you?

    Exercise \(\PageIndex{3}\): Dog Bath

    Elena filled up the tub and gave her dog a bath. Then she let the water out of the tub.

    clipboard_ed4cdcda301bc0d5f84c8233ca2a725e1.png
    Figure \(\PageIndex{3}\)
    1. The graph shows the amount of water in the tub, in gallons, as a function of time, in minutes. Add labels to the graph to show this.
    2. When did she turn off the water faucet?
    3. How much water was in the tub when she bathed her dog?
    4. How long did it take for the tub to drain completely?
    5. At what rate did the faucet fill the tub?
    6. At what rate did the water drain from the tub?

    Exercise \(\PageIndex{4}\): Distance and Speed

    clipboard_e24632f5575ee0c0385ca7f939bd3b0b2.png
    Figure \(\PageIndex{4}\)

    The graph shows the speed of a car as a function of time. Describe what a person watching the car would see.

    Are you ready for more?

    The graph models the speed of a car over a function of time during a
    3-hour trip. How far did the car go over the course of the trip?

    There is a nice way to visualize this quantity in terms of the graph. Can you find it?

    clipboard_e48a780cb4035f60c5fe69084abd8cc11.png
    Figure \(\PageIndex{5}\): Coordinate plane, horizontal axis, time in minutes, 0 to 180 by fifteens. Vertival axis, speed in miles per hour, 0 to 80 by tens. A segment from closed circle at ( 0 comma 20 ) to open circle at ( 0 comma 60 ). segment from closed circle at ( 60 comma 30 ) to open circle at ( 90 comma 30 ). Segment from closed circle at ( 90 comma 50 ) to open circle at ( 120 comma 50 ). Segment from closed circle at ( 120 comma 40 ) to open circle at ( 135 comma 40 ). Segment from closed circle at ( 135 comma 20 ) to open circle ( 150 comma 20 ). Segment from closed circle ( 150 comma 10 ) to open circle at ( 180 comma 10 ).

    Summary

    This graph shows Andre biking to his friend’s house where he hangs out for a while. Then they bike together to the store to buy some groceries before racing back to Andre’s house for a movie night. Each line segment in the graph represents a different part of Andre’s travels.

    clipboard_e8400649e3ada714ac70ab57b3cdeba34.png
    Figure \(\PageIndex{6}\): Graph composed of 5 linear sections. Horizontal axis, time, vertical axis, distance from home. Beginning at the origin, first segment slopes up as it moves right. Second segment horizontal, third segment slopes up and right, more steeply than the first segment. Fourth segment horizontal, fifth segment slopes down and right back to the horizontal axis.

    This is an example of a piecewise linear function, which is a function whose graph is pieced together out of line segments. It can be used to model situations in which a quantity changes at a constant rate for a while, then switches to a different constant rate.

    We can use piecewise functions to represent stories, or we can use them to model actual data. In the second example, temperature recordings at several times throughout a day are modeled with a piecewise function made up of two line segments. Which line segment do you think does the best job of modeling the data?

    clipboard_e5154e365d19860dd005842da874a87b1.png
    Figure \(\PageIndex{7}\): Scatterplot, horizontal, time in hours after midnight, 0 to 12 by ones, vertical, temperature in degrees Fahrenheit. Fifty points approximate a straight line from point 2 5 comma 50 increasing to 5 point 75 comma 59 and then decreasing from there to 12 comma 52 point 5.

    Practice

    Exercise \(\PageIndex{5}\)

    The graph shows the distance of a car from home as a function of time.

    clipboard_e358f346337778b3609cbb00dbe70dd78.png
    Figure \(\PageIndex{8}\)

    Describe what a person watching the car may be seeing.

    Exercise \(\PageIndex{6}\)

    The equation and the graph represent two functions. Use the equation \(y=4\) and the graph to answer the questions.

    clipboard_e04d90301a534ca257d33d33abd9df6a2.png
    Figure \(\PageIndex{9}\)
    1. When \(x\) is 4, is the output of the equation or the graph greater?
    2. What value for \(x\) produces the same output in both the graph and the equation?

    (From Unit 5.2.5)

    Exercise \(\PageIndex{7}\)

    This graph shows a trip on a bike trail. The trail has markers every 0.5 km showing the distance from the beginning of the trail.

    clipboard_e3111d33f59200e6e3663506f9d4905db.png
    Figure \(\PageIndex{10}\): Coordinate plane, x, time in hours, 0 to 3 point 4 by point 2, y, distance from beginning in kilometers, 0 to 10 by 2. Line segments connecting the origin and (point 8 comma 8), (1 point 4 comma 8), (2 point 2 comma 10), (2 point 4 comma 10), (2 point 6 comma 5), (3 comma 0).
    1. When was the bike rider going the fastest?
    2. When was the bike rider going the slowest?
    3. During what times was the rider going away from the beginning of the trail?
    4. During what times was the rider going back towards the beginning of the trail?
    5. During what times did the rider stop?

    Exercise \(\PageIndex{8}\)

    The expression \(-25t+1250\) represents the volume of liquid of a container after \(t\) seconds. The expression \(50t+250\) represents the volume of liquid of another container after \(t\) seconds. What does the equation \(-25t+1250=50t+250\) mean in this situation?

    (From Unit 4.2.8)


    This page titled 5.3.3: Piecewise Linear Functions is shared under a CC BY license and was authored, remixed, and/or curated by Illustrative Mathematics.

    • Was this article helpful?