Vai alla Home Page About me Courseware Federica Living Library Federica Federica Podstudio Virtual Campus 3D Le Miniguide all'orientamento Gli eBook di Federica La Corte in Rete
 
I corsi di Agraria
 
Il Corso Le lezioni del Corso La Cattedra
 
Materiali di approfondimento Risorse Web Il Podcast di questa lezione

Francesco Giannino » 1.Functions and their graph. One–one and onto functions. Composite and inverse functions.


Functions and their graphs

Given two sets X and Y, a function from X to Y is a rule, or law, that associates to every element xX (the independent variable) an element yY (the dependent variable). It is usually symbolized as

y = f (x),

in which x is called argument (input) of the function f and y is the image (output) of x under f.

Functions and their graphs

A single output is associated to each input, as different input can generate the same output.
The set X is called domain of the function f (dom f), while Y is called codomain (cod f). The range (or image) of X, is the set of all images of elements of X (rng ƒ). Obviously

rng~f \subseteq cod~f

The notation

f : X \to Y

indicates that ƒ is a function with domain X and codomain Y.

Functions and their graphs

Given ƒ:X → Y, the graph G( f ) is the set of the ordered pairs

(x,y) ~such~ that ~x \in X, y = f (x)

In particular, if x and y are real numbers, G(f ) can be represented on a Cartesian plane to form a curve. A glance at the graphical representation of a function allows us to visualize the behaviour and characteristics of a function.

G(f) = \{(1,4), (2,1), (3,1)\}


Functions and their graphs: preimage

Given ƒ:X → Y, the preimage (or inverse image, or counter image) of a subset B of the codomain Y under ƒ is the subset f-1(B) of the elements of X whose images belong to B, i.e

f^{-1} (B) = \{ x \in X:f(x) \in B\}<br />

f^{-1} \{ 3\} = \emptyset

f^{-1} \{1\}= \{a,b\}

f^{-1} \{1,3\}= \{a,b\}


Vertical line test

The Vertical line test is used to determine whether a curve is the graph of a function when the function’s domain and codomain correspond to the x and y axes of the Cartesian coordinate system.
Essentially, the test amounts to answering this question:
is it possible to draw a vertical line that intersects the curve in two or more places?  If so, then the curve is not the graph of a function.  If it is not possible, then the curve is the graph of a function.
Why does this test work?
A curve would fail to be the the graph of a function if for any input x, there existed more than one y-value corresponding to it.

Vertical line test

Take, for example, the equation x^2 + y^2 = 4
Note that the points (0, 2) and (0, -2) both satisfy the equation.  So we have a situation in which one x-value (namely, when x = 0) corresponds to two different y-values (namely, 2 and -2).  The points (0, -2) and (0, 2) lie on the same vertical line with equation x = 2 on the Cartesian coordinate system.
So if a vertical line hits a curve in more than one place, it is the same as having the same x-value paired up with two different y-values, and the graph is not that of a function.
(Thus, a circle is not the graph of a function).

Vertical line test

We see that we can draw a vertical line, for example the dotted line in the drawing, which cuts the circle more than once.

Therefore the circle is not a function.


Example

Example 1. Does this graph pass the vertical line test?

Solution. It passes the vertical line test.  Therefore, it is the graph of a function.


Example

Example 2. Does this graph pass the vertical line test?

Solution. It does not pass the vertical line test because the vertical line we have drawn cuts the graph twice, so it is not the graph of a function.


Definition

A one to one function is a function which associates distinct arguments with distinct values; that is, every unique argument produces a unique result. It is not necessary for all elements in a co-domain to be mapped. A one to one function is also said to be an injective function.
A function f that is not injective is sometimes called many-to-one.

Definition. Let  f:  X \rightarrow Y be a function whose domain is a set X. The function f is injective if

\forall x_1, x_2 \in X, f (x_1) = f (x_2) \Longrightarrow x_1 = x_2

Similarly, if

x_1 \not= x_2 \Rightarrow f (x_1) \not= f (x_2)

Practice Rules

  • Put f(x_1)=f(x_2).  Solve equation. If it yieldsx_1=x_2 then function is one-one; otherwise not.
  • Alternatively, draw plot of the given function and apply the horizontal line test. That is, draw a line parallel to x-axis such that it intersects as many points on the plot as possible. If it intersects the graph only at one point, then the function is one-one.
  • Alternatively, a function is a one-one function, if f(x) is a continuous function and is either increasing or decreasing  in the given domain.

Exercises

Exercise 1. Let a function f: R \rightarrow R be given by:

