Solution (source code)

= Solution

Write $\xi_P(p)=\left.\frac d{dt}\right|_0\exp(t\xi)\cdot p$ for the <fundamental vector field> of a left <Lie group action>, and use $\iota_{X_f}\omega=df$ throughout. Such fundamental fields satisfy $[\xi_P,\eta_P]=-[\xi,\eta]_P$. A <moment map> has linear components $\mu_\xi=\langle\mu,\xi\rangle$ satisfying
$$
d\mu_\xi=\iota_{\xi_P}\omega.
$$
For the action to be <Hamiltonian>, these components can be chosen equivariantly, or, infinitesimally,
$$
\boxed{\{\mu_\xi,\mu_\eta\}=\mu_{[\xi,\eta]}.}
$$
This identifies the span of the component Hamiltonians with the Lie algebra image, rather than identifying the entire infinite-dimensional <Poisson algebra> $C^\infty(P)$ with $\mathfrak g$. For an actual isomorphism with $\mathfrak g$, injectivity is also needed; a faithful infinitesimal action supplies it.

Preservation of $\omega$ alone gives $d\iota_{\xi_P}\omega=0$, not necessarily exactness. For example, translation generated by $\partial_q$ on the symplectic two-torus has contraction $dp$, whose period is nonzero. That action has no globally defined component Hamiltonian. Once the contractions are exact, choose Hamiltonians linearly in $\xi$. On each connected component of $P$, the discrepancy
$$
\kappa(\xi,\eta)=\{\mu_\xi,\mu_\eta\}-\mu_{[\xi,\eta]}
$$
is constant: apply $[X_f,X_g]=-X_{\{f,g\}}$ and the fundamental-field bracket. The <Jacobi identity> makes $\kappa$ a <Lie algebra two-cocycle>. Replacing $\mu_\xi$ by $\mu_\xi+b(\xi)$ changes it to $\kappa(\xi,\eta)-b([\xi,\eta])$. Thus the exactness condition and vanishing of this <moment-map equivariance obstruction> are precisely the required infinitesimal conditions.

For a <semisimple Lie algebra>, both hold. First <Cartan's magic formula> gives
$$
\iota_{[\xi_P,\eta_P]}\omega=d(\iota_{\xi_P}\iota_{\eta_P}\omega)
=-d[\omega(\xi_P,\eta_P)],
\qquad \iota_{[\xi,\eta]_P}\omega=d[\omega(\xi_P,\eta_P)].
$$
Semisimplicity implies $[\mathfrak g,\mathfrak g]=\mathfrak g$, so every generator is a sum of commutators and has a globally exact contraction. This proves <Hamiltonian existence for a semisimple symplectic action>.

Next use the nondegenerate <Killing form> to define $D$ by $B(D\xi,\eta)=\kappa(\xi,\eta)$. Antisymmetry makes $D$ skew for $B$. The cocycle identity and invariance of $B$ imply $D[\xi,\eta]=[D\xi,\eta]+[\xi,D\eta]$, so $D$ is a derivation. Choose $Z$ by
$$
B(Z,\xi)=\operatorname{tr}(D\operatorname{ad}\xi).
$$
Then, using cyclicity of trace and $[D,\operatorname{ad}\xi]=\operatorname{ad}(D\xi)$,
$$
B([Z,\xi],\eta)=\operatorname{tr}(D[\operatorname{ad}\xi,\operatorname{ad}\eta])
=\operatorname{tr}([D,\operatorname{ad}\xi]\operatorname{ad}\eta)=B(D\xi,\eta).
$$
Hence $D=\operatorname{ad}Z$ and $\kappa(\xi,\eta)=B(Z,[\xi,\eta])$. Taking $b(\xi)=B(Z,\xi)$ removes the cocycle and proves <semisimple moment-map equivariance> without merely invoking a cohomology theorem. For a connected group, integrate the infinitesimal equivariance along its one-parameter subgroups to obtain group equivariance. A disconnected group can require an additional discrete-equivariance check.