Definition:Homotopy

Definition
Let $X$ and $Y$ be topological spaces.

Let $f: X \to Y$, $g: X \to Y$ be continuous mappings.

Then $f$ and $g$ are homotopic if there exists a continuous mapping:
 * $H: X \times \left[{0 \,.\,.\, 1}\right] \to Y$

such that:
 * $H \left({x, 0}\right) = f \left({x}\right)$

and:
 * $H \left({x, 1}\right) = g \left({x}\right)$

$H$ is called a homotopy between $f$ and $g$.

Relative Homotopy
Let $X$ and $Y$ be topological spaces.

Let $K \subseteq X$ be a subset of $X$.

Let $f: X \to Y$, $g: X \to Y$ be continuous mappings.

We say that $f$ and $g$ a homotopic relative to $K$ if for all $x \in K$, $f(x) = g(x)$, and there exists a homotopy $H$ between $f$ and $g$ such that
 * $\forall x \in K \ \forall t \in [0,1]: H(x,t) = f(x)$

Also see

 * Homotopy Class
 * Smooth Homotopy