f(x)=x^3

Decide whether f is injective.

Solution. Applying the horizontal line test, draw a line parallel to x-axis to intersect the plot of the function as many times as possible.

Exercises

We find that all lines drawn parallel to x-axis intersect the plot only once. Hence, the function is one-one.


Exercises

Exercise 2. Let a function f: R \rightarrow R be given by:

f(x)=x|x|.

Decide whether f is injective.

Solution. Draw the plot of the function and see intersection of a line parallel to x-axis.
We observe that there is no line parallel to x-axis which intersects the functions more than once. Hence, function is one-one.


Exercises

Exercise 3. Let a function f: R \rightarrow R be given by:

f(x)=x^2.

Decide whether f is injective.

Solution. We can solve f(x_1)= f(x_2) and see whether  x_1=x_2 to decide the function type.
Then

f (x_1) = f (x_2) \Longleftrightarrow x {_1}{^2} = x {_2}{^2}

That is

x_1 = \pm x_2

We see x_1 that is not exclusively equal to x_2 . Hence, given function is not a one-one function, but a many – one function.

Exercises

The conclusion is further emphasized by the intersection of a line parallel to x-axis, which intersects function plot at two points.


Exercises

Exercise 4. Let a function f: R \rightarrow R be given by:

f (x) = \frac {3x^2 + 6x - 8} {3+ 6x - 8x^2}

Decide whether f is injective.

Solution. The given function is a rational function. We have to determine function type.
We evaluate function for x=0. If  f(x)=f(0) equation yields multiple values of x, then function is not one-one. Then,

f(0) = - \frac 8 3

Exercises

Now, f (x) = f (0) \Longrightarrow

f(x)= \frac{3x^2+6x-8}{3+6x-8x^2}=-\frac{8}{3}

\Rightarrow 9x^2+18x-24=64x^2-48x-24

\Rightarrow 55x^2-66x=0 \Rightarrow 5x^2-6x=0

\Rightarrow x=0 \quad\text{and}\quad x=\frac{6}{5}

We see that f(0)=f(26). It means pre-images are not related to distinct images. Thus, we conclude that function is not one-one, but many-one.

Definition

A function is an onto function if its range is equal to its co-domain. Onto functions are alternatively called surjective functions.

Definition. Let  f:X \rightarrow Y be a function whose domain is a set X. The function f is an onto function if and only if for every y in the co-domain Y there is at least one x in the domain X such that f(x)=y:

\forall y \in Y, \exists x \in X : f(x) = y

Exercises

Exercise 5. Let a function f:[0,2] \rightarrow [-1,2] be given by:

f(x) = \sqrt x -1

Decide whether f is an onto function.

Solution. We can apply the definition to verify if f is onto.

\forall y \in [-1,2], \exists x \in [0,2] : f (x) = y \Leftrightarrow

\Leftrightarrow \sqrt x - 1 = y \Leftrightarrow x = (1 + y) ^2

Choosing for example y=2 \in [-1,2], we obtain

x=9\notin [-1,2] \Rightarrow f is not onto.

Definition

Definition. A function f is a bijection if the function is both one-one and onto and has the property that every element y Y. corresponds to exactly one element x \in X.

Definition. Let f:X \rightarrow Y. Then, if it exists, the inverse of ƒ is the function f^{-1}:Y \rightarrow X , defined by the following rule:

f(x)=y \Rightarrow f^{-1}(y)=x

Stated otherwise, a function is invertible if and only if its inverse relation is a function, in which case the inverse relation is the inverse function: the inverse relation is the relation obtained by switching x and y everywhere.

Definition

Not all functions have an inverse. For this rule to be applicable, each element y \in Y must correspond to exactly one element y Y .

Most functions encountered in elementary calculus do not have an inverse.

Definition. A function f admits an inverse function f^{-1} if the function f is a bijection.

Exercises

Exercise 6. Let a function f:R \rightarrow R be given by :

f(x)=x+1

Decide whether f has the inverse function and construct it.

Solution. The function f is both one-one and onto, so the function f has the inverse function f^{-1}.

We construct an inverse rule in step-wise manner:

Step 1: Write down the rule of the given function f.
Let the given rule be f(x) given by :

f(x)=x+1

Exercises

Let us put y=f(x). Then

y=f(x)=x+1

This relation gives us one value of image. For example, if x=3, then

y=f(3)=3+1=4

Step 2: Solve for x:

x=y-1

Replace x which now represents image by the symbol f^{-1}(x) and replace y which now represents independent variable by x. For the given function, f(x)=x+1, the new inverse rule is:

