I'm working on a problem from an old textbook that involves composite functions, domains, and equalities that are valid within a given domain. After being given f(x)=1/(1-x), I'm asked to find the domain of a composite function, as shown here:
x < 0 || 0 < x < 1 || x > 1
Then, I'm asked to prove that Composite[f,f,f][x] is equal to x for all x in the domain of Composite[f,f,f][x]. This is how I chose to prove it.
Resolve[ForAll[x, Element[x, FunctionDomain[f@*f@*f@x, x]],
f@*f@*f@x == x]]
Instead of Mathematica returning a "True" or some kind of thumbs-up, it returned
Resolve::elemc: Unable to resolve the domain or region membership condition x\[Element](x<0||0<x<1||x>1). >>
So, I tried using Reals for the domain in Element, and Mathematica returned "True".
In:= f[x_] := 1/(1 - x); Resolve[
ForAll[x, Element[x, Reals], f@*f@*f@x == x]]
But how can that be? The composite function goes to infinity for x=0 and x=1.
It's likely that I don't completely understand the data-types that Resolve, ForAll, Element, and FunctionDomain are using and returning. Or, maybe I completely missed something simple. That's likely, too. How can I make this yield what I expect to see? Thanks! (Notebook attached, too. Problem at the very bottom.)