Let $G$ be a Lie group and $P \to M$ a principal $G$-bundle over a closed Riemann surface. The gauge group $\mathcal{G}$ is defined by


$$\mathcal{G}=\lbrace f : P \to G \mid f(p \cdot g) = g^{-1}f(p)g\ (\forall g \in G, p \in P) \rbrace.$$


I want to understand the following statement which I found in Atiyah-Bott ([Roy. Soc. London Ser. A 308](http://rsta.royalsocietypublishing.org/content/308/1505/523)).



> 
> PROPOSITION 2.4. Let $BG$ be the classifying space for $G$. Then in homotopy theory
>  $$B\mathcal{G} = \mathrm{Map}\_P(M,BG).$$ Here the subscript $P$
>  denotes the component of a map of $M$ into $BG$ which induces $P$.
> 
> 
> 


This is proved by showing that $\pi:\mathrm{Map}\_G(P,EG) \to \mathrm{Map}\_P(M,BG)$ is a universal $\mathcal{G}$-bundle. 


My questions: 


1. Why is $\mathrm{Map}\_G(P,EG)$ contractible?
2. How do we see that $\pi:\mathrm{Map}\_G(P,EG) \to \mathrm{Map}\_P(M,BG)$ is locally trivial? Here for a $G$-equivariant map $f:P \to EG$, $\pi(f)$ is the map $P/G \to EG/G$ which is canonically induced by $f$.


Notes:


* It is easy to see that $\mathrm{Map}(P,EG)$ is contractible, because $EG$ is contractible. But, because of the $G$-actions, it does not seem that we can apply the same discussion to $\mathrm{Map}\_G(P,EG)$.
* For the second question, Atiyah and Bott say the following. But I can not understand it and I want to understand the details.



> 
> If $BG$ is paracompact and locally contractible, which is easily arranged, $\pi$ will be a locally trivial principal fibring, as follows easily from the homotopy properties of fibrings.
> 
> 
>
* If there is a good exposition of this problem, please let me know.



The classifying space of a gauge group
**Proof of (1):** 


(a). Suppose $X$ and $Y$ are $G$-spaces, the action of $G$ on $X$ is free, and $X\to X/G$ is
a principal bundle, then the space of $G$-equivariant maps 
$$
F(X,Y)^G
$$
is the same thing as the space of sections of the fibration $X\times\_G Y \to X/G$.


(b). If $E\to B$ is a Hurewicz fibration, with $B$ connected and the fiber contractible, then the space of sections is again contractible. This can be seen as follows: the adjunction property shows that 
$$
\text{sec}(E \to B) \to F(B,E) \to F(B,B)
$$
is a fibration (the displayed fiber is the space of sections---it's the fiber over the basepoint of $F(B,B)$ given by the identity map of $B$---and the other two spaces are function spaces). Since $F$ is contractible the map $E\to B$ is a homotopy equivalence and therefore so is $F(B,E) \to F(B,B)$. Hence $\text{sec}(E\to B)$ is contractible.


(c). It follows from (a) and (b) that the space of sections of $X\times\_G Y \to X/G$ is contractible whenever $Y$ is.


(d). In your case, $X = P$ and $Y = EG$. Hence, $F(P,EG)^G$ is contractible.


**Proof of (2):**


I'll prove something slightly less, which is enough for what 
you wish to have: 


I claim that 
if $X \to X/G$ and $Y \to Y/G$ are principal $G$-bundles then the map
$$
F(X,Y)^G \to F(X/G,Y/G)
$$
is a Hurewicz fibration. This is the same thing as the map
$$
\text{sec}(X\times\_G Y\to X/G) \to \text{sec}(X/G\times Y/G\to X/G)
$$
induced by the fibration $X\times\_G Y \to X/G \times Y/G$.


This map of section spaces is the map of fibers which is induced by a map of fibrations
over a common base space: the first fibration is $F(X/G, X\times\_G Y) \to F(X/G,X/G)$ and the second one is
$F(X/G, X/G\times Y/G) \to F(X/G,X/G)$. Since the map $F(X/G, X\times\_G Y) \to F(X/G, X/G\times Y/G)$ is a fibration, it is formal to show that the
map of section spaces is too. 


In your situation we take $X = P$ and $Y = EG$. Then we see that the map
$$
F(P,EG)^G \to F(P/G,BG)
$$
is a fibration. The fiber at the point of $F(P/G,BG)$ defined by the classifying map for $P \to P/G$ is then
your gauge group $\cal G$.


