How do you write p(x) = |x-1| +4p(x)=|x1|+4 as a piecewise function?

1 Answer
Sep 7, 2017

p(x)=-x+5 :x in (-oo,1)p(x)=x+5:x(,1)
p(x) = +x+3: x in [1, +oo)p(x)=+x+3:x[1,+)

Explanation:

p(x) =abs(x-1)+4p(x)=|x1|+4

p(x) =-(x-1)+4 =-x+5p(x)=(x1)+4=x+5
where x-1<0 -> x in (-oo, +1)x1<0x(,+1)

p(x) =+(x-1)+4 = +x+3p(x)=+(x1)+4=+x+3
where x-1>=0 -> x in [1, +oo)x10x[1,+)

This can be more easily visualised from the graph pf p(x)p(x) below.

graph{abs(x-1)+4 [-9.96, 10.04, -0.64, 9.36]}