Relative Homotopy is Equivalence Relation

Theorem
Homotopy is an equivalence relation.

Proof
We examine each condition for equivalency.

Reflexivity:

For any function $$f:X \to Y$$, define $$F:X\times [0,1] \to Y$$ as $$F(x,t)=f(x)$$.

This yields a smooth homotopy between $$f$$ and itself.

Symmetry:

Given a homotopy $$F: X \times [0,1] \to Y$$ from $$f(x)=F(x,0)$$ to $$g(x)=F(x,1)$$, the function $$G(x,t)=F(x,1-t)$$ is a homotopy from $$g$$ to $$f$$.

Thus $$G$$ is smooth whenever $$F$$ is.

Transitivity:

The continuous case admits of a simpler solution than the smooth case, but the smooth case implies the continuous case, so we examine only the smooth case.

Define the function $$\beta (x) = \begin{cases} e^{-1/(1-x^2)} & \mbox{ for } |x| < 1\\ 0 & \mbox{ otherwise} \end{cases} $$

This function is known to be smooth.

Define $$\phi (t) = \tfrac{\int_{0}^{t} \beta (\tfrac{x+2}{4}) dx}{\int_{0}^{1} \beta (\tfrac{x+2}{4} )dx}$$

By construction, $$\phi$$ is a smooth function which is 0 for all $$t \leq 1/4$$, 1 for all $$t \geq 3/4$$, and rises smoothly from 0 to 1 in $$(\tfrac{1}{4}, \tfrac{3}{4})$$.

Let $$f,g,h$$ be smooth functions such that $$f$$ is homotopic to $$g$$, which is in turn homotopic to $$h$$.

Then we can define the smooth homotopies:

$$A(x,t) = \phi(t)g(x)+(1-\phi(t))f(x) \,\! $$, which satisfies $$A(x,0)=f(x) \,\!$$ and $$A(x,1)=g(x)\,\!$$, and

$$B(x,t) = \phi(t)h(x)+(1-\phi(t))g(x) \,\! $$, which satisfies $$B(x,0)=g(x) \,\!$$ and $$B(x,1)=h(x)\,\!$$

We then define a smooth function:

$$C(x,t) = \begin{cases} A(x,\tfrac{t}{2}) & \mbox{if } t \leq \tfrac{1}{2}  \\ B(x,\tfrac{t+1}{2})  & \mbox{if } t > \tfrac{1}{2}, \end{cases} $$

$$C$$ is a smooth function satisfying $$C(x,0)=f(x)$$ and $$C(x,1)=h(x)$$, so it is a homotopy from $$f$$ to $$h$$.