2.3 Functions

Ex: 1-23

  • Function f:A→Bf: A\to B - an assiagnment of exactly one element of BB to each element of AA.
  • Domain and codomain, image and preimage, range
  • One-to-one function

    ∀a∀b(f(a)=f(b)→a=b)\forall a \forall b (f(a)=f(b) \to a=b) or equivalently ∀a∀b(a≠b→f(a)≠f(b))\forall a \forall b (a\ne b \to f(a) \ne f(b))

  • Image of set f(s)={t∣∃s∈S,f(s)=t}f(s) = \{t \mid \exists s \in S, f(s) = t\}
  • Inverse function

    1. If ff is a function f:A→Bf: A\to B and is one to one, then f−1f^{-1} exists.
    2. f−1(b)=af^{-1}(b) = a when f(a)=bf(a) = b

  • Inverse image (hw 42, 44)
  • Composite Function

Homework

p175: 40, 42, 44

40. Let ff be a function from the set AA to the set BB. Let SS and TT be subsets of AA. Show that
a. f(S∪T)=f(S)∪f(T)f(S \cup T) = f(S) \cup f(T).

Solution

we need to prove (1) f(S∪T)⊆f(S)∪f(T)f(S \cup T) \subseteq f(S) \cup f(T) and (2) f(S)∪f(T)⊆f(S∪T)f(S) \cup f(T) \subseteq f(S \cup T).
a1. Prove f(S∪T)⊆f(S)∪f(T)f(S \cup T) \subseteq f(S) \cup f(T)
Let b∈f(S∪T)b \in f(S \cup T), it follows that ∃(a∈S∪T)f(a)=b\exists (a \in S \cup T)f(a) = b

