Piecewise Defined Functions

advertisement
Piecewise Defined Functions
Most of the functions that we’ve looked at this semester can be expressed
p
as a single equation. For example, f (x) = 3x2 5x + 2, or g(x) = x 1,
or h(x) = e3x 1.
Sometimes an equation can’t be described by a single equation, and instead
we have to describe it using a combination of equations. Such functions are
called piecewise defined functions, and probably the easiest way to describe
them is to look at a couple of examples.
First example. The function g : R ! R is defined by
8
2
>
1 if x 2 ( 1, 0];
<x
g(x) = x 1
if x 2 [0, 4];
>
:3
if x 2 [4, 1).
The function g is a piecewise defined function. It is defined using three
functions that we’re more comfortable with: x2 1, x 1, and the constant
function 3. Each of these three functions is paired with an interval that
appears on the right side of the same line as the function: ( 1, 0], and [0, 4],
and [4, 1) respectively.
If you want to find g(x) for a specific number x, first locate which of the
three intervals that particular number x is in. Once you’ve decided on the
correct interval, use the function that interval is paired with to determine
g(x).
If you want to find g(2), first check that 2 2 [0, 4]. Therefore, we should
use the equation g(x) = x 1, because x 1 is the function that the interval
[0, 4] is paired with. That means that g(2) = 2 1 = 1.
To find g(5), notice that 5 2 [4, 1). That means we should be looking at
the third interval used in the definition of g(x), and the function paired with
that interval is the constant function 3. Therefore, g(5) = 3.
Let’s look at one more number. Let’s find g(0). First we have to decide
which of the three intervals used in the definition of g(x) contains the number
0. Notice that there’s some ambiguity here because 0 is contained in both the
interval ( 1, 0] and in the interval [0, 4]. Whenever there’s ambiguity, choose
either of the intervals that are options. Either of the functions that these
intervals are paired with will give you the same result. That is, 02 1 = 1
is the same number as 0 1 = 1, so g(0) = 1.
228
5
9~;
~!
I
e
To
graph
g(x),
graph
each
of
the
pieces
ofg.g.
g.That
Thatis,is,
is,graph
graphgggg: :(:: ((( 1,
⇤,0]0]
0]!
⇥RR
R
To
graph
g(x),
graph
each
the
pieces
That
graph
⇤,
⇥
Tograph
graphg(x),
g(x),graph
grapheach
eachofof
ofthe
thepieces
piecesofof
of
g.
That
is,
graph
⇤,
0]
⇥
R
To
2
2 22 1,
where
g(x)
=
and
graph
:: [0,
[0,
4]!
⇥RR
Rwhere
whereg(x)
g(x)==
=xxx
x 1,1,
1,and
andgraph
graph
where
g(x)
and
graph
⇥
where
g(x)
and
graph
whereg(x)
g(x)==
=xxx
x
1,and
andgraph
graphgggg: :[0,
[0,4]4]
4]
⇥
R
where
g(x)
=
1,
and
graph
where
1,1,
[4,
⇤)
⇥
R
where
g(x)
=
3.
Together,
these1three
threepieces
piecesmake
makeup
upthe
the
[4,
⇤)
⇥
where
g(x)
Together,
these
three
pieces
make
up
the
[4,1)
⇤)!
⇥RR
Rwhere
whereg(x)
g(x)==
=3.3.
3. Together,
Together,these
these
three
pieces
make
up
the
gggg: :::[4,
graph
of
g(x).
graph
g(x).
graphofof
ofg(x).
g(x).
graph
Graph
of
⇤,
0]
⇥
Rwhere
whereg(x)
g(x)
=xx2x
x222 1.1.
1.
4, ==
Graph
⇤,
⇥
where
g(x)
Graphofof
ofgggg: :(:: ((( 1,
⇤,0]0]
0]!
⇥RR
R
where
g(x)
=
1.
Graph
5
2
I
Graph
of
:: [0,
[0,
4]
⇥
Rwhere
whereg(x)
g(x)==
=xxx
x 1.1.
1.
Graph
⇥
where
g(x)
Graphofof
ofgggg: :[0,
[0,4]4]
4]!
⇥RR
R
where
g(x)
=
1.
Graph
3
a
a
C
—I
Graphofof
ofggg: :[4,
: [4,
[4,1)
⇤)!
Graph
⇤)
⇥
where
g(x)
⇥RR
Rwhere
whereg(x)
g(x)==
=3.3.
3.
Graph
S
S
2
I
—z
‘I
a r
—I
178
178
178
229
4
.%
Ii
I—
£graphs
z of
To
graph
g(x),
draw
the
ofofall
all
three
ofofits
its
pieces.
To
Tograph
graphg(x),
g(x),draw
draw4,the
thegraphs
graphs
allthree
threeof
itspieces.
pieces.
S
—z
-i
2
I
3
5~
‘t
—I
Second
example.
The
function
⇥
RRisisisdefined
defined
by
Second
Secondexample.
example.The
Thefunction
functionfff:: R
:RR!
⇥R
definedby
by
(
22 2+ 2
(x
3)3)
⇤=⇤=3;
3;3;
(x
3)
++2 2 ifififxxx6=
(x
f
(x)
=
f (x)
f (x)== 4
==3.
3.3.
44
ifififxxx=
This
function
made
up
ofoftwo
two
pieces.
Either
⇤=⇤=3,
3,3,in
ininwhich
which
case
This
Thisfunction
functionisisismade
madeup
upof
twopieces.
pieces. Either
Eitherxxx6=
whichcase
case
2
2 2+ 2. Or x = 3, and then f (3) = 4.
f
(x)
=
(x
3)
f (x)
f (x)==(x(x 3)3)++2.2.Or
Orx x==3,3,and
andthen
thenf (3)
f (3)==4.4.
Graph
ofofthe
the
first
piece
ofofff(x):
the
graph
ofofxx2x2 2shifted
shifted
right
and
up
Graph
Graphof
thefirst
firstpiece
pieceof
f(x):
(x):the
thegraph
graphof
shiftedright
right333and
andup
up222
vertex
removed.
with the point of thewith
graph
whose
x-coordinate
withthe
the
vertex
removed. equals 3 removed.
(Remember
that
a
little
circle
means
that
point
not
point
ofofthe
the
graph.)
(Remember
(Rememberthat
thata alittle
littlecircle
circlemeans
meansthat
thatpoint
pointisisisnot
notaaapoint
pointof
thegraph.)
graph.)
It
(x-3~2+ 2
‘S
a
0’
I
~
179
230
179
41
£
E
of the
second
pieceaofsingle
f (x):giant
a single
giant dot.
Graph of Graph
the second
piece
of f (x):
dot whose
x-coordinate
equals 3.
Lf.
S
(3,9)
3
z
-p
ii
9.
.5
Graph of
of both
both pieces,
pieces, and
and hence
hence the
the entire
entire graph,
graph, of
of ff (x).
(x).
Graph
It
3
a
I
*
*
*
*
*
*
4Z~
I
*
231
180
180
*
*
*
*
*
*
Absolute value
value
Absolute
value
Absolute
The
most
important
piecewise defined
defined function
function in
in calculus
calculus isis
is the
the absolute
absolute
The most
most important
important piecewise
The
The
most
important
piecewise
defined
function
in
calculus
the
absolute
value
function
that
defined
by
value function
function that
that isis
is defined
defined by
by
value
value
function
that
(
xxx x ififif xxxif2⇤
⇥,
0];
⇤x(((⇥1,
⇥,
0];
0; 0];
|x|
=
|x|=
=
|x|
|x| = x if x ⇤ [0, ⇥).
[0,
⇥).
x x xifif xxif2⇤0[0,
⇥1).
x.
The
domain
of
the
absolute
value
function
R.
The
range
of
the
absolute
The domain
domain of
of the
the absolute
absolutevalue
valuefunction
functionisis
isR.
R. The
Therange
rangeof
ofthe
theabsolute
absolute
The
The
domain
of
the
value
function
is
the
set
of
non-negative
numbers.
The
number
|x|
called
value function
function isis
is the
the set
set of
of non-negative
non-negative numbers.
numbers. The
The number
number |x|
|x| isis
is called
called
value
value
function
the
the
absolute
value
of x.
x.
the absolute
absolute value
value of
the
the
absolute
value
of
x.
For
examples
of
how this
this function
function works,
works, notice
notice that
that |4|
|4| =
= 4,
4, |0|
|0| =
= 0,0,
0, and
and
For examples
examples of
of how
For
For
examples
of
how
this
function
works,
notice
that
|4|
=
4,
|0|
=
and
3|
3.
If
xx is
is
positive
0,
absolute
value
of
xx itself.
3| =
3. (If
If 3)
is
positive
or positive
0, then
then the
the
absolute
value
of xx is
isvalue
itself.
Ifisx
x xis
is
|||| 3|
= 3.
=positive
3. If x or
is
or 0,
then the
absolute
of xIf
x
negative,
then
|x|
is
the
positive
number
that
you’d
get
from
“erasing”
the
negative,
then
|x| is
is thethen
positive
that number
you’d getthat
from
“erasing”
the
itself.
If xthen
is negative,
|x| is number
the
positive
you’d
get from
negative,
|x|
11
11
1
1
negative
sign:
10|
10
|| =
=
.. |
12 || 10
negative sign:
sign:
10| =
=sign:
10 and
and
= 122and
“erasing”
the negative
| 10|
negative
||| 10|
2| = 2.
22
2
Graph
of
the
absolute
value
function.
Graph of
of the
the absolute
absolutevalue
valuefunction.
function.
Graph
Another
interpretation
of
the
absolute
value
function,
and
the
one
that’s
Another interpretation
interpretation of
of the
the absolute
absolute value
value function,
function, and
and the
the one
one that’s
that’s
Another
Another
interpretation
of
the
absolute
value
function,
and
the
one
that’s
most
important
for
calculus,
is
that
the
absolute
value
of
a
number
is
the
most important
important for
for calculus,
calculus, isis
is that
that the
the absolute
absolute value
value of
of aaa number
number isis
is the
the
most
most
important
for
calculus,
that
the
absolute
value
of
number
the
same
as
its
distance
from
0.
That
is,
the
distance
between
0
and
5
is
|5|
=
5,
same as
as its
its distance
distancefrom
from0.
0. That
Thatis,
is,the
thedistance
distancebetween
between000and
and555isis
is|5|
|5|==
=5,5,
5,
same
same
as
its
distance
from
0.
That
is,
the
distance
between
and
|5|
the
distance
between
0
and
7
is
|
7|
=
7,
and
the
distance
between
0
and
the distance
distance between
between 000 and
and 777isis
is||| 7|
7|=
=7,
7,and
andthe
thedistance
distancebetween
between000and
and
the
the
distance
between
and
7|
=
7,
and
the
distance
between
and
is
|0|
=
0.
is |0|
|0|=
=0.
0.
0000 is
is
|0|
=
0.
181
191
232
4
Let’s
Let’s look
look at
at the
the graph
graph of
of say
say |x
|x 3|.
3|. It’s
It’s the
the graph
graph of
of |x|
|x| shifted
shifted right
right by
by
3.
Let’s
look
at
the
graph
of
say
|x
3|.
It’s
the
graph
of
|x|
shifted
right
by
3.
3.
You
You might
might guess
guess from
from the
the graph
graph of
of |x
|x 3|,
3|, that
that |x
|x 3|
3| is
is the
the function
function that
that
You might
guess from
the graph
of |x
3|, that’s
that |xtrue.3| Similarly,
is the function
that
measures
the
distance
between
x
and
3,
and
|x
measures the distance between x and 3, and that’s true. Similarly, |x 6|
6| is
is
measures
thebetween
distancex between
x+and
3,the
anddistance
that’s true.
Similarly,
|x 2, and
6| is
the
distance
and
6,
|x
2|
is
between
x
and
the distance between x and 6, |x + 2| is the distance between x and 2, and
the distance between
x and
6, |x + 2| is
the distance
between x and 2, and
more
more generally,
generally, |x
|x y|
y| is
is the
the distance
distance between
between x
x and
and y.
y.
more generally, |x y| is the distance between x and y.
**
*
**
*
**
*
**
*
**
*
**
*
**
*
**
*
**
*
**
*
**
*
**
*
Solving inequalities involving absolute values
Solving inequalities involving absolute values
**
*
The inequality |x| < 5 means that the distance between x and 0 is less than
inequality
< 5 means5 that
x and the
0 is previous
less than
5. The
Therefore,
x is|x|between
and the
5. distance
Another between
way to write
5. Therefore,
sentence
is 5x<isxless
< 5.than 5 and greater than 5. Another way to write the
previous sentence is 5 < x < 5.
Notice in the above paragraph that the precise number 5 wasn’t really
important for the problem. We could have replaced 5 with any positive
number c to obtain the following translation.
-8 -7-s
-~
-‘t 3-2
|x|
< c means
233
192
182
5
c2 <3Zt56
x<c
78
Notice in the above paragraph that the precise number 5 wasn’t really
important for the problem. We could have replaced 5 with any positive
number c to obtain the following translation.
|x| < c means
c<x<c
For example, writing |x| < 2 means the same thing as writing 2 < x < 2,
and |2x 3| < 13 means the same as 13 < 2x 3 < 13 .
We can use the above rule to help us solve some inequalities that involve
absolute values.
Problem. Solve for x if |
3x + 4| < 2.
Solution. We know from the explanation above that
2<
3x + 4 < 2.
Subtracting 4 from all three of the quantities in the previous inequality
yields 2 4 < 3x < 2 4, and that can be simplified as 6 < 3x < 2.
Next divide by 3, keeping in mind that dividing an inequality by a negative number “flips” the inequalities. The result will be 63 > x > 23 , which
can be simplified as 2 > x > 23 . That’s the answer.
The inequality 2 > x >
x 2 ( 23 , 2).
2
3
could also be written as
234
2
3
< x < 2, or as
Problem. Solve for x if |2x
1| < 3.
FL
2x-i
I
(71
2 < 2x < 4, and divide by 2 to get
1 < x < 2.
I
CA)
10
H
Add 1 to get
1 < 3.
H
3 < 2x
‘0
N
—
Solution. Write the inequality from the problem as
*
*
*
*
*
*
*
*
*
*
*
*
*
15
n
V
If c is a positive number, |x| > c means that the distance between x and 0
is greater than c. There are two ways that the distance between x and 0 can
be greater than c. Either x < c or x > c.
p
b
r)
|x| > c means either x <
c or x > c
S
235
~ir
H
FL
FL
‘0
H
‘0
N
I
(71
—
N
—
Problem. Solve for x if |2x + 1| > 5.
I
CA)
I
CA)
10
H
10
H
I
(71
Solution. |2x + 1| > 4 means that either 2x + 1 < 5 or 2x + 1 > 5.
This leaves us with two di↵erent inequalities to solve. Let’s start with the
inequality 2x + 1 < 5 . Subtract 1, and divide by 2 to find that x < 3.
That’s one half of our answer.
For the second half of the answer, solve the second inequality: 2x + 1 > 5.
Subtract 1, and divide by 2 to find that x > 2. That’s the second half of our
answer.
To summarize, if |2x + 1| > 4, then either x < 3 or x > 2.
*
*
n
V
*
*
*
*
*
*
*
*
*
*
*
15
Two important rules for absolute values
2. |a
c|  |a
b| + |b
c| (triangle inequality)
r)
1. |ab| = |a||b|
15
n
V
For the two rules below, a, b, c 2 R. Each rule is important for calculus.
They’ll be explained in class.
236
Exercises
1.) Suppose f (x) is the piecewise defined function given by
(
x + 1 if x 2 ( 1, 2);
f (x) =
x + 3 if x 2 [2, 1).
What is f (0)? What is f (10)? What is f (2)?
2.) Suppose g(x) is the piecewise defined function given by
(
3 if x 2 [1, 5];
g(x) =
1 if x 2 (5, 1).
What is g(1)? What is g(100)? What is g(5)?
3.) Suppose h(x) is the piecewise defined function given by
(
5
if x 2 (1, 3];
h(x) =
x + 2 if x 2 [3, 8).
What is h(2)? What is h(7)? What is h(3)?
4.) Suppose f (x) is the piecewise defined function given by
8
>
if x 2 [ 3, 0);
<2
f (x) = ex
if x 2 [0, 2];
>
:3x 2 if x 2 (2, 1).
What is f ( 2)? What is f (0)? What is f (2)? What is f (15)?
5.) Suppose g(x) is the piecewise defined function given by
8
2
>
if x 2 ( 1, 1];
<(x 1)
g(x) = loge (x)
if x 2 [1, 5];
>
:log (5)
if x 2 [5, 1).
e
What is g(0)? What is g(1)? What is g(5)? What is g(20)?
237
6.) Suppose h(x) is the piecewise defined function given by
(
ex if x 6= 2;
h(x) =
1
if x = 2.
What is h(0)? What is h(2)? What is h loge (17) ?
7.) Write the following numbers as integers: |8 5|, | 10 5|, and |5 5|.
The function |x 5| measures the distance between x and which number?
8.) Write the following numbers as integers: |1 2|, |3 2|, and |2 2|.
The function |x 2| measures the distance between x and which number?
9.) Write the following numbers as integers: |3 + 4|, | 1 + 4|, | 4 + 4|.
The function |x + 4| measures the distance between x and which number?
10.) The function |x
number?
11.) Solve for x if |5x
y| measures the distance between x and which
2| < 7.
12.) Solve for x if |3x + 4| < 1.
13.) Solve for x if |
2x + 3| < 5.
14.) Solve for x if |x + 3| > 2.
15.) Solve for x if |4x| > 12.
16.) Solve for x if |2x + 4| > 8.
238
Match the functions with their graphs.
17.) f (x) = 2x + 1
(
2x + 1
1
II
18.) g(x) = 1
19.) p(x) =
(
20.) q(x) =
A.)
B.)
C.)
D.)
1
2x + 1
if x 2 ( 1, 0);
if x 2 [0, 1).
if x 2 ( 1, 0);
if x 2 [0, 1).
II
239
a’
a’
I
Match the functions with their graphs.
21.) f (x) = e
22.) g(x) =
x
2
A.)
23.) p(x) =
(
24.) q(x) =
(
ex
2
if x 6= 1;
if x = 1.
ex
2
if x 6=
if x =
1;
1.
B.)
a’
I
C.)
D.)
a’
240
a’
a’
Match the functions with their graphs.
25.) f (x) =
p
x+2
28.) q(x) =
(
a’
27.) p(x) =
(
I
26.) g(x) = 2
A.)
B.)
C.)
D.)
x+2
if x 2 ( 1, 0);
if x 2 [0, 1).
x+2
if x 2 ( 1, 1);
if x 2 [1, 1).
2
p
2
p
a’
I
241
a’
a’
Simplify the expressions in #29-34.
29.) 34
2
32.) 8 3
30.)
2
1
4
33.) 27
31.)
2
3
1
e
4
2
3
34.) 16 2
Each of the numbers in #35-40 is an integer. Which integers are they?
1
e3
35.) loge (e6 )
36.) loge
38.) log2 32
39.) log2 ( 14 )
242
37.) log2 (8)
40.) log3 (81)
Download