Assume $f:B_{1}\to B_{1}$ (where $B_{1}$ is the closed unit-ball in $\mathbb{R}^{n}$ ) is a continuous function that has no fixed points I need to construct a function $g:B_{1}\to B_{1}$ which is a retract, that is continuous and $g|_{\partial B_{1}}=\mbox{Id}$ . This is what I tried, define $a:B_{1}\to\mathbb{R}_{\geq0}$ such that $a\left(x\right)$ is the unique solution of $\left\Vert x-a\left(x\right)\cdot\left(f\left(x\right)-x\right)\right\Vert =1 .$ and define $g$ by $g\left(x\right)=x-a\left(x\right)\cdot\left(f\left(x\right)-x\right)$.
For any $\left\Vert x\right\Vert =1$ we get $a\left(x\right)=0$ and thus $g\left(x\right)=x$ meaning $g|_{\partial B_{1}}=\mbox{Id}$ like we want. Now if $a$ was continuous then $g$ would immediately be continuous and I would have what I need. Problem is I'm not sure how to show $a$ is continuous... Help would be appreciated
Let us use the definition $$\|x+a(x)(f(x)-x)\|=1$$ Then $$(x+a(x)(f(x)-x),x+a(x)(f(x)-x))=1$$ so $$\|x\|^2+2a(x)(x,f(x)-x)+a(x)^2\|f(x)-x\|^2=1$$ Thus $$a(x)=\frac{-2(x,f(x)-x)\pm\sqrt{4(x,f(x)-x)^2+4(1-\|x\|^2)\|f(x)-x\|^2}}{2\|f(x)-x\|^2}$$ and if we take the positive root we get $$a(x)=\frac{-2(x,f(x)-x)+\sqrt{4(x,f(x)-x)^2+4(1-\|x\|^2)\|f(x)-x\|^2}}{2\|f(x)-x\|^2}$$ which is guaranteed to be nonnegative and continuous.