Let $f: W \rightarrow W$ be defined as $f(n) = n-1$ if $n$ is odd and $f(n) = n+1$ if $n$ is even. Show that $f$ is invertible. Find the inverse of $f$. Here,$W$ is the set of all whole numbers.

Vedclass pdf generator app on play store
Vedclass iOS app on app store
(A) It is given that $f: W \rightarrow W$ is defined as:
$f(n) = \begin{cases} n-1 & \text{if } n \text{ is odd} \\ n+1 & \text{if } n \text{ is even} \end{cases}$
For one-one:
Let $f(n) = f(m)$.
If $n$ is odd and $m$ is even,then $n-1 = m+1 \Rightarrow n-m = 2$. This is impossible as the difference between an odd and an even number is always odd. Similarly,$n$ being even and $m$ being odd is impossible.
Therefore,$n$ and $m$ must have the same parity.
If both are odd,$n-1 = m-1 \Rightarrow n = m$.
If both are even,$n+1 = m+1 \Rightarrow n = m$.
Thus,$f$ is one-one.
For onto:
Any odd number $2r+1$ in the codomain is the image of $2r+2$ (which is even) or $2r$ (which is odd). Specifically,$f(2r+2) = 2r+1$ and $f(2r) = 2r+1$ is not the case here; rather,$f(2r+2) = 2r+3$ and $f(2r+1) = 2r$. Every $m \in W$ has a preimage. Thus,$f$ is onto.
Since $f$ is one-one and onto,it is invertible.
Let $g: W \rightarrow W$ be defined as $g(m) = \begin{cases} m+1 & \text{if } m \text{ is even} \\ m-1 & \text{if } m \text{ is odd} \end{cases}$.
We observe that $f(f(n)) = n$ for all $n \in W$.
If $n$ is odd,$f(n) = n-1$ (even),so $f(f(n)) = f(n-1) = (n-1)+1 = n$.
If $n$ is even,$f(n) = n+1$ (odd),so $f(f(n)) = f(n+1) = (n+1)-1 = n$.
Thus,$f \circ f = I_W$,which implies $f^{-1} = f$.

Explore More

Similar Questions

If a function $f: R \rightarrow R$ is defined by $f(x) = \frac{4x}{5} + 3$,then $f^{-1}(x) =$

Let $f(x) = (x - 1)^2 + 1$ for $x \ge 1$.
Statement-$1$: $S = \{x : f(x) = f^{-1}(x)\} = \{1, 2\}$.
Statement-$2$: $f$ is a bijection and $f^{-1}(x) = 1 + \sqrt{x - 1}$ for $x \ge 1$.

If $f: \mathbb{R} \to \mathbb{R}$ is defined by $f(x) = 3x - 4$,then ${f^{ - 1}}: \mathbb{R} \to \mathbb{R}$ is

If $f(x) = \frac{3x+2}{5x-3}$,where $x \in R - \{\frac{3}{5}\}$,then:

If $g$ is the inverse of a function $f$ and $f'(x) = \frac{1}{1 + x^5}$,then $g'(x)$ is equal to:

Vedclass Products

For Students

Vedclass Test Series

Mock tests in real JEE/NEET style with performance analysis. 5-day free trial.

Start Free Trial
For Teachers

Exam Paper Generator

Generate Set A/B/C/D exam papers from 7.5L+ questions in 2 minutes. 3 chapters free.

Try Free
For Institutes

Online Exam Module

Live online exams with unlimited students, 360° analytics & white-label branding.

See Demo