📊

Piecewise Functions and Absolute Value

Sep 5, 2025

Overview

This lecture explains what piecewise functions are, how to graph them, and highlights the absolute value function as a common example of a piecewise function.

What is a Piecewise Function?

  • A piecewise function is defined by different rules over different intervals of its domain.
  • Unlike standard functions, which have the same rule for all inputs, piecewise functions apply different rules depending on the input value.

Example of a Piecewise Function

  • Example: ( f(x) = 2x ) for ( x \leq 0 ); ( f(x) = 3 ) for ( x > 0 ).
  • For ( x \leq 0 ), output is twice the input (e.g., ( f(-2) = -4 )).
  • For ( x > 0 ), output is always 3.
  • At ( x = 0 ), use the first rule, so ( f(0) = 0 ).

Graphing Piecewise Functions

  • Graph each rule only on its corresponding interval.
  • For ( x \leq 0 ), plot the line ( y = 2x ) up to the origin.
  • For ( x > 0 ), plot the horizontal line ( y = 3 ) starting just right of the origin.
  • Use a solid dot for included endpoints and an open circle for excluded endpoints (e.g., open circle at ( (0, 3) )).

The Absolute Value Function as a Piecewise Function

  • Absolute value, ( |x| ), is defined as ( -x ) for ( x < 0 ) and ( x ) for ( x \geq 0 ).
  • For negative inputs, the output is their positive counterpart (flips the sign).
  • For non-negative inputs, the output is the input itself.
  • The graph of ( |x| ) changes from a line with a negative slope to a line with a positive slope at ( x = 0 ).

Key Terms & Definitions

  • Piecewise Function — A function defined by different expressions over different intervals of its domain.
  • Absolute Value Function — A function that returns a number's distance from zero, expressed as a piecewise function.

Action Items / Next Steps

  • Practice graphing piecewise functions with different rules and intervals.
  • Review the graph of the absolute value function and identify its distinct pieces.