- Q^TG^{-1} Q + e^T e \ ,$$ where we introduce the frame fields $$G= \kappa^T \kappa \ , \quad e= \kappa \left( L + G^{-1} Q \right) .$$

We perform the dualisation by introducing a $\mathfrak{h}$-valued connection with components $A_{\pm} = A_{\pm}^{a}H_{a}$ and a $\mathfrak{h}^\star$-valued Lagrange multiplier $V= v_{a} \tilde{H}^{a}$. We covariantise currents $$J^{\nabla}_{\pm} = g^{-1} d g + g^{-1} A_{\pm } g \ ,$$ such that we are gauging a left action of some $\tilde{h} \in H$ $$g \rightarrow \tilde{h} g \ , \quad A \rightarrow \tilde{h} A \tilde{h} ^{-1} - d \tilde{h} \tilde{h}^{-1} \ ,$$ and consider $${\cal L }^{ \nabla} = {\operatorname{Tr}}(J^{\nabla}_+ P(J^{\nabla}_-) ) + {\operatorname{Tr}}(V F_{+ -} ) \ ,$$ where the field strength is $F_{+-} = \partial_{+} A_{-} - \partial_{-} A_{+} + [A_{+} , A_{-}]$.

We continue by gauge fixing on the group element $g = \hat{g}$ i.e. $h=1$.[^2] Integrating the Lagrange multipliers enforces a flat connection and one recovers the starting model since $$\label{eq:puregauge}
A_\pm = h^{-1}\partial_\pm h = L_\pm \ ,$$ and upon substituting back into the action one recovers the starting $\sigma$-model.

On the other hand, integrating by parts the derivative terms of the gauge fields yields $${\cal L }^{ \nabla} = {\operatorname{Tr}}(\hat{J}_{+} P(\hat{J}_-) ) + A_{+}^{a}A_{-}^{b} M_{ab} + A_{+}^{a}( \partial_{-} v_{a}+ Q_{-a} ) - A_{-}^{a}( \partial_{+} v_{a} - Q_{+a} ) \ ,$$ in which we have pulled back the one-forms $Q$ and $\hat{J}$ to the worldsheet and defined $$\begin{aligned}
F_{ab} &= {\operatorname{Tr}}([H_{a} ,H_{b}]V) = f_{ab}{}^{c} v_{c} \ , \quad M_{ab} =G_{ab} + F_{ab} \ .
\end{aligned}$$ The gauge field equations of motion now read $$\label{eq:gauge}
A_{-} = - M^{-1} ( \partial_{-} v + Q_{-} ) \ , \quad A_{+} = M^{-T} ( \partial_{+} v - Q_{+ } ) \ .$$ Combining these equations of motion for the gauge field in eqs.  and sets up the canonical transformation between T-dual theories. Substitution of the gauge field equation of motion into the action yields