Find \(g \circ f\) and \(f \circ g\) for \(f(x)=x\) and \(g(x)=|x|\)
📺 Video Explanation
📝 Question
Let functions \(f:\mathbb{R}\to\mathbb{R}\) and \(g:\mathbb{R}\to\mathbb{R}\) be defined as:
\[ f(x)=x,\qquad g(x)=|x| \]
Find:
- \((g\circ f)(x)\)
- \((f\circ g)(x)\)
✅ Solution
🔹 Find \((g\circ f)(x)\)
By definition:
\[ (g\circ f)(x)=g(f(x)) \]
Since:
\[ f(x)=x \]
Substitute:
\[ g(f(x))=g(x) \]
Now:
\[ g(x)=|x| \]
Therefore:
\[ \boxed{(g\circ f)(x)=|x|} \]
🔹 Find \((f\circ g)(x)\)
By definition:
\[ (f\circ g)(x)=f(g(x)) \]
Substitute:
\[ f(|x|) \]
Since:
\[ f(x)=x \]
The identity function returns the same input:
\[ f(|x|)=|x| \]
Therefore:
\[ \boxed{(f\circ g)(x)=|x|} \]
🎯 Final Answer
\[ \boxed{(g\circ f)(x)=|x|} \]
\[ \boxed{(f\circ g)(x)=|x|} \]
🚀 Exam Shortcut
- Identity function means output = input
- So composing with identity leaves function unchanged
- Hence both compositions are \(|x|\)