Suppose that $\omega$ is an exact differential form satisfying $L_X \omega=0$ for $X$ in some Lie algebra of vector fields. When can I find $\eta$ such that $\omega=d \eta$ and $L_X \eta=0?$ What are the obstructions for this problem?
Motivating example:
Manifold $\mathbb R^2$, $\omega=dx \wedge dy $. I can find $\eta = \frac{1}{2} ( x dy - y dx )$ which is rotationally symmetric, $\eta = x dy$ which is invariant with respect to translations in $y$ and $\eta= -y dx$ which is invariant with respect to translations in $x$ direction. Finding $\eta$ with all these symmetries is impossible.
Formulation in the language of cohomology:
Since Lie derivatives commutes with exterior derivative, algebra of differential forms invariant under an action of given group forms a chain subcomplex of de Rham complex. The question essentially asks what can be said about its cohomology.
As noted in comments by Ted Shifrin, in the case of compact groups invariant potential can be found by averaging action of a group on one potential (with respect to Haar measure). This is nice and useful point, but now case of noncompact groups remains.