Composition preserves homotopy

1.3k Views Asked by At

I have to prove that, given continuous functions between topological spaces $f,g:X\to Y$ and $h,k:Y\to Z$, we have $$f\simeq g,\quad h\simeq k\qquad\Rightarrow\qquad hf\simeq kg.$$ I would like to ask if the following proof is correct. Since $f\simeq g$ and $h\simeq k$, there exist continuous functions $$\varphi:X\times I\to Y\qquad\text{and}\qquad\psi:Y\times I\to Z,$$ with $I=[0,1]$ the euclidean interval, such that $$\begin{cases} \varphi(x,0)=f(x)\\ \varphi(x,1)=g(x) \end{cases} \qquad\text{and}\qquad \begin{cases} \psi(y,0)=h(y)\\ \psi(y,1)=k(y) \end{cases}$$ for all $x\in X$ and $y\in Y$. Define $\tau:X\times I\to Z$ like this: $$\tau(x,t)=\psi\big(\varphi(x,t),t\big).$$ Then $\tau$ should be continuous and such that $$\begin{cases} \tau(x,0)=hf(x)\\ \tau(x,1)=kg(x), \end{cases}$$ so it should be a homotopy $\tau:hf\simeq kg$. Is this proof OK or did I get something wrong? Thank you very much!