Justification for g being a one to one function If $f$ and $f\circ g$ are one to one functions, is $g$ also a one to one function? Justify your answer.
I am guessing that $g$ should be a one to one function.
So a function $F$ is injective if:
$\forall a \forall b(F(a)=F(b) \Rightarrow a=b)$
So since $f$ is injective:
$\forall a \forall b(f(a)=f(b) \Rightarrow a=b)$
And $f\circ g$ is also injective:
$\forall a \forall b(f \circ g(a)=f \circ g(b) \Rightarrow g(a)=g(b))$
$\forall a \forall b(g(a)=g(b) \Rightarrow a=b)$
Does this show that $g$ must also be injective?
 A: You proof doesn't seems correct. Anyway, take $a,b$ such that $g(a)=g(b)$. So $fg(a)=fg(b)$. But $fg$ is injective, so $a=b$. The injective of $f$ doesn't seem important as hypotesis.
A: Let's prove the contrapositive!  If $g$ is not injective, then there exist two distinct elements $a$ and $b$ in the domain of $g$ such that $g(a) = g(b)$.  Let $c = g(a)$.  Then $$(f \circ g)(a) = f(g(a)) = f(c) = f(g(b)) = (f \circ g)(b),$$ and so $f \circ g$ is also not injective.
Thus, if $g$ is not injective, then $f \circ g$ is not injective.  By contraposition, this is equivalent to the statement that if $f \circ g$ is injective, then $g$ is also injective, which we were asked to prove.

(Note that we did not, in fact, have to use the assumption that $f$ is also injective anywhere, and indeed the same result holds even if $f$ is not injective.  However, while $f \circ g$ being injective does not imply that $f$ is injective, we can prove that it implies that the restriction of $f$ to the range of $g$ must be injective.)
