Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Методичка дискретка(англ).doc
Скачиваний:
2
Добавлен:
12.11.2019
Размер:
1.33 Mб
Скачать

Figure 4

example 5 (a) Consider the function h: R R given by

h{x) = (x3 + 2x)7.

The value h(x) is obtained by first calculating x3 + 2x and then taking its seventh power. We write f for the first or inside function: f(x) = x3 + 2x. We write g for the second or outside function: g(x) = x7. The name of the variable x is irrelevant; we could just as well have written g(y) = y7 for yR. Either way, we see that

g(f(x)) = 9(x3 + 2x) = (x3 + 2x)7 = h{x) for xR.

Thus h = g o f. The ability to view complicated functions as the com­position of simpler functions is a critical skill in calculus. Note that the order of f and g is important. In fact,

f o g(x) = f(x7) = (x7)3 + 2(x7) = x2 * + 2x7 for xR.

(b) Suppose that one wishes to calculate h(x) = for certain positive values of x on a hand-held calculator. The calculator has the functions and log x, which stands for log10 x. One works from the inside out. For example, if x = 73, one keys in this value, performs log x to obtain 1.8633, and then performs to obtain 1.3650. Note that h= g o f where f(x) = log x and g(x) = . As in part (a), order is im­portant: h f o g, i.e., is not generally equal to log . For example, if x = 73, then is approximately 8.5440 and log is approximately .9317.

(c) Of course, some functions f and g do commute under composi­tion,

i.e., satisfy f o g == g o f. For example, if f(x) = and g{x) = 1/x for

x  (0, ), then f o g = g o f because

for x  (0,)

For example, for x = 9 we have . ■

We can compose more than two functions if we wish.

EXAMPLE 6. Define the functions f, g and h that map R into R by

.

We've used the different variable names x, y and z to help clarify our computations below. Let’s calculate h o (g o f) and (h o g) o f and com- pare the answers. First, for xR we have

(h o (g o f))(x) = h(g o f(x)) by definition of h o (g o f)

= h(g(f(x))) by definition of g o f

=h(g(x4)) since f(x) = x4

= y = x4 in definition of h

= +72 z = in definition of h

= x8 + 73 algebra.

On the other hand,

((h o g) o f)(x) = (h o g)(f(x)) by definition of (h o g) o f

= h(g(f(x))) by definition of h o g

= x8 + 73 exactly as above.

We conclude that

(h o (g o f))(x)=((h o g) o f)(x)=x8+73 for all xR,

so the functions h o (g o f) and (h o g) o f are exactly the same function. This is no accident, as we observe in the next general theorem. ■

Consider functions f: S T, g: T U and h: UV. Then

h o (g o f) = (h o g) o f.

Associativity of

Composition

The proof of this basic result amounts to checking that the func­tions h o (g o f) and (h o g) o f both map S into V and that, just as in Example 6, for each xS the values (h o (g o f))(x) and ((h o g) o f)(x) arc both equal to h{g(f(x))).

Since composition is associative, we can write h o g o f unambig­uously without any parentheses. We can also compose any finite number of functions without using parentheses.

example 7 (a) If f{x) = x4 for x  [0, ), g(x) = for x  [0, )

and h(x) = x2 + 1 for xR, then

h o g o f(x) = h(g(x4)) = h( ) = (x4 + 2) + 1= x4 + 3

for x  [0, ),

= f{g(x2 + 1)) = = (x3 +3)2

for xR,

for x  [0, ).

(b) The function F given by

F(x) = for xR

can be written as k ◦ h ◦ g ◦ f where

f(x) = x2 + 1 for xR,

g(x)= for x  [0,),

h(x) = x+3 for xR,

k(x)=x5 for xR.

EXERCISES 1.3

1 . We define f: RR as follows:

  1. Calculate f(3), f(1/3), f(-1/3) and f(-3).

(b) Sketch a graph of f.

(c) Find Im(f).

2. The functions sketched in Figure 5 have domain and codomain both equal to [0,1].

(a) Which of these functions are one-to-one?

(b) Which of these functions map [0,1] onto [0,1]?

(c) Which of these functions are one-to-one correspondences?