a∈S∪T⇒a∈S∨a∈T⇒(Or){a∈S⇒f(a)∈f(S)a∈T⇒f(a)∈f(T)⇒f(a)∈f(S)∪f(T)⇒b∈f(S)∪f(T)\begin{gathered} a \in S \cup T \To a \in S \lor a \in T\\ \To \text{(Or)} \begin{cases} a \in S \To f(a) \in f(S) \\ a \in T \To f(a) \in f(T) \end{cases} \To f(a) \in f(S) \cup f(T) \To b \in f(S) \cup f(T) \end{gathered}

Therefore a1 is proved.
a2. Prove f(S)∪f(T)⊆f(S∪T)f(S) \cup f(T) \subseteq f(S \cup T)
Let b∈f(S)∪f(T)b \in f(S) \cup f(T), it follows that b∈f(S)∨b∈f(T)b \in f(S) \lor b \in f(T)

case 1: b∈f(S)⇒∃(a1∈S)f(a1)=ba1∈S⇒a1∈S∪T⇒f(a1)∈f(S∪T)⇒b∈f(S∪T)case 2: b∈f(T)⇒∃(a2∈T)f(a2)=ba2∈T⇒a2∈S∪T⇒f(a2)∈f(S∪T)⇒b∈f(S∪T)\begin{aligned} \text{case 1: } & b \in f(S) \To \exists (a_1 \in S)f(a_1) = b \\ & a_1 \in S \To a_1 \in S \cup T \\ &\To f(a_1) \in f(S \cup T) \\ &\To b \in f(S \cup T)\\ \text{case 2: } & b \in f(T) \To \exists (a_2 \in T)f(a_2) = b \\ & a_2 \in T \To a_2 \in S \cup T \\ &\To f(a_2) \in f(S \cup T) \\ &\To b \in f(S \cup T) \end{aligned}

In both cases, b∈f(S∪T)b \in f(S \cup T). Therefore a2 is proved.
According to (a1) and (a2), a is true.

b. f(S∩T)⊆f(S)∩f(T)f(S \cap T) \subseteq f(S) \cap f(T).

Solution

Let b∈f(S∩T)b \in f(S \cap T), it follows that ∃(a∈S∩T)f(a)=b\exists (a \in S \cap T)f(a) = b

a∈S∩T⇒a∈S∧a∈T⇒(And){a∈S⇒f(a)∈f(S)a∈T⇒f(a)∈f(T)⇒f(a)∈f(S)∩f(T)⇒b∈f(S)∩f(T)\begin{gathered} a \in S \cap T \To a \in S \land a \in T\\ \To \text{(And)}\begin{cases} a \in S \To f(a) \in f(S)\\ a \in T \To f(a) \in f(T) \end{cases} \To f(a) \in f(S) \cap f(T) \To b \in f(S) \cap f(T) \end{gathered}

Therefore b is true.

Let ff be a function from the set AA to the set BB. Let SS be a subset of BB. We define the inverse image of SS to be the subset of AA whose elements are precisely all pre-images of all elements of SS. We denote the inverse image of S by f−1(S)f^{-1}(S), so f−1(S)={a∈A∣f(a)∈S}f^{-1}(S) = \{a \in A | f (a) \in S\}. (Beware: The notation f−1f^{-1} is used in two different ways. Do not confuse the notation introduced here with the notation f−1(y)f^{-1}(y) for the value at yy of the inverse of the invertible function ff. Notice also that f−1(S)f^{-1}(S), the inverse image of the set SS, makes sense for all functions ff, not just invertible functions.)

42. Let ff be the function from R\mathbb {R} to R\mathbb {R} defined by f(x)=x2f(x) = x^2. Find
a. f−1({1})f^{-1}(\{1\})

Solution

f(x)=x2=1⇒x=±1f−1({1})={±1}\begin{gathered} f(x) = x^2 =1 \To x=\pm 1 \\ f^{-1}(\{1\}) = \{\pm 1\} \end{gathered}

b. f−1({x∣0<x<1})f^{-1}(\{x | 0 <x< 1\})

Solution

0<f(x)=x2<1⇒0<x<1 or −1<x<0f−1({x∣0<x<1})={a∈(0,1)∨a∈(−1,0)}\begin{gathered} 0 < f(x)=x^2 <1 \To 0<x<1 \text{ or } -1<x<0 \\ f^{-1}(\{x | 0 <x< 1\}) = \{a \in (0, 1) \lor a \in (-1, 0)\} \end{gathered}

c. f−1({x∣x>4})f^{-1}(\{x | x > 4\})

Solution

f(x)=x2>4⇒x<−2 or x>2f−1({x∣x>4})={a∈(2,∞)∨a∈(−∞,2)}\begin{gathered} f(x)=x^2 >4 \To x<-2 \text{ or } x>2 \\ f^{-1}(\{x | x > 4\}) = \{a \in (2, \infty) \lor a \in (-\infty, 2)\} \end{gathered}

44. Let ff be a function from AA to BB. Let SS and TT be subsets of BB. Show that
a) f−1(S∪T)=f−1(S)∪f−1(T)f^{-1}(S \cup T) = f^{-1}(S) \cup f^{-1}(T).

Solution

We need to prove (a1) f−1(S∪T)⊆f−1(S)∪f−1(T)f^{-1}(S \cup T) \subseteq f^{-1}(S) \cup f^{-1}(T) and (a2) f−1(S)∪f−1(T)⊆f−1(S∪T)f^{-1}(S) \cup f^{-1}(T) \subseteq f^{-1}(S \cup T).
a1. Prove f−1(S∪T)⊆f−1(S)∪f−1(T)f^{-1}(S \cup T) \subseteq f^{-1}(S) \cup f^{-1}(T)
Let a∈f−1(S∪T)a \in f^{-1}(S \cup T), it follows that f(a)∈S∪Tf(a) \in S \cup T

(Or){f(a)∈S⇒a∈f−1(S)f(a)∈T⇒a∈f−1(T)⇒a∈f−1(T)∪f−1(S)\begin{gathered} \text{(Or)} \begin{cases} f(a) \in S \To a \in f^{-1}(S) \\ f(a) \in T \To a \in f^{-1}(T) \\ \end{cases} \To a \in f^{-1}(T) \cup f^{-1}(S) \end{gathered}

Therefore a1 is proved.
a2. Prove f−1(S)∪f−1(T)⊆f−1(S∪T)f^{-1}(S) \cup f^{-1}(T) \subseteq f^{-1}(S \cup T)
Let a∈f−1(S)∪f−1(T)a \in f^{-1}(S) \cup f^{-1}(T), then a∈f−1(S)∨a∈f−1(T)a \in f^{-1}(S) \lor a \in f^{-1}(T)

(Or){a∈f−1(S)⇒f(a)∈Sa∈f−1(T)⇒f(a)∈T⇒f(a)∈S∪T⇒a∈f−1(S∪T)\begin{gathered} \text{(Or)} \begin{cases} a \in f^{-1}(S) \To f(a) \in S\\ a \in f^{-1}(T) \To f(a) \in T \end{cases}\\ \To f(a) \in S \cup T \To a \in f^{-1}(S \cup T) \end{gathered}

Therefore a2 is proved.
According to (a1) and (a2), a is true.

b) f−1(S∩T)=f−1(S)∩f−1(T)f^{-1}(S \cap T) = f^{-1}(S) \cap f^{-1}(T).

Solution

We need to prove (b1) f−1(S∩T)⊆f−1(S)∩f−1(T)f^{-1}(S \cap T) \subseteq f^{-1}(S) \cap f^{-1}(T) and (b2) f−1(S)∩f−1(T)⊆f−1(S∩T)f^{-1}(S) \cap f^{-1}(T) \subseteq f^{-1}(S \cap T).
b1. Prove f−1(S∩T)⊆f−1(S)∩f−1(T)f^{-1}(S \cap T) \subseteq f^{-1}(S) \cap f^{-1}(T)
Let a∈f−1(S∩T)a \in f^{-1}(S \cap T), it follows that f(a)∈S∩Tf(a) \in S \cap T

(And){f(a)∈S⇒a∈f−1(S)f(a)∈T⇒a∈f−1(T)⇒a∈f−1(S)∩f−1(T)\begin{gathered} \text{(And)} \begin{cases} f(a) \in S \To a \in f^{-1}(S)\\ f(a) \in T \To a \in f^{-1}(T) \end{cases}\\ \To a \in f^{-1}(S) \cap f^{-1}(T) \end{gathered}

Therefore b1 is proved.
b2. Prove f−1(S)∩f−1(T)⊆f−1(S∩T)f^{-1}(S) \cap f^{-1}(T) \subseteq f^{-1}(S \cap T)
Let a∈f−1(S)∩f−1(T)a \in f^{-1}(S) \cap f^{-1}(T), then a∈f−1(S)∧a∈f−1(T)a \in f^{-1}(S) \land a \in f^{-1}(T)

(And){a∈f−1(S)⇒f(a)∈Sa∈f−1(T)⇒f(a)∈T⇒f(a)∈S∩T⇒a∈f−1(S∩T)\begin{gathered} \text{(And)} \begin{cases} a \in f^{-1}(S) \To f(a) \in S\\ a \in f^{-1}(T) \To f(a) \in T \end{cases}\\ \To f(a) \in S \cap T \To a \in f^{-1}(S \cap T) \end{gathered}

Therefore b2 is proved.
According to (b1) and (b2), b is true.