Question:

Let $N$ be the set of natural numbers and two functions $f$ and $g$ be defined as $f,g : N \to N$ such that : $f(n) = \begin{cases} \frac{n+1}{2} & \quad \text{if } n \text{ is odd}\\ \frac{n}{2} & \quad \text{if } n \text{ is even} \end{cases}$ and $g(n) = n-(-1)^n$. The $fog$ is :

Updated On: Feb 14, 2025
  • Both one-one and onto
  • One-one but not onto
  • Neither one-one nor onto
  • onto but not one-one
Hide Solution
collegedunia
Verified By Collegedunia

The Correct Option is D

Solution and Explanation

$f(x) = \begin{cases} \frac{n+1}{2} & \quad n \text{ is odd}\\ -(n+1)/2 & \quad n \text{ is even} \end{cases} $
$g(x) = n - (-1)^n \begin{cases} n+ 1 & ; \quad n \text{ is odd}\\ n - 1 &; \quad \text{if } n \text{ is even} \end{cases} $
$f(g(n)) = \begin{cases} \frac{n}{2} ; & \quad n \text{ is even}\\ \frac{n +1}{2} ; & \quad n \text{ is odd} \end{cases} $
$\therefore$ many one but one to one
Was this answer helpful?
0
0

Concepts Used:

Functions

A function is a relation between a set of inputs and a set of permissible outputs with the property that each input is related to exactly one output. Let A & B be any two non-empty sets, mapping from A to B will be a function only when every element in set A has one end only one image in set B.

Kinds of Functions

The different types of functions are - 

One to One Function: When elements of set A have a separate component of set B, we can determine that it is a one-to-one function. Besides, you can also call it injective.

Many to One Function: As the name suggests, here more than two elements in set A are mapped with one element in set B.

Moreover, if it happens that all the elements in set B have pre-images in set A, it is called an onto function or surjective function.

Also, if a function is both one-to-one and onto function, it is known as a bijective. This means, that all the elements of A are mapped with separate elements in B, and A holds a pre-image of elements of B.

Read More: Relations and Functions