There are two function $f:\mathbb{Q} \rightarrow \mathbb{Q}\setminus \{-1\}, g:\mathbb{Q}\rightarrow\mathbb{Q}\setminus \{1\}$ such that for every $x\in\mathbb{Q}$, $g(x)=\frac{f(x)}{f(x)+1}$. Show that if $f$ is invertible, $g$ is invertible, and find an equation that depicts $g^{-1}$ by $f^{-1}$.
I proved that if $f$ is invertible then $g$ is invertible by showing that if $f$ is injective and surjective then $g$ is injective and surjective, but I don't know how to proceed with the second part of the question (finding the equation). Would appreciate your assistance. Thank you.
Suppose that $y=g(x)$. Then $$ y=\frac{f(x)}{f(x)+1}, $$ and $$ f(x)=\frac{y}{1-y}. $$ Thus $$ g^{-1}(y)=x=f^{-1}\Big(\frac y{1-y}\Big). $$