Types of Functions

One to one Function:

A function f : X → Y is defined to be one-one (or injective), if the images of distinct elements of

X under f are distinct,

i.e., for every x1 , x2 ∈ X, f(x1 ) = f(x2 ) implies x1 = x2 . Otherwise, f is called many-one.

## Examples

Examples of one-one / injective Function

• The identity function X → X is always one-one.
• If function f: R→ R, then f(x) = 2x is one-one.
• If function f: R→ R, then f(x) = 2x+1 is one-one.
• If function f: R→ R, then f(x) = x2 is not an injective function, because here

if x = -1, then f(-1) = 1 = f(1). Hence, the element of co-domain is not discrete here.

• If function f: R→ R, then f(x) = x/2 is one-one.
• If function f: R→ R, then f(x) = x3 is one-one.
• If function f: R→ R, then f(x) = 4x+5 is one-one.

## Properties of One-One Function

• If f and g are both one to one, then f ∘ g follows one-one.
• If g ∘ f is one to one, then function f is one to one, but function g may not be.
• f: X → Y is one-one, if and only if, given any functions g, h : P → X whenever f ∘ g = f ∘ h, then g = h..
• If f: X → Y is one-one and P is a subset of X, then f-1 (f(A)) = P. Thus, P can be retrieved from its image f(P).
• If f: X → Y is one-one and P and Q are both subsets of X, then f(P ∩ Q) = f(P) ∩ f(Q).
• If both X and Y are limited with the same number of elements, then f: X → Y is one-one, if and only if f is surjective or onto function.

Example :

Show that f: R→ R defined as f(a) = 3x3 – 4 is one to one function?

Solution:

Let f ( x1 ) = f ( x2 ) for all a1 , a∈ R

• 3x13 – 4 = 3x23 – 4
• x13 = x23
• x13 – x23 = 0
• (x1 – x2) (x1 + x1x2 + x22) = 0
• x1 = x2 and (x12 + x1x2 + x22) = 0
• (x12 + x1x2 + x22) = 0 is not considered because there are no real values of x1 and x2.

Therefore,  the given function f is one-one.

Onto Function:

A function f: X → Y is said to be onto (or surjective), if every element of Y is the image of some element of X under f,(Codomain=Range)

i.e., for every y ∈ Y, there exists an element x in X such that f(x) = y. Properties of Onto Function:

• In the onto function, every element in the codomain will be assigned to at least one value in the domain.
• Every function that is an onto function has a right inverse.
• Every function which has a right inverse can be considered as an onto function.
• A function f: A →B is an onto, or surjective, function if the range of f equals the codomain of the function f.
• Let f: A →B be an arbitrary function then, every member of A has an image under f and all the images will be considered as members of T. The set R of these images can be considered as the range of the function f.

Example :

Find the number of onto functions from the set X = {1, 2, 3, 4} to the set y= {a, b, c} .

Given:

Set X = {1, 2, 3, 4}

Set Y = {a, b, c}

Here, n=4 and m=3

Now, substitute the values of m and n in the formula, we get

= 34 – 3C1(2)4 + 3C2(1)4

= 81 – 3 (16) + 3(1)

= 81 – 48 + 3

= 84-48

= 36

Thus, the number of onto functions from set X to set Y is 36.

One-one and Onto Function:

A function f: X → Y is said to be one-one and onto (or bijective), if f is both one-one and onto. One-one and Onto function

N.B.:

1) Let X and Y are two sets having m and n elements respectively.

Function f: Xà Y then total no. of functions= nm

2) total no. of one-one function = mPn   if m>=n  otherwise 0

3) total no. of onto function =r=1nnr(r)m (-1)n- if 1nm     otherwise 0.

4) total no. of Bijective function = m!. if m=n otherwise 0.

Example 1:

Find the domain and range of a function f(x) = 3x2 – 5.

Solution:

Given function:

f(x) = 3x2 – 5

We know the domain of a function is the set of input values for f(x), in which the function is real and defined.

The given function has no undefined values of x.

Thus, for the given function, the domain is the set of all real numbers.

Domain = [-∞, ∞]

Also, the range of a function comprises the set of values of a dependent variable for which the given function is defined.

Let y = 3x2 – 5

3x2 = y + 5

x2 = (y + 5)/3

x = √[(y + 5)/3]

Square root function will be defined for non-negative values.

So, √[(y + 5)/3] ≥ 0

This is possible when y is greater than y ≥ -5.

Hence, the range of f(x) is [-5, ∞).

Example 2:

Find the domain and range of a function f(x) = (2x – 1)/(x + 4).

Solution:

Given function is:

f(x) = (2x – 1)/(x + 4)

We know that the domain of a function is the set of input values for f(x), in which the function is real and defined.

The given function is not defined when x + 4 = 0, i.e. x = -4

So, the domain of given function is the set of all real number except -4.

i.e. Domain = (-∞, -4) U (-4, ∞)

Also, the range of a function comprises the set of values of a dependent variable for which the given function is defined.

Let y = (2x – 1)/(x + 4)

xy + 4y = 2x – 1

2x – xy = 4y + 1

x(2 – y) = 4y + 1

x = (4y + 1)/(2 – y)

This is defined only when y is not equal to 2.

Hence, the range of the given function is (-∞, 2) U (2, ∞).

Example 3 :

The number of bijective functions from set A to itself when A contains 50 elements is

(A) 50

(B) 50!

(C) 502

(D) 250

Solution:

n(A) = m = 50

The number of bijective functions = m!

= 50!

Hence, option B is the answer.

Example 4: Given that the set A = {1, 2, 3}, set B = {4, 5} and let the function f = {(1, 4), (2, 5), (3, 5)}. Show that the function f is a surjective function from A to B.

