How to add piecewise functions with different breakpoints
Combine all breakpoints first
If two piecewise functions switch formulas at different places, list every breakpoint from both functions. On each resulting interval, choose the applicable formula from each function and add them. Check strict and inclusive inequalities at each breakpoint.
Problem
Let f(x)={5x+3,x2+8x,x<1x≥1 and g(x)={−2x+1,x−6,x≤0x>0. Find (f+g)(x).
Answer
(f+g)(x)=⎩⎨⎧3x+4,6x−3,x2+9x−6,x≤00<x<1x≥1.
Both boundary points use the inclusive branch stated in the original definitions.
Step-by-step solution
1. List breakpoints
The formula for g changes at 0; the formula for f changes at 1. So use three intervals: x≤0, 0<x<1, and x≥1.
2. Add the formulas on each interval
For x≤0, use 5x+3 and −2x+1, giving 3x+4. For 0<x<1, use 5x+3 and x−6, giving 6x−3. For x≥1, use x2+8x and x−6, giving x2+9x−6.
3. Check endpoints
At x=0, g(0)=1, so the first branch gives (f+g)(0)=4. At x=1, f(1)=9 and g(1)=−5, so the third branch gives (f+g)(1)=4.