Show that the linear transformation T is invertible 
(Application of the rank-nullity theorem) Suppose $S,T: V\to V$ are linear transformations of a finite dimensional vector space $V$, and that the composition $ST\colon V\to V$ is invertible. Show that then $T$ is one-to-one, and deduce that it is invertible. Show also that $S$ is invertible. Deduce that $ST$ is invertible if and only if $TS$ is invertible.

I'm not remotely sure how to apply the rank-nullity theorem here. Also, I thought it was self-evident that T and S would have to be invertible since as far as I know the inverse of a composition involves the composition of inverses (and if a matrix is invertible it's definitely one-to-one).
Any help would be greatly appreciated!
 A: In general, it's possible for a composition to be invertible and neither function to be invertible: take $f\colon\{a\}\to\{1,2\}$ given by $f(a)=1$, and $g\colon\{1,2\}\to\{x\}$ given by $g(1)=g(2)=x$. Neither $f$ nor $g$ are invertible ($f$ is not onto, $g$ is not one-to-one) but $gf\colon\{a\}\to\{x\}$ is clearly invertible. 
What is true is that if $f$ and $g$ are invertible and you can compose them, then $gf$ is invertible and $(gf)^{-1} = f^{-1}g^{-1}$. But you cannot conclude that $f$ and $g$ are each invertible from the assumption that $gf$ is invertible.
For a linear example, take $T\colon\mathbb{R}^2\to\mathbb{R}^3$ given by $T(x,y) = (x,y,x-y)$ (not onto), and $S\colon\mathbb{R}^3\to\mathbb{R}^2$ given by $S(x,y,z) = (x,y)$ (not one-to-one). Neither $T$ nor $S$ are invertible, but $ST\colon\mathbb{R}^2\to\mathbb{R}^2$ is invertible.
For a linear example with maps from the a vector space to itself, necessarily infinite dimensional in view of the theorem above, take the vector space of all sequences of real numbers, and let $T$ be the "right shift" operator and $S$ the "left shift" operator. that is, $T(a_1,a_2,a_3,\ldots) = (0,a_1,a_2,\ldots)$, and $S(a_1,a_2,a_3,\ldots) = (a_2,a_3,\ldots)$. Check that neither $T$ nor $S$ are invertible, but that $ST$ is the identity map, hence invertible.
So: first assume that $ST$ is invertible. Use this to show that $T$ must be one-to-one. 
Added hint: To show that $T$ is one-to-one, you want to show that if $\mathbf{v}\in V$ is such that $T(\mathbf{v})=\mathbf{0}$, then $\mathbf{v}=\mathbf{0}$ (that is, the only vector that goes to $\mathbf{0}$ is the zero vector; we're showing the nullspace of $T$ is trivial, or that the nullity is $0$). So, let $\mathbf{v}$ be a vector in $V$ such that $T(\mathbf{v})=\mathbf{0}$. What is $ST(\mathbf{v})$? What does that tell you about $\mathbf{v}$? What does that tell you about $T$ (and why)?
Once you know that $T$ is one-to-one, then you can use the Rank-Nullity Theorem to conclude that since $T$ is one-to-one and maps from $V$ to itself ($V$ finite dimensional), then $T$ is invertible. And then you can use that both $ST$ and $T$ are invertible (and hence both $ST$ and $T^{-1}$ are invertible) to show that $S$ is invertible. And if both $S$ and $T$ are invertible, then show that $TS$ is invertible. This proves that if $ST$ is invertible, then $TS$ is invertible; the converse follows by simply swapping the roles of $S$ and $T$.
A: There is a much stronger result which is not really harder to prove:

Let $K$ be a commutative ring, let $V$ be a finitely generated $K$-module, let $T$ be a surjective $K$-linear endomorphism of $V$. Then $T$ is injective.

Indeed, let $(v_j)$ be a finite system generating $V$. Each $v_j$ can be written as 
$$
v_j=T\ \ \sum_k\ a_{jk}\ v_k
$$
for some $a_{jk}$ in $K$. In other words we have 
$$
\sum_k\ (\delta_{jk}-a_{jk}T\ )\ v_k=0
$$
(where $\delta$ is Kronecker's delta), i.e. the elements 
$$
b_{jk}:=\delta_{jk}-a_{jk}T\in K[T]
$$
satisfy 
$$
\sum_k\ b_{jk}\ v_k=0.
$$
If $(c_{ij})$ is the adjugate of the matrix $(b_{jk})$, we get 
$$
\sum_j\ c_{ij}\ b_{jk}=\delta_{ik}\ \Delta,\quad\Delta:=\det(b_{jk})\in K[T].
$$ 
Let's compute 
$$
w_i:=\sum_{j,k}\ c_{ij}\ b_{jk}\ v_k\in V
$$
in two ways. On the one hand we have 
$$
w_i=\sum_j\ c_{ij}\ \sum_k\ b_{jk}\ v_k=0.
$$
On the other hand we have 
$$
w_i=\sum_k\ \left(\sum_j\ c_{ij}\ b_{jk}\right)v_k=\sum_k\ \delta_{ik}\ \Delta v_k=\Delta v_i.
$$
This implies $\Delta v_i=0$ for all $i$, and thus $\Delta v=0$ for all $v$ in $V$.
But we also have 
$$
\Delta=1-p(T)\ T
$$
for some $p$ in $K[X]$ (where $X$ is an indeterminate), and thus 
$$
\text{Id}_V=p(T)\ T,
$$
which implies indeed that $T$ is injective.
A: If $A:=S\circ T: V\to V$ is "invertible" (i.e., bijective) then $T$ has to be injective (i.e., one-one), or one would not find a unique pre-image $A^{-1}y$ for some $y\in V$, and $S$ has to be surjective (i.e., onto), or $A^{-1}$ would not be defined on all of $V$. An injective $T:V\to V$ is automatically bijective (this is a fundamental theorem of linear algebra), and similarly a surjective $S:V\to V$ is automatically bijective.  Now that both $T$ and $S$ are verified to be bijective it follows that the same is true for $TS$. Conversely, the bijectivity of $TS$ implies the bijectivity of $ST$. (Actually it would be enough to assume the composition $ST$ injective resp. surjective only.)
A: You can pass to a matrix representation on the same basis of V as domain and codomain.
Then the matrix of the composition is the product of the two matices.
The product of two square matrices is invertible if and only if each of them is invertible.
After this you know that a linear transformation is invertible if and only if a matrix that  represents it  is invertible.
