Question:

If \( f : \mathbb{R} \to \mathbb{R} \) and \( g : \mathbb{R} \to \mathbb{R} \) be functions defined by \( f(x) = \cos x \) and \( g(x) = 3x^2 \) respectively, then prove that \( g \circ f \neq f \circ g \).

Show Hint

{Key Points:}
  • \( g \circ f \) means apply \( f \) first, then \( g \)
  • \( f \circ g \) means apply \( g \) first, then \( f \)
  • Function composition is generally not commutative
  • To prove inequality, a single counterexample is sufficient
Updated On: Feb 24, 2026
Hide Solution
collegedunia
Verified By Collegedunia

Solution and Explanation


Step 1: Find \( g \circ f \) \[ (g \circ f)(x) = g(f(x)) = g(\cos x) = 3(\cos x)^2 = 3\cos^2 x \]
Step 2: Find \( f \circ g \) \[ (f \circ g)(x) = f(g(x)) = f(3x^2) = \cos(3x^2) \]
Step 3: Compare \( g \circ f \) and \( f \circ g \) \[ (g \circ f)(x) = 3\cos^2 x \] \[ (f \circ g)(x) = \cos(3x^2) \]
Step 4: Show they are not equal by counterexample Take \( x = 0 \): \[ (g \circ f)(0) = 3\cos^2 0 = 3(1)^2 = 3 \] \[ (f \circ g)(0) = \cos(3 \times 0^2) = \cos 0 = 1 \] Since \( 3 \neq 1 \), we have \( (g \circ f)(0) \neq (f \circ g)(0) \).
Step 5: Conclusion Since \( (g \circ f)(x) \neq (f \circ g)(x) \) for at least one value of \( x \) (here \( x = 0 \)), the two composite functions are not equal. Therefore: \[ \boxed{g \circ f \neq f \circ g} \]
Was this answer helpful?
0
0