I'm trying to solve the following problem but I'm having a lot of difficulty with it.
Let $X$ be a topological space, and let $f$ be a loop in $X$ with base point $x_0$. Now consider the following homeomorfism $g:I\to I$. Show that $[f\circ g][f]=[e_{x_0}]$ or $[f\circ g][f]^{-1}=[e_{x_0}]$ in $\pi_1(X,x_0)$.
I'm totally lost on how to even begin with such a problem so any help is greatly appreciated.
You consider a homeomorphism $g : I \to I$. The boundary points $b_0 = 0,b_1 = 1$ of $I$ are mapped to distinct points $b'_0 = g(b_0) , b'_1 = g(b_1)$ of $I$. The $b'_i$ must be boundary points of $I$: The sets $I \setminus \{b_i\}$ are connected, thus also the sets $g(I \setminus \{b_i\}) = I \setminus \{b'_i\}$ are connected which is possible only when $b'_i \in \{0,1\}$.
Case 1. $g(0) = 0, g(1) = 1$.
$f \circ g$ is path homotopic to $f$ via
$$H : I \times I \to X, H(s,t) = f(ts + (1-t)g(s)) .$$ Note that $ts + (1-t)g(s) \in I$ because $I$ is convex and $s, g(s) \in I$. We have $H(s,0) = (f \circ g)(s), H(s,1) = f(s)$ for all $s$ and $H(b_i,t) = b_i$ for all $t$.
Thus $[f \circ g] = [f]$ and therefore $[f\circ g][f]^{-1}=[e_{x_0}]$.
Case 2. $g(0) = 1, g(1) = 0$.
In this case $f \circ g$ is path homotopic to the map $f^{-} : I \to X, f^{-}(s) = f(1-s)$, via
$$H : I \times I \to X, H(s,t) = f(t(1 - s) + (1-t)g(s))) .$$
Thus $[f \circ g] = [f^-] = [f]^{-1}$ and therefore $[f\circ g][f]=[e_{x_0}]$.