Let $X$ and $Y$ be topological spaces, and let $f: X \to Y$. I'd like to show that if there are maps $g,h : Y \to X$ such that $fg$ and $hf$ are homotopy equivalences, then $f$ is a homotopy equivalences.
$fg$ is a homotopy equivalence means there is some map $k_1 : Y \to Y$ such that $fg k_1 \simeq \mathrm{id}_Y \simeq k_1 fg$. Similarly, there is some map $k_2 : X \to X$ with $hfk_2 \simeq \mathrm{id}_X \simeq k_2 hf$.
I want to find a map $k_3 : Y \to X$, comprising of compositions of $f, g, h, k_1$ and $k_2$, such that $f k_3 \simeq \mathrm{id}_Y$ and $k_3 f \simeq \mathrm{id}_X$. I simply cannot find such a $k_3$. Any ideas?
Thanks