2-cocycle for a group action

Definition
Let $$G$$ be a group acting (on the left) on an abelian group $$A$$ via a homomorphism of groups $$\varphi:G \to \operatorname{Aut}(A)$$ where $$\operatorname{Aut}(A)$$ is the automorphism group of $$A$$.

Explicit definition
A 2-cocycle for the action is a function $$f:G \times G \to A$$ satisfying:

$$\!\varphi(g_1)(f(g_2,g_3)) + f(g_1,g_2g_3) = f(g_1g_2,g_3) + f(g_1,g_2)$$

If we suppress $$\varphi$$ and use $$\cdot$$ for the action, we can rewrite this as:

$$\!g_1 \cdot f(g_2,g_3) + f(g_1,g_2g_3) = f(g_1g_2,g_3) + f(g_1,g_2)$$ or equivalently:

$$\! g_1 \cdot f(g_2,g_3) - f(g_1g_2,g_3) + f(g_1,g_2g_3) - f(g_1,g_2) = 0$$

Note that a function $$f:G \times G \to A$$ (without any conditions) is sometimes termed a 2-cochain for the group action.

Definition as part of the general definition of cocycle
A 2-cocycle for a group action is a special case of a defining ingredient::cocycle for a group action, namely $$n = 2$$. This, in turn, is the notion of cocycle corresponding to the Hom complex from the defining ingredient::bar resolution of $$G$$ to $$A$$ as $$\mathbb{Z}G$$-modules.

Group structure
The set of 2-cocycles for the action of $$G$$ on $$A$$ forms a group under pointwise addition. This group is denoted $$Z^2_\varphi(G,A)$$ where $$\varphi$$ is the action. If the action is understood from the context, it can simply be denoted as $$Z^2(G,A)$$.

As a group of homomorphisms
For any group $$G$$, we can construct a $$\mathbb{Z}G$$-module $$K$$ such that for any abelian group $$A$$, the group of 2-cocycles $$f:G \times G \to A$$ can be identified with the group of $$\mathbb{Z}G$$-module maps from $$K$$ to $$A$$.

Extreme examples

 * If $$A$$ is the trivial group, the group of 2-cocycles is the trivial group, with the only 2-cocycle being the map that sends every pair of elements of $$G$$ to the zero element of $$A$$.
 * If $$G$$ is the trivial group, the group of 2-cocycles is isomorphic to the group $$A$$, with each 2-cocycle being identified with its image value in $$A$$.

Extension involving an abelian normal subgroup
Let $$E$$ be a group with an abelian normal subgroup isomorphic to (and explicitly identified with) $$A$$, and a quotient isomorphic to (and explicitly identified with) $$G$$, such that the induced action of the quotient $$G$$ on $$A$$ (in the sense of action by conjugation, see quotient group acts on abelian normal subgroup) is as described. Let $$S$$ be a system of coset representatives for $$G$$ in $$E$$ with $$s: G \to S$$ being the representation map. Then, define $$f: G \times G \to A$$ such that

$$\! s(gh) = f(g,h)s(g)s(h)$$

In other words, $$f$$ measures the extent to which the collection of coset representatives fails to be closed under multiplication.

Such an $$f$$ is a 2-cocycle.

Note that for a particular choice of $$E$$, all the 2-cocycles obtained by different choices of $$S$$ will form a single coset of the coboundary group, that is, any two such cocycles will differ by a coboundary. Thus, in particular, we can intrinsically associate, to every extension $$E$$ with abelian normal subgroup $$A$$ and quotient $$G$$, an element of the second cohomology group.