A parking garage charges a flat fee for the first hour and a different hourly rate after that. A tax schedule uses one rate up to some income and another rate above it. These are piecewise functions, one rule for some inputs and another rule for the rest. The whole skill is to look at the input first, decide which rule applies, and only then compute.
Key terms
Piecewise function
Definition A piecewise function is a function defined by several formulas, each paired with a condition on the input. Written out, it looks like
The domain of is the set of inputs that satisfy at least one of the conditions. For the rule to define a function, every input in the domain must receive exactly one output. This holds automatically when the conditions do not overlap. If two conditions overlap, their formulas must give the same value at every input in the overlap.
In plain words It is still one function. It simply uses different instructions on different parts of the number line, and the instructions never contradict each other.
Example The rule
has overlapping conditions at , but both formulas give there, so it defines a function. If the second formula were instead, the input would receive both and , and the rule would not be a function.
Input condition
Definition An input condition is the statement about written next to a formula, such as , or . A formula is used for exactly those inputs that make its condition true. An input that satisfies no condition is not in the domain, even if some formula could be evaluated there.
In plain words The conditions are the gatekeepers. Read them before you look at any formula.
Example For
no condition allows , so is undefined and is not in the domain. The domain is , even though both formulas are constants that could be written down for any input.
Rule selection
Definition To evaluate a piecewise function at an input , first find the condition that satisfies, then substitute into the formula paired with that condition and only that formula. If satisfies no condition, the function has no value at .
In plain words Pick the rule, then plug in. Never plug into a formula whose condition is false for your input.
Example For when and when ,
| Input | Condition it meets | Formula used | Output |
|---|---|---|---|
A common slip is to compute . That uses the wrong rule, because is false.
Branch
Definition A branch of a piecewise function is the part of its graph produced by one formula on the inputs allowed by its condition. The graph of the whole function is the union of its branches. A formula’s curve outside its condition is not part of the graph.
In plain words Each formula contributes only a piece of its usual curve. Draw that piece and stop where the condition stops.
Example For the function above, the first branch is the part of the parabola to the left of , and the second is the part of the line from onward. The rest of the parabola, such as the point , does not belong to the graph. If you sketch the whole parabola lightly as a guide, erase it or keep it clearly separate from the final graph.
Closed and open endpoints
Definition Where a branch ends at an input , the endpoint is included in the graph exactly when the condition includes equality at , as in or . It is drawn as a filled dot, a closed endpoint. When the condition is strict, as in or , the point is not on that branch and is drawn as a hollow dot, an open endpoint.
In plain words Equality in the condition means the dot is filled. Strict inequality means the branch gets as close as you like but leaves a hole.
Example For above, the first branch heads toward , since , but its condition excludes . That gets a hollow dot at . The second branch starts at , since , and its condition includes . That gets a filled dot at . So the graph has exactly one point above , which is , in agreement with .
Switching input
Definition A switching input is a value of where the condition in force changes, so the function stops using one formula and starts using another. At a switching input you check three numbers separately, the value the left formula approaches as from the left, the value the right formula approaches as from the right, and the actual value given by whichever condition includes .
In plain words The switch is where all the interesting behavior happens. Check the boundary on its own rather than trusting the sketch.
Example For above the switching input is . The left formula approaches , the right formula approaches , and the actual value is . These three numbers tell you everything about the graph near .
Matching branch values
Definition The branch values match at a switching input when the left formula and the right formula approach the same number as approaches from their own sides, and that number is also . For polynomial formulas such as these, the number a formula approaches is simply its value at . Then the branches meet at a single point and the graph has no break at . Matching values do not mean the graph is smooth there. The branches can meet at an angle and form a corner.
In plain words If both pieces arrive at the same height and the function’s own value is that height, you can draw through the switch without lifting your pencil.
Example Consider
At the left formula gives and the right formula gives , and . The branches join at , drawn with a single filled dot. They do not join smoothly, though. A chord from to a point on the left branch has slope
which is at and at , so the left branch arrives tilted at a slope near . Every chord on the right branch has slope . The two sides meet at different steepness, so the graph has a corner at , which is a different issue from a break.
Jump
Definition A piecewise function has a jump at a switching input when the left branch approaches one number and the right branch approaches a different number . The size of the jump is . At a jump the graph breaks, and at most one of the two endpoint heights can be the actual value .
In plain words The two pieces arrive at different heights, so the pencil has to lift and move up or down.
Example For when and when , the left branch approaches and the right branch approaches . The jump has size . The graph shows a hollow dot at and a filled dot at . In calculus this is exactly the situation where the two one-sided limits exist but differ, so the two-sided limit at does not exist.
Check yourself
- Let when , when , and when . Find , , and .
Show the answer
The input meets , so . The input meets , so . Both and meet , so and .
- For the function in the first question, describe what happens at each switching input. Is there a jump, and which dots are filled?
Show the answer
At the left formula gives and the right formula approaches . That is a jump of size , with a filled dot at and a hollow dot at . At the middle formula approaches and the right branch starts at . That is a jump of size , with a hollow dot at and a filled dot at .
- Find the constant that makes the branch values match at for the function equal to when and to when .
Show the answer
The right branch gives at , and this is also the value of the function there. The left formula gives at . Setting gives