Example Where \(g \circ f\) is Onto but \(f\) is Not Onto
📺 Video Explanation
📝 Question
Give examples of two functions:
\[ f:\mathbb{N}\to\mathbb{N},\qquad g:\mathbb{N}\to\mathbb{N} \]
such that:
\[ g\circ f \text{ is onto, but } f \text{ is not onto.} \]
✅ Solution
🔹 Choose Functions
Take:
\[ f(x)=x+1 \]
and
\[ g(x)= \begin{cases} x-1, & x>1 \\[4pt] 1, & x=1 \end{cases} \]
Both are functions from \(\mathbb{N}\to\mathbb{N}\).
🔹 Step 1: Show that \(f\) is not onto
Since:
\[ f(x)=x+1 \]
The smallest value in the range of \(f\) is:
\[ 2 \]
So:
\[ 1 \notin \text{Range}(f) \]
Hence, no natural number maps to 1.
Therefore:
\[ f \text{ is not onto} \]
🔹 Step 2: Find \(g\circ f\)
By definition:
\[ (g\circ f)(x)=g(f(x)) \]
Substitute:
\[ (g\circ f)(x)=g(x+1) \]
Since \(x+1>1\), use:
\[ g(x+1)=(x+1)-1=x \]
So:
\[ (g\circ f)(x)=x \]
🔹 Step 3: Show \(g\circ f\) is onto
Since:
\[ (g\circ f)(x)=x \]
This is identity function on \(\mathbb{N}\).
Therefore:
\[ g\circ f \text{ is onto} \]
🎯 Final Answer
One suitable example is:
\[ \boxed{f(x)=x+1} \]
and
\[ \boxed{ g(x)= \begin{cases} x-1, & x>1\\ 1, & x=1 \end{cases}} \]
Then:
\[ \boxed{g\circ f(x)=x} \]
So, \(g\circ f\) is onto but \(f\) is not onto.
🚀 Exam Shortcut
- Take \(f\) that skips first natural number
- Choose \(g\) to shift values back
- Then composition becomes identity