What is the domain of the composite function (g@f)(x)(gf)(x)?

1 Answer
May 10, 2015

Since the notation for the composition (g\circ f)(x)=g(f(x))(gf)(x)=g(f(x)) means to first apply ff to xx to get f(x)f(x) and then to apply gg to f(x)f(x) to get g(f(x))g(f(x)), a point xx will be in the domain of g\circ fgf if and only if xx is in the domain of ff and f(x)f(x) is in the domain of gg.

For example, let f(x)=\frac{x+3}{x-4}f(x)=x+3x4 and g(x)=\frac{x-2}{x+5}g(x)=x2x+5. The number x=4x=4 is not in the domain of ff and is therefore not in the domain of g\circ fgf. Is there another number that's not in the domain of g\circ fgf? Yes, any value(s) of xx such that f(x)=-5f(x)=5 is/are not in the domain of g\circ fgf since -55 is not in the domain of gg. In order for f(x)=-5f(x)=5, we must have x+3=-5(x-4)=-5x+20x+3=5(x4)=5x+20 or 6x=176x=17 or x=17/6x=176. The domain of g\circ fgf is therefore \{x\in R: x!= 4 \mbox{ and } x!=17/6\}{xR:x4 and x176}.

If you find a simplified formula for g\circ fgf in such an example, you can be misled in what the correct answer is. In the example above, we can write (g\circ f)(x)=\frac{f(x)-2}{f(x)+5}=\frac{\frac{x+3}{x-4}-2}{\frac{x+3}{x-4}+5}=\frac{x+3-2(x-4)}{x+3+5(x-4)}=\frac{-x+11}{6x-17}(gf)(x)=f(x)2f(x)+5=x+3x42x+3x4+5=x+32(x4)x+3+5(x4)=x+116x17.

This simplified formula can mislead you into thinking that 17/6176 is the only number not in the domain of g\circ fgf, but it's not. The number 44 is also not in the domain as we saw above.

Why does this happen? The reason is that the equality \frac{\frac{x+3}{x-4}-2}{\frac{x+3}{x-4}+5}=\frac{x+3-2(x-4)}{x+3+5(x-4)}x+3x42x+3x4+5=x+32(x4)x+3+5(x4) is not true if x=4x=4, because the expression on the left-hand side is undefined there. So, in doing the simplification above, we were implicitly assuming that x!=4x4.