Solution: Domain = set A = {1, 2, 3}

We can see that the element from set A, 1 has an image 4, and both 2 and 3 have the same image 5. Thus, the range of the function is {4, 5} which is equal to set B.

So  F: A →B is an onto function.

Therefore, the given function f is a surjective function.

Example 5 : Prove that the function f: N → N, defined by f(x) = x2 + x + 1, is one-one but not onto

Solution:

Given f: N → N, defined by f(x) = x2 + x + 1

Now we have to prove that given function is one-one

Injectivity:

Let x and y be any two elements in the domain (N), such that f(x) = f(y).

⇒ x2 + x + 1 = y2 + y + 1

⇒ (x2 – y2) + (x – y) = 0 `

⇒ (x + y) (x- y ) + (x – y ) = 0

⇒ (x – y) (x + y + 1) = 0

⇒ x – y = 0 [x + y + 1 cannot be zero because x and y are natural numbers

⇒ x = y

So, f is one-one.

Surjectivity:

When x = 1

x2 + x + 1 = 1 + 1 + 1 = 3

⇒ x2 + x +1 ≥ 3, for every x in N.

⇒ f(x) will not assume the values 1 and 2.

So, f is not onto.

Example 6 :

Let A = {−1, 0, 1} and f = {(x, x2) : x ∈ A}. Show that f : A → A is neither one-one nor onto.

Solution:

Given A = {−1, 0, 1} and f = {(x, x2): x ∈ A}

Also given that, f(x) = x2

Now we have to prove that given function neither one-one or nor onto.

Injectivity:

Let x = 1

Therefore f(1) = 12=1 and

f(-1)=(-1)2=1

⇒ 1 and -1 have the same images.

So, f is not one-one.

Surjectivity:

Co-domain of f = {-1, 0, 1}

f(1) = 12 = 1,

f(-1) = (-1)2 = 1 and

f(0) = 0

⇒ Range of f  = {0, 1}

So, both are not same.

Hence, f is not onto

Example 7 :

Let A = [-1, 1]. Then, discuss whether the following function from A to itself is one-one, onto or bijective:

(i) f (x) = x/2

(ii) g (x) = |x|

(iii) h (x) = x2

Solution:

(i) Given f: A → A, given by f (x) = x/2

Now we have to show that the given function is one-one and on-to

Injection test:

Let x and y be any two elements in the domain (A), such that f(x) = f(y).

f(x) = f(y)

x/2 = y/2

x = y

So, f is one-one.

Surjection test:

Let y be any element in the co-domain (A), such that f(x) = y for some element x in A (domain)

f(x) = y

x/2 = y

x = 2y, which may not be in A.

For example, if y = 1, then

x = 2, which is not in A.

So, f is not onto.

So, f is not bijective.

(ii) Given g: A → A, given by g (x) = |x|

Now we have to show that the given function is one-one and on-to

Injection test:

Let x and y be any two elements in the domain (A), such that f(x) = f(y).

g(x) = g(y)

|x| = |y|

x = ± y

So, f is not one-one.

Surjection test:

For y = -1, there is no value of x in A.

So, g is not onto.

So, g is not bijective.

(iii) Given h: A → A, given by h (x) = x2

Now we have to show that the given function is one-one and on-to

Injection test:

Let x and y be any two elements in the domain (A), such that h(x) = h(y).

h(x) = h(y)

x2 = y2

x = ±y

So, f is not one-one.

Surjection test:

For y = – 1, there is no value of x in A.

So, h is not onto.

So, h is not bijective.

Example 8 :

Are the following set of ordered pair of a function? If so, examine whether the mapping is injective or surjective:

(i) {(x, y): x is a person, y is the mother of x}

(ii) {(a, b): a is a person, b is an ancestor of a}

Solution:

Let f = {(x, y): x is a person, y is the mother of x}

As, for each element x in domain set, there is a unique related element y in co-domain set.

So, f is the function.

Injection test:

As, y can be mother of two or more persons

So, f is not injective.

Surjection test:

For every mother y defined by (x, y), there exists a person x for whom y is mother.

So, f is surjective.

Therefore, f is surjective function.

(ii) Let g = {(a, b): a is a person, b is an ancestor of a}

Since, the ordered map (a, b) does not map ‘a’ – a person to a living person.

So, g is not a function.

Example 9:

. Let A = {1, 2, 3}. Write all one-one from A to itself.

Solution:

Given A = {1, 2, 3}

Number of elements in  A = 3

Number of one-one functions = number of ways of arranging 3 elements = 3! = 6

(i) {(1, 1), (2, 2), (3, 3)}

(ii) {(1, 1), (2, 3), (3, 2)}

(iii) {(1, 2 ), (2, 2), (3, 3 )}

(iv) {(1, 2), (2, 1), (3, 3)}

(v) {(1, 3), (2, 2), (3, 1)}

(vi) {(1, 3), (2, 1), (3,2 )}

Example 10 :

If f: R → R be the function defined by f(x) = 4x3 + 7, show that f is a bijection.

Solution:

Given f: R → R is a function defined by f(x) = 4x3 + 7

Injectivity:

Let x and y be any two elements in the domain (R), such that f(x) = f(y)

⇒ 4x+ 7 = 4y+ 7

⇒ 4x= 4y3

⇒ x= y3

⇒ x = y

So, f is one-one.

Surjectivity:

Let y be any element in the co-domain (R), such that f(x) = y for some element x in R (domain)

f(x) = y

⇒ 4x+ 7 = y

⇒ 4x= y − 7

⇒ x3 = (y – 7)/4

⇒ x = ∛(y-7)/4 in R

So, for every element in the co-domain, there exists some pre-image in the domain. f is onto.

Since, f is both one-to-one and onto, it is a bijection.