How do you write #abs(x^2 +x -12)# as a piecewise function?

1 Answer
Jun 25, 2017

Use the definition:
#|A|={(A;A>=0),(-A;A<0):}#
Find the points where the quadratic is zero to simplify the restrictions and add pieces as needed.

Explanation:

Given #y = |x^2 +x -12|#

Use the definition, #|A|={(A;A>=0),(-A;A<0):}#:

#y = {(x^2 +x -12;x^2 +x -12>=0),(-(x^2 +x -12);x^2 +x -12<0):}#

Find the x values for #x^2 +x -12=0#:

Factor:

#(x-3)(x+4)=0#

#x = -4 and x = 3#

This means that #x^2 +x -12 >=0# for #x <= -4# and #x>=3#

Modify the restriction for the first piece to be #x <=-4# and add a third peace with the restriction #x>=3#:

#y = {(x^2 +x -12;x<=-4),(-(x^2 +x -12);x^2 +x -12 < 0),(x^2 +x -12;x>=3):}#

Modify the restriction for the middle piece to be #-4 < x < 3# and distribute the -1

#y = {(x^2 +x -12;x<=-4),(-x^2 -x +12;-4 < x < 3),(x^2 +x -12;x>=3):}#

Here is a graph of #y = |x^2 +x -12|#

Desmos.com

Here is a graph of the piece-wise function

#y = {(x^2 +x -12;x<=-4),(-x^2 -x +12;-4 < x < 3),(x^2 +x -12;x>=3):}#

with each piece in a different color:

Desmos.com