If we consider a central extension $\mathfrak h$ of a Lie algebra $\mathfrak{g}$ by the abelian $\mathfrak a$:
$$0 \longrightarrow \mathfrak a \longrightarrow \mathfrak h \stackrel{\pi}\longrightarrow \mathfrak g \longrightarrow 0$$
Then there is a linear splitting map $\beta: \mathfrak{g} \to \mathfrak{h}$ so that $\pi \circ \beta = id_{\mathfrak g}$, simply by virtue that Lie algebras are also vector spaces and every short exact sequence on vector spaces splits.
Define for $X,Y \in \mathfrak g$ a map $\Theta(X,Y) = [\beta(X),\beta(Y)]_{\mathfrak h} - \beta([X,Y]_{\mathfrak g})$. This map satisfies the $2$ conditions that make it a cocycle:
- $\Theta(X,Y)=-\Theta(Y,X)$
- $\Theta(X,[Y,Z]_{\mathfrak g})+\Theta(Y,[Z,X]_{\mathfrak g})+\Theta(Z,[X,Y]_{\mathfrak g})$
The first property is clear, the second looks like its supposed to be a super simple calculation, but for some reason I am failing to do it.
Why does $2$ hold for $\Theta$?
Well thinking about it a little more, it turns out the question is indeed super trivial.
Basically use the thing that makes a short exact sequence a central extension, which has not been used so far.
If $i: \mathfrak{a} \to \mathfrak{h}$ is the map in the central extension, then $i(\mathfrak a)=\ker(\pi)$ and $i(\mathfrak a)$ is central in $\mathfrak h$. Now $$\pi(\Theta(X,Y)) = \pi\left([\beta(X),\beta(Y)]_{\mathfrak h} - \beta([X,Y]_{\mathfrak g})\right) =[X,Y]_{\mathfrak g}-[X,Y]_{\mathfrak g}=0$$
by virtue of $\pi$ being a Lie Algebra homomorphism and $\pi \circ \beta = id_{\mathfrak g}$.
This means $\Theta(X,Y) \in i(\mathfrak g)$, which is central, so $[f,\Theta(X,Y)]=0$ for all $f \in \mathfrak h$. So immediately:
\begin{align} \Theta(X,[Y,Z]_{\mathfrak g})&=[_\mathstrut\beta(X),\beta([_\mathstrut Y,Z]_{\mathfrak g})]_{\mathfrak h}-\beta([_\mathstrut X,[_\mathstrut Y,Z]_{\mathfrak g}]_{\mathfrak g})\\ &=[_\mathstrut \beta(X),-\Theta(Y,Z)]_{\mathfrak h}+[_\mathstrut\beta(X),[_\mathstrut \beta(Y),\beta(Z)]_{\mathfrak h}]_{\mathfrak h}-\beta([_\mathstrut X,[_\mathstrut Y,Z]_{\mathfrak g}]_{\mathfrak g})\\ &=[_\mathstrut \beta(X),[_\mathstrut\beta(Y),\beta(Z)]_{\mathfrak h}]_{\mathfrak h}-\beta([_\mathstrut X,[_\mathstrut Y,Z]_{\mathfrak g}]_{\mathfrak g}) \end{align}
The statement then follows from the Jacobi Identity on $[_\mathstrut,]_\mathfrak{h}$ and $[_\mathstrut,]_\mathfrak{g}$ together with $\beta$ being linear to get all the $[_\mathstrut,]_\mathfrak{g}$ together underneath $\beta()$.