f^{-1}(x)=x-1

Exercises

Exercise 7. Let a function f:R \rightarrow R be given by:

f(x)=|x|

Decide whether f has the inverse function and construct it.

Solution. The function f is not one-one, so the function f does not have the inverse function f^{-1}.

Exercises

Exercise 8. Let a function f:R \rightarrow R be given by :

f(x)=x^2+1

Decide whether f has the inverse function and construct it.

Solution. The function f is not one-one, so the function f does not have the inverse function  f^{-1}.

Composition of Functions

We can understand composition in terms of two functions.
Let there be two functions denoted as :

f: A \rightarrow B~ by~f(x) for~ all ~x \in A

g: B \rightarrow C~ by~g(x) for~ all ~x \in B

Observe that set B is common to two functions. The rules of the functions are given by f (x) and g (x) respectively. Our objective here is to define a new function h: A \rightarrow C and its rule.

Composition of Functions

Thinking in terms of relation, A and B are the domain and codomain of the function f. It means that every element x of A has an image f (x) in B.
Similarly, thinking in terms of relation, B and C are the domain and codomain of the function g.
In this function, f (x) which was the image of pre-image x in A is now pre-image for the function g. There is a corresponding unique image in set “C“. Following the symbolic notation, f (x) has image denoted by “g(f (x)) ” in “C”. The gure here depicts the relationship among three sets via two functions (relations) and the combination function.

Composition of Functions

Function composition is a special relation between sets not common to two functions.


Composition of Functions

For every element x in A, there exists an element f (x) in set B. This is the requirement of function f by definition. For every

element f (x) in B, there exists an element g(f (x)) in set B. This is the requirement of function g by definition. It follows, then, that for every element x in A, there exists an
element g(f(x)) in set C. This concluding statement is definition of a new function :

h:A \rightarrow C~by~ f(x) ~for~all~ x \in A

By convention, we call this new function as g \circ f and is read “g composed with f“.

g~ o ~f = g (f (x)), \forall x \in A

The two symbolical representations are equivalent.

Exercises

Exercise 9. Let two functions  f: R \rightarrow R and g:R \rightarrow R be defined as follow:

f (x) = x^2

g(x) = x + 1

Determine f \circ g and g \circ f .

Solution. According to definition,

f o g = f (g(x))

\Longrightarrow f o g (x) = f (x + 1)

\Longrightarrow f o g (x) = f (x + 1)^2

Exercises

Again, according to definition,

g \circ f = g(f(x))

\Rightarrow g \circ f(x)=g(x^2)

\Rightarrow g \circ f(x) = (x^2+1)

Importantly note that  f \circ g \neq g \circ f
It indicates that composition of functions is not commutative.

Existence of composition set

Let there be two functions denoted as :

f:A \rightarrow B~by~ f(x)~for~all ~x \in A

g:B \rightarrow C~by~g(x) ~for~all~x \in B

The range of f is a subset of its co-domain B. But, set B is the domain of function g such that there exists image g (f (x)) in C for every x in A. This means
that range of f is subset of domain of g :

Range of f ⊂ Domain of g

Existence of composition set

Clearly, if this condition is met, then composition g \circ f exists. Following this conclusion,  f \circ g will exist, if

Range of g ⊂ Domain of f

And, if both conditions are met simultaneously, then we can conclude that both g \circ f and  f \circ g g exist.

This is usually possible when all sets involved are sets of real numbers.

Exercises

Exercise 10. Let two functions be defined as follows:

f = \{(1, 2), (2, 3), (3, 4), (4, 5)\}

g = \{(2,4), (3, 2), (4, 3), (5, 1)\}

Check whether and exit for the given functions?

Solution. Here we have,

Domain of f ={1,2,3,4}

Range of f ={2,3,4,5}

Domain of g ={2,3,4,5}

Range of g ={4,2,3,1} = {1,2,3,4}

Exercises

Hence

Range of f ⊂ Domain of g

and

Range of g ⊂ Domain of g

This means that both compositions g \circ f and f \circ g exist for the given sets.

  • Contenuti protetti da Creative Commons
  • Feed RSS
  • Condividi su FriendFeed
  • Condividi su Facebook
  • Segnala su Twitter
  • Condividi su LinkedIn
Progetto "Campus Virtuale" dell'Università degli Studi di Napoli Federico II, realizzato con il cofinanziamento dell'Unione europea. Asse V - Società dell'informazione - Obiettivo Operativo 5.1 e-Government ed e-Inclusion