---
abstract: 'For a prime number $p$ and a free profinite group $S$, let $S^{(n,p)}$ be the $n$th term of its lower $p$-central filtration, and $S^{[n,p]}$ the corresponding quotient. Using tools from the combinatorics of words, we construct a canonical basis of the cohomology group $H^2(S^{[n,p]},{\mathbb{Z}}/p)$, which we call the Lyndon basis, and use it to obtain structural results on this group. We show a duality between the Lyndon basis and canonical generators of $S^{(n,p)}/S^{(n+1,p)}$. We prove that the cohomology group satisfies shuffle relations, which for small values of $n$ fully describe it.'
address: |
    Department of Mathematics\
    Ben-Gurion University of the Negev\
    P.O. Box 653, Be’er-Sheva 84105\
    Israel
author:
- Ido Efrat
title: The Cohomology of canonical quotients of free groups and Lyndon words
---

\[section\] \[thm\][Corollary]{} \[thm\][Lemma]{} \[thm\][Proposition]{} \[thm\][Definition]{} \[thm\][Example]{} \[thm\][Examples]{} \[thm\][Remark]{} \[thm\][Question]{} \[thm\][Remarks]{}

\[thm\][Questions]{}

[^1]

Introduction
============

Let $p$ be a fixed prime number. For a profinite group $G$ one defines the [**lower $p$-central filtration**]{} $G^{(n,p)}$, $n=1,2{,\ldots,}$ inductively by $$G^{(1,p)}=G, \quad G^{(n+1,p)}=(G^{(n,p)})^p[G,G^{(n,p)}].$$ Thus $G^{(n+1,p)}$ is the closed subgroup of $G$ generated by the powers $h^p$ and commutators $[g,h]=g{^{-1}}h{^{-1}}gh$, where $g\in G$ and $h\in G^{(n,p)}$. We also set $G^{[n,p]}=G/G^{(n,p)}$.

Now let $S$ be a free profinite group on the basis $X$, and let $n\geq2$. Then $S^{[n,p]}$ is a free object in the category of pro-$p$ groups $G$ with $G^{(n,p)}$ trivial. As with any pro-$p$ group, the cohomology groups $H^l(S^{[n,p]})=H^l(S^{[n,p]},{\mathbb{Z}}/p)$, $l=1,2$, capture the main information on generators and relations, respectively, in a minimal presentation of $S^{[n,p]}$. The group $H^1(S^{[n,p]})$ is just the dual $(S^{[2,p]})^\vee{\cong}\bigoplus_{x\in X}{\mathbb{Z}}/p$, and it remains to understand $H^2(S^{[n,p]})$.

When $n=2$ the quotient $S^{[2,p]}$ is an elementary abelian $p$-group, and the structure of $H^2(S^{[2,p]})$ is well-known. Namely, for $p>2$ one has an isomorphism $$H^1(S^{[2,p]})\oplus{\textstyle\bigwedge^2} H^1(S^{[2,p]})\xrightarrow{\sim}H^2(S^{[2,p]}),$$ which is the Bockstein map on the first component, and the cup product on the second component. Furthermore, taking a basis $\chi_x$, $x\in X$, of $H^1(S^{[2,p]})$ dual to $X$, there is a fundamental duality between $p$th powers and commutators in the presentation of $S$ and Bockstein elements and cup products, respectively, of the $\chi_x$ (see [@NeukirchSchmidtWingberg]\*[Ch. III, §9]{} for details). These facts have numerous applications in Galois theory, ranging from class field theory ([@Koch02], [@NeukirchSchmidtWingberg]), the works by Serre and Labute on the pro-$p$ Galois theory of $p$-adic fields ([@SerreDemuskin], [@Labute67]), the structure theory of general absolute Galois groups ([@MinacSpira96], [@EfratMinac11]), the birational anabelian phenomena ([@Bogomolov91], [@Topaz15]), Galois groups with restricted ramification ([@Vogel05], [@Schmidt10]), and mild groups ([@Labute06], [@Forre11], [@LabuteMinac11]), to mention only a few of the pioneering works in these areas.

In this paper we generalize the above results from the case $n=2$ to arbitrary $n\geq2$. Namely, we give a complete description of $H^2(S^{[n,p]})$ in terms of a canonical linear basis of this cohomology group. This basis is constructed using tools from the [*combinatorics of words*]{} – in particular, the [**Lyndon words**]{} in the alphabet $X$, i.e., words which are lexicographically smaller than all their proper suffixes (for a fixed total order on $X$). We call it the [**Lyndon basis**]{}, and use it to prove several structural results on $H^2(S^{[n,p]})$, and in particular to compute its size (see below).

The Lyndon basis constructed here can be most naturally described in terms of central extensions, as follows: For $1\leq s\leq n$ let ${\mathbb{U}}$ denote the group of all unipotent upper-triangular $(s+1)\times(s+1)$-matrices over the ring ${\mathbb{Z}}/p^{n-s+1}$. There is a central extension $$0\to{\mathbb{Z}}/p\to{\mathbb{U}}\to {\mathbb{U}}^{[n,p]}\to1$$ (Proposition \[properties of dbU\]). It corresponds to a cohomology element ${\gamma}_{n,s}\in H^2({\mathbb{U}}^{[n,p]})$. For a profinite group $G$ and a continuous homomorphism $\rho\colon G\to{\mathbb{U}}$ we write $\bar\rho\colon G^{[n,p]}\to{\mathbb{U}}^{[n,p]}$ for the induced homomorphism, and $\bar\rho^*{\gamma}_{n,s}$ for the pullback to $H^2(G^{[n,p]})$. Now for any word $w=(x_1\cdots x_s)$ in the alphabet $X$ we define a homomorphism $\rho^w\colon S\to {\mathbb{U}}$ by setting the entry $(\rho^w({\sigma}))_{ij}$ to be the coefficient of the subword $(x_i\cdots x_{j-1})$ in the power series ${\Lambda}({\sigma})$, where ${\Lambda}\colon S\to({\mathbb{Z}}/p^{n-s+1})\langle\langle X\rangle\rangle^\times$ is the [**Magnus homomorphism**]{}, defined on the generators $x\in X$ by ${\Lambda}(x)=1+x$ (see §3 and §6 for more details). The Lyndon basis is now given by:

The pullbacks ${\alpha}_{w,n}=(\bar\rho^w)^*{\gamma}_{n,s}$, where $w$ ranges over all Lyndon words of length $1\leq s\leq n$ in the alphabet $X$, form a linear basis of $H^2(S^{[n,p]})$ over ${\mathbb{Z}}/p$.

We further show a duality between the Lyndon basis and certain canonical elements ${\sigma}_w\in S^{(n,p)}$, with $w$ a Lyndon word of length $\leq n$, generalizing the above mentioned duality in the case $n=2$ (see Corollary \[upper-triangular\]).

The cohomology elements $\bar\rho^*{\gamma}_{n,s}$ include the Bockstein elements (for $s=1$), the cup products (for $n=s=2$), and more generally, the elements of $n$-fold Massey products in $H^2(G^{[n,p]})$ (for $n=s\geq2$); see Examples \[examples of alp\]. The full spectrum $\bar\rho^*{\gamma}_{n,s}$, $1\leq s\leq n$, appears to give new significant “external" objects in profinite cohomology, which to our knowledge have not been investigated so far in general.

Lyndon words are known to have tight connections with the [**shuffle algebra**]{}, and indeed, the ${\alpha}_{w,n}$ for arbitrary words $w$ of length $\leq n$ in $X$ satisfy natural [**shuffle relations**]{} (Theorem \[shuffle relations\]). In §\[section on n=2\]-§\[section on n=3\] we show that for $n=2,3$ these shuffle relations fully describe $H^2(S^{[n,p]})$, provided that $p>2$, $p>3$, respectively (for $n=2$ this was essentially known). Interestingly, related considerations arise also in the context of [*multiple zeta values*]{}, see e.g. [@MinhPetitot00], although we are not aware of a direct connection.

The Lyndon words on $X$ form a special instance of [*Hall sets*]{}, which are well-known to have fundamental role in the structure theory of free groups and free Lie algebras (see [@Reutenauer93], [@SerreLie]). In addition, the Lyndon words have a **triangularity property** (see Proposition \[Lam(tau w)\](b)). This property allows us to construct certain upper-triangular unipotent matrices that express a (semi-)duality between the ${\sigma}_w$ and the cohomology elements ${\alpha}_{w,n}$.

We now outline the proof that the ${\alpha}_{w,n}$ form a linear basis of $H^2(S^{[n,p]})$. For simplicity we assume for the moment that $X$ is finite. To each Lyndon word $w$ of length $1\leq s\leq n$ one associates in a canonical way an element $\tau_w$ of the $s$-th term of the lower central series of $S$ (see §4). The cosets of the powers ${\sigma}_w=\tau_w^{p^{n-s}}$ generate $S^{(n,p)}/S^{(n+1,p)}$ (Theorem \[generators\]). Using the special structure of the lower $p$-central filtration of ${\mathbb{U}}$ we define for any two Lyndon words $w,w'$ of length $\leq n$ a value $\langle w,w'\rangle_n\in{\mathbb{Z}}/p$ (see §\[section on pairings\]). The triangularity property of Lyndon words implies that the matrix $\bigl(\langle w,w'\rangle_n\bigr)$ is unipotent upper-triangular, whence invertible. Turning now to cohomology, we define a natural perfect pairing $$(\cdot,\cdot)_n\colon S^{(n,p)}/S^{(n+1,p)}\times H^2(S^{[n,p]})\to{\mathbb{Z}}/p.$$ Cohomological computations show that, for Lyndon words $w,w'$ of length $\leq n$, one has $\langle w,w'\rangle_n=({\sigma}_w,{\alpha}_{w',n})_n$. Hence the matrix $\bigl(({\sigma}_w,{\alpha}_{w',n})_n\bigr)$ is also invertible. We then conclude that the ${\alpha}_{w',n}$ form a basis of $H^2(S^{[n,p]})$ (Theorem \[basis\]). This immediately determines the dimension of the latter cohomology group, in terms of Witt’s [**necklace function**]{}, which counts the number of Lyndon words over $X$ of a given length (Corollary \[dim of H2\]).

In the special case $n=2$, the theory developed here generalizes the above description of $H^2(S^{[2,p]})$ in terms of the Bockstein map and cup products (see §\[section on n=2\] for details). Namely, the matrix $(\langle w,w'\rangle_2)$ is the identity matrix, which gives the above duality between $p$th powers/commutators and Bockstein elements/cup products. Likewise, the shuffle relations just recover the basic fact that the cup product factors via the exterior product.

In §\[section on n=3\] we describe our theory explicitly also for the (new) case $n=3$.

While here we focus primarily on free profinite groups, it may be interesting to study the canonical elements $\bar\rho_*{\gamma}_{n,s}$ for more general profinite groups $G$, in particular, when $G=G_F$ is the absolute Galois group of a field $F$. For instance, when $n=2$, they were used in [@EfratMinac11] (following [@MinacSpira96] and [@AdemKaragueuzianMinac99]) and [@CheboluEfratMinac12] to describe the quotient $G_F^{[3,p]}$. Triple Massey products for $G_F$ (which correspond to the case $n=s=3$) were also extensively studied in recent years – see [@EfratMatzri15], [@MinacTan15b], [@MinacTan16], [@MinacTan17], and [@Wickelgren12] and the references therein.

I thank Claudio Quadrelli and the anonymous referee for their careful reading of this paper and for their very valuable comments and suggestions on improving the exposition.

Words {#section on words}
=====

Let $X$ be a nonempty set, considered as an alphabet. Let $X^*$ be the free monoid on $X$. We view its elements as associative words on $X$. The length of a word $w$ is denoted by $|w|$. We write $\emptyset$ for the empty word, and $ww'$ for the concatenation of words $w$ and $w'$.

Recall that a **magma** is a set ${\mathcal{M}}$ with a binary operation $(\cdot,\cdot)\colon {\mathcal{M}}\times {\mathcal{M}}\to {\mathcal{M}}$. A morphism of magmas is a map which commutes with the associated binary operations. There is a **free magma** ${\mathcal{M}}_X$ on $X$, unique up to an isomorphism; that is, $X\subseteq {\mathcal{M}}_X$, and for every magma $(\cdot,\cdot)\colon N\times N\to N$ and a map $f_0\colon X\to N$ there is a magma morphism $f\colon {\mathcal{M}}_X\to N$ extending $f_0$. See [@SerreLie]\*[Ch. IV, §1]{} for an explicit construction of ${\mathcal{M}}_X$. The elements of ${\mathcal{M}}_X$ may be viewed as non-associative words on $X$.

The monoid $X^*$ is a magma with respect to concatenation, so the universal property of ${\mathcal{M}}_X$ gives rise to a unique magma morphism $f\colon {\mathcal{M}}_X\to X^*$, called the **foliage** (or **brackets dropping**) map, such that $f(x)=x$ for $x\in X$.

Let ${\mathcal{H}}$ be a subset of ${\mathcal{M}}_X$ and $\leq$ a total order on ${\mathcal{H}}$. We say that $({\mathcal{H}},\leq)$ is a **Hall set in ${\mathcal{M}}_X$**, if the following conditions hold [@Reutenauer93]\*[§4.1]{}:

1.  $X\subseteq {\mathcal{H}}$;

2.  If $h=(h',h'')\in{\mathcal{H}}\setminus X$, then $h<h''$;

3.  For $h=(h',h'')\in {\mathcal{M}}_X \setminus X$, one has $h\in{\mathcal{H}}$ if and only if

    -   $h',h''\in{\mathcal{H}}$ and $h'<h''$; and

    -   either $h'\in X$, or $h'=(v,u)$ where $u\geq h''$.

Given a Hall set $({\mathcal{H}},\leq)$ in ${\mathcal{M}}_X$ we call $H=f({\mathcal{H}})$ a **Hall set in $X^*$**.

Every $w\in H$ can be written as $w=f(h)$ for a *unique* $h\in{\mathcal{H}}$ [@Reutenauer93]\*[Cor. 4.5]{}. If $w\in H\setminus X$, then we can uniquely write $h=(h',h'')$ with $h',h''\in {\mathcal{H}}$, and call $w=w'w''$, where $w'=f(h')$ and $w''=f(h'')$, the **standard factorization** of $w$ [@Reutenauer93]\*[p. 89]{}.

Next we fix a total order $\leq$ on $X$, and define a total order $\leq_{\rm alp}$ (the [**alphabetical**]{} order) on $X^*$ as follows: Let $w_1,w_2\in X^*$. Then $w_1\leq_{\rm alp} w_2$ if and only if $w_2=w_1v$ for some $v\in X^*$, or $w_1=vx_1u_1$, $w_2=vx_2u_2$ for some words $v,u_1,u_2$ and some letters $x_1,x_2\in X$ with $x_1<x_2$. Note that the restriction of $\leq_{\rm alp}$ to $X^n$ is the lexicographic order.

In addition, we order ${\mathbb{Z}}_{\geq0}\times X^*$ lexicographically with respect to the usual order on ${\mathbb{Z}}_{\geq0}$ and the order $\leq_{\rm alp}$ on $X^*$. We then define a second total order $\preceq$ on $X^*$ by setting $$\label{preceq}
w_1\preceq w_2\quad \Longleftrightarrow\quad (|w_1|,w_1)\leq(|w_2|,w_2)$$ with respect to the latter order on ${\mathbb{Z}}_{\geq0}\times X^*$.

A nonempty word $w\in X^*$ is called a **Lyndon word** if it is smaller in $\leq_{\rm alp}$ than all its non-trivial proper right factors. Equivalently, no non-trivial rotation leaves $w$ invariant, and $w$ is lexicographically strictly smaller than all its rotations $\neq w$ ([@ChenFoxLyndon58]\*[Th. 1.4]{}, [@Reutenauer93]\*[Cor. 7.7]{}). We denote the set of all Lyndon words on $X$ by $\operatorname{Lyn}(X)$, and the set of all such words of length $n$ (resp., $\leq n$) by $\operatorname{Lyn}_n(X)$ (resp., $\operatorname{Lyn}_{\leq n}(X)$). The set $\operatorname{Lyn}(X)$, totally ordered with respect to $\leq_{\rm alp}$, is a Hall set [@Reutenauer93]\*[Th. 5.1]{}.

\[examples of Lyndon words\] The Lyndon words of length $\leq4$ on $X$ are $$\begin{split}
&(x) \hbox{ for } x\in X,\\
& (xy), (xxy), (xyy), (xxxy), (xxyy), (xyyy) \hbox{ for } x,y\in X, \ x<y, \\
&  (xyz), (xzy),(xxyz), (xxzy), (xyxz), (xyyz), (xyzy), (xyzz), \\
& \qquad\qquad \qquad(xzyy), (xzyz), (xzzy) \hbox{  for } x,y,z\in X, \  x<y<z,\\
& (xyzt), (xytz), (xzyt),(xzty),(xtyz), (xtzy) \hbox{  for } x,y,z,t\in X, \  x<y<z<t
\end{split}$$

The [**necklace map**]{} (also called the [**Witt map**]{}) is defined for integers $n,m\geq1$ by $$\varphi_n(m)=\frac1n\sum_{d|n}\mu(d)m^{n/d}.$$ Here $\mu$ is the Möbius function, defined by $\mu(d)=(-1)^k$, if $d$ is a product of $k$ distinct prime numbers, and $\mu(d)=0$ otherwise; Alternatively, $1/\zeta(s)=\sum_{n=1}^\infty\mu(n)/n^s$, where $\zeta(s)$ is the Riemann zeta function and $s$ is a complex number with real part $>1$. When $m=q$ is a prime power, $\varphi_n(q)$ also counts the number of irreducible monic polynomials of degree $n$ over a field of $q$ elements [@Reutenauer93]\*[§7.6.2]{}. We also define $\varphi_n(\infty)=\infty$. One has [@Reutenauer93]\*[Cor. 4.14]{} $$\label{size of Lyn}
|\operatorname{Lyn}_n(X)|=\varphi_n(|X|).$$

Power series {#section on power series}
============

We fix a commutative unital ring $R$. Recall that a bilinear map $M\times N\to R$ of $R$-modules is [**non-degenerate**]{} if its left and right kernels are trivial, i.e., the induced maps $M\to\operatorname{Hom}(N,R)$ and $N\to\operatorname{Hom}(M,R)$ are injective. The bilinear map is [**perfect**]{} if these two maps are isomorphisms.

Let $R\langle X\rangle$ be the free associative $R$-algebra on $X$. We may view its elements as polynomials over $R$ in the non-commuting variables $x\in X$. The additive group of $R\langle X\rangle$ is the free $R$-module on the basis $X^*$. We grade $R\langle X\rangle$ by total degree. Let $R\langle \langle X\rangle\rangle$ be the ring of all formal power series in the non-commuting variables $x\in X$ and coefficients in $R$. For $f\in R\langle\langle X\rangle\rangle$ we write $f_w$ for the coefficient of $f$ at $w\in X^*$. Thus $f=\sum_{w\in X^*}f_ww$. There are natural embedings $X^*\subseteq R\langle X\rangle\subseteq R\langle\langle X\rangle\rangle$, where we identify $w\in X^*$ with the series $f$ such that $f_w=1$ and $f_{w'}=0$ for $w'\neq w$. There is a well-defined non-degenerate bilinear map of $R$-modules $$\label{bilinear}
R\langle\langle X\rangle\rangle\times R\langle X\rangle\to R, \quad (f,g)\mapsto \sum_{w\in X^*}f_wg_w;$$ See [@Reutenauer93]\*[p. 17]{}. For every integer $n\geq0$, it restricts to a non-degenerate bilinear map on the homogenous components of degree $n$.

We may identify the additive group of $R\langle\langle X\rangle\rangle$ with $R^{X^*}$ via the map $f\mapsto(f_w)_w$. When $R$ is equipped with a profinite ring topology (e.g. when $R$ is finite), the product topology on $R^{X^*}$ induces a profinite group topology on $R\langle\langle X\rangle\rangle$. Moreover, the multiplication map of $R\langle\langle X\rangle\rangle$ is continuous, making it a profinite ring. The group $R\langle\langle X\rangle\rangle^\times$ of all invertible elements in $R\langle\langle X\rangle\rangle$ is then a profinite group.

Next we recall from [@FriedJarden08]\*[§17.4]{} the following terminology and facts on free profinite groups. Let $G$ be a profinite group and $X$ a set. A map $\psi\colon X\to G$ [**converges to $1$**]{}, if for every open normal subgroup $N$ of $G$, the set $X\setminus\psi{^{-1}}(N)$ is finite. We say that a profinite group $S$ is a [**free profinite group on basis $X$**]{} with respect to a map $\iota\colon X\to S$ if

1.  $\iota\colon X\to S$ converges to $1$ and $\iota(X)$ generates $S$ as a profinite group;

2.  For every profinite group $G$ and a map $\psi\colon X\to G$ converging to $1$, there is a unique continuous homomorphism $\hat\psi\colon S\to G$ such that $\psi=\hat\psi\circ\iota$ on $X$.

A free profinite group on $X$ exists, and is unique up to a continuous isomorphism. We denote it by $S_X$. The map $\iota$ is then injective, and we identify $X$ with its image in $S_X$.

We define the (profinite) [**Magnus homomorphism**]{} ${\Lambda}_{X,R}\colon S_X\to R\langle\langle  X\rangle\rangle^\times$ as follows (compare [@Efrat14]\*[§5]{}):

Assume first that $X$ is finite. For $x\in X$ one has $1=(1+x)\sum_{i=0}^\infty(-1)^ix^i$ in $R\langle\langle X\rangle\rangle$, so $1+x\in R\langle\langle X\rangle\rangle^\times$. Hence, by (ii), the map $\psi\colon X\to R\langle\langle X\rangle\rangle^\times$, $x\mapsto 1+x$, uniquely extends to a continuous homomorphism ${\Lambda}_{X,R}\colon S_X\to R\langle\langle X\rangle\rangle^\times$.

Now suppose that $X$ is arbitrary. Let $Y$ range over all finite subsets of $X$. The map $\psi\colon X\to S_Y$, which is the identity on $Y$ and $1$ on $X\setminus Y$, converges to $1$. Hence it extends to a unique continuous group homomorphism $S_X\to S_Y$. Also, there is a unique continuous $R$-algebra homomorphism $R\langle\langle X\rangle\rangle\to R\langle\langle Y\rangle\rangle$, which is the identity on $Y$ and $0$ on $X\setminus Y$. Then $$S_X=\operatorname{\varprojlim}S_Y, \quad R\langle\langle X\rangle\rangle=\operatorname{\varprojlim}R\langle\langle Y\rangle\rangle, \quad
 R\langle\langle X\rangle\rangle^\times=\operatorname{\varprojlim}R\langle\langle Y\rangle\rangle^\times.$$ We define ${\Lambda}_{X,R}=\operatorname{\varprojlim}{\Lambda}_{Y,R}$. It is functorial in both $X$ and $R$ in the natural way. Note that ${\Lambda}_{X,R}(x)=1+x$ for $x\in X$.

In the sequel, $X$ will be fixed, so we abbreviate $S=S_X$ and ${\Lambda}_R={\Lambda}_{X,R}$.

For ${\sigma}\in S$ and a word $w\in X^*$ we denote the coefficient of $w$ in ${\Lambda}_R({\sigma})$ by ${\epsilon}_{w,R}({\sigma})$. Thus $${\Lambda}_R({\sigma})=\sum_{w\in X^*}{\epsilon}_{w,R}({\sigma})w.$$ By the construction of ${\Lambda}_R$, we have ${\epsilon}_{\emptyset,R}({\sigma})=1$. Since ${\Lambda}_R$ is a homomorphism, for every ${\sigma},\tau\in S$ and $w\in X^*$ one has $$\label{eps of product}
{\epsilon}_{w,R}({\sigma}\tau)=\sum_{w=u_1u_2}{\epsilon}_{u_1,R}({\sigma}){\epsilon}_{u_2,R}(\tau).$$

We will also need the classical [*discrete*]{} version of the Magnus homomorphism. To define it, assume that $X$ is finite, and let $F_X$ be the free group on basis $X$. There is a natural homomorphism $F_X\to S_X$. The [**discrete Magnus homomorphism**]{} ${\Lambda}_{\mathbb{Z}}^{\rm disc}\colon F_X\to{\mathbb{Z}}\langle\langle X\rangle\rangle^\times$ is defined again by $x\mapsto 1+x$. There is a commutative square $$\label{discrete Magnus hom}
\xymatrix{
F_X\ar[r] \ar[d]_{{\Lambda}_{\mathbb{Z}}^{\rm disc}} & S_X\ar[d]^{{\Lambda}_{{\mathbb{Z}}_p}}\\
{\mathbb{Z}}\langle\langle X\rangle\rangle^\times\ar@{^{(}->}[r] &{\mathbb{Z}}_p\langle\langle X\rangle\rangle^\times.
}$$

Lie algebra constructions {#section on Lie algebra constructions}
=========================

Recall that the [**lower central filtration**]{} $G^{(n,0)}$, $n=1,2{,\ldots,}$ of a profinite group $G$ is defined inductively by $$G^{(1,0)}=G,\quad G^{(n+1,0)}=[G^{(n,0)},G].$$ Thus $G^{(n+1,0)}$ is generated as a profinite group by all elements of the form $[{\sigma},\tau]$ with ${\sigma}\in G^{(n,0)}$ and $\tau\in G$. One has $[G^{(n,0)},G^{(m,0)}]\leq G^{(n+m,0)}$ for every $n,m\geq1$ (compare [@SerreLie]\*[Part I, Ch. II, §3]{}).

\[Koch\] Let $S=S_X$ and let ${\sigma}\in S$. Then:

1.  ${\sigma}\in S^{(n,0)}$ if and only if ${\epsilon}_{w,{\mathbb{Z}}_p}({\sigma})=0$ for every $w\in X^*$ with $1\leq|w|<n$;

2.  ${\sigma}\in S^{(n,p)}$ if and only if ${\epsilon}_{w,{\mathbb{Z}}_p}({\sigma})\in p^{n-|w|}{\mathbb{Z}}_p$ for every $w\in X^*$ with $1\leq|w|<n$.

In the discrete case (a) and (b) are due to Grün and Magnus (see [@SerreLie]\*[Part I, Ch. IV, th. 6.3]{}) and Koch [@Koch60], respectively. The results in the profinite case follow by continuity.

For other approaches see [@Morishita12]\*[Prop. 8.15]{}, [@ChapmanEfrat16]\*[Example 4.5]{}, and [@MinacTan15a]\*[Lemma 2.2(d)]{}.

We will need the following profinite analog of [@Fenn83]\*[Lemma 4.4.1(iii)]{}.

\[commutators\] Let ${\sigma}\in S^{(n,0)}$ and $\tau\in S^{(m,0)}$, and let $w\in X^*$ have length $n+m$. Write $w=u_1u_2=u'_2u'_1$ with $|u_1|=|u'_1|=n$ and $|u_2|=|u'_2|=m$. Then $${\epsilon}_{w,{\mathbb{Z}}_p}([{\sigma},\tau])={\epsilon}_{u_1,{\mathbb{Z}}_p}({\sigma}){\epsilon}_{u_2,{\mathbb{Z}}_p}(\tau)-{\epsilon}_{u'_2,{\mathbb{Z}}_p}(\tau){\epsilon}_{u'_1,{\mathbb{Z}}_p}({\sigma}).$$

By Proposition \[Koch\](a), we may write ${\Lambda}_{{\mathbb{Z}}_p}({\sigma})=1+P+O(n+1)$ and ${\Lambda}_{{\mathbb{Z}}_p}(\tau)=1+Q+O(m+1)$, where $P,Q\in{\mathbb{Z}}_p\langle\langle X\rangle\rangle$ are homogenous of degrees $n,m$, respectively, and where $O(r)$ denotes a power series containing only terms of degree $\geq r$. Then $${\Lambda}_{{\mathbb{Z}}_p}([{\sigma},\tau])=1+PQ-QP+O(n+m+1).$$ (compare e.g., [@Morishita12]\*[Proof of Prop. 8.5]{}). By (\[eps of product\]), it follows that $$\begin{split}
{\epsilon}_{w,{\mathbb{Z}}_p}([{\sigma},\tau])&=(PQ-QP)_w=P_{u_1}Q_{u_2}-Q_{u'_2}P_{u'_1}\\
&={\epsilon}_{u_1,{\mathbb{Z}}_p}({\sigma}){\epsilon}_{u_2,{\mathbb{Z}}_p}(\tau)-{\epsilon}_{u'_2,{\mathbb{Z}}_p}(\tau){\epsilon}_{u'_1,{\mathbb{Z}}_p}({\sigma}).
\end{split}$$

The commutator map induces on the graded ring $\bigoplus_{n=1}^\infty S^{(n,0)}/S^{(n+1,0)}$ a graded Lie algebra structure [@SerreLie]\*[Part I, Ch. II, Prop. 2.3]{}. Let ${\mathfrak{d}}$ be the ideal in the ${\mathbb{Z}}_p$-algebra ${\mathbb{Z}}_p\langle\langle X\rangle\rangle$ generated by $X$. Then $\bigoplus_{n=1}^\infty{\mathfrak{d}}^n/{\mathfrak{d}}^{n+1}$ is a Lie algebra with the Lie brackets defined on homogenous components by $[\bar f,\bar g]=\overline{fg-gf}$ for $f\in{\mathfrak{d}}^n$, $g\in {\mathfrak{d}}^m$ [@SerreLie]\*[p. 25]{}. By Proposition \[Koch\](a), ${\Lambda}_{{\mathbb{Z}}_p}$ induces a graded ${\mathbb{Z}}_p$-algebra homomorphism $${\mathrm{gr}}\ {\Lambda}_{{\mathbb{Z}}_p}\colon \bigoplus_{n=1}^\infty S^{(n,0)}/S^{(n+1,0)}\to\bigoplus_{n=1}^\infty{\mathfrak{d}}^n/{\mathfrak{d}}^{n+1},
\quad
{\sigma}S^{(n+1,0)}\mapsto \sum_{|w|=n}{\epsilon}_{w,{\mathbb{Z}}_p}({\sigma})+{\mathfrak{d}}^{n+1}.$$ Then Lemma \[commutators\] means that ${\mathrm{gr}}\ {\Lambda}_{{\mathbb{Z}}_p}$ is a Lie algebra homomorphism.

For $w\in \operatorname{Lyn}(X)$ we inductively define an element $\tau_w$ of $S$ and a non-commutative polynomial $P_w\in {\mathbb{Z}}\langle X\rangle\subseteq{\mathbb{Z}}_p\langle X\rangle$ as follows:

-   If $w=(x)$ has length $1$, then $\tau_w=x$ and $P_w=x$;

-   If $|w|>1$, then we take the standard factorization $w=w'w''$ of $w$ with respect to the Hall set $\operatorname{Lyn}(X)$ (see §\[section on words\]), and set $$\tau_w=[\tau_{w'},\tau_{w''}], \qquad P_w=P_{w'}P_{w''}-P_{w''}P_{w'}.$$

For $w\in\operatorname{Lyn}_n(X)$ one has $\tau_w\in S^{(n,0)}$. Moreover:

\[the taus generate\] Let $n\geq1$. The cosets of $\tau_w$, with $w\in \operatorname{Lyn}_n(X)$, generate $S^{(n,0)}/S^{(n+1,0)}$.

See [@Reutenauer93]\*[Cor. 6.16]{} for the discrete version. The profinite version follows by taking closure.

Let $\leq_{\rm alp}$ and $\preceq$ be the total orders on $X^*$ defined in §\[section on words\]. The importance of the Lyndon words in our context, beside forming a Hall set, is part (b) of the following Proposition, called the [**triangularity**]{} property.

\[Lam(tau w)\] Let $w\in\operatorname{Lyn}(X)$. Then

1.  ${\Lambda}_{{\mathbb{Z}}_p}(\tau_w)-1-P_w$ is a combination of words of length $>|w|$.

2.  $P_w-w$ is a combination of words of length $|w|$ which are strictly larger than $w$ with respect to $\leq_{\rm alp}$.

3.  ${\Lambda}_{{\mathbb{Z}}_p}(\tau_w)-1-w$ is a combination of words which are strictly larger than $w$ in $\preceq$.

\(a) Since ${\mathrm{gr}}\,{\Lambda}_{{\mathbb{Z}}_p}$ is a Lie algebra homomorphism, for $w\in\operatorname{Lyn}_n(X)$ we have by induction $$({\mathrm{gr}}\,{\Lambda}_{{\mathbb{Z}}_p})(\tau_w S^{(n+1,0)})=P_w+{\mathfrak{d}}^{n+1},$$ and the assertion follows. See also [@Reutenauer93]\*[Lemma 6.10(ii)]{}.

\(b) See [@Reutenauer93]\*[Th. 5.1]{} and its proof.

\(c) This follows from (a) and (b).

Generators for $S^{(n,p)}/S^{(n+1,p)}$
======================================

Let $\pi$ be an indeterminate over the ring ${\mathbb{Z}}/p$ and let ${\mathbb{Z}}/p[\pi]$ be the polynomial ring. Let $A_\bullet=\bigoplus_{n=1}^\infty A_n$ be a graded Lie ${\mathbb{Z}}/p$-algebra with Lie bracket $[\cdot,\cdot]$. Suppose that there is a map ${\mathbb{Z}}/p[\pi]\times A_\bullet\to A_\bullet, \quad ({\alpha},\xi)\mapsto {\alpha}\xi$, which is ${\mathbb{Z}}/p$-linear in ${\mathbb{Z}}/p[\pi]$, such that $\pi\xi\in A_{s+1}$ for $\xi\in A_s$, and such that for every $\xi_1,\xi_2\in A_s$, $$\label{properties of pi}
\pi(\xi_1+\xi_2)=\begin{cases}
\pi\xi_1+\pi\xi_2, & \hbox{ if } p>2 \hbox{ or } s>1,\\
\pi\xi_1+\pi\xi_2+[\xi_1,\xi_2], & \hbox{ if }p=2,\ s=1.
\end{cases}$$ By induction, this extends to:

\[ZpPi algebras\] Let $r,k,s\geq1$ and let $\xi_1{,\ldots,}\xi_k\in A_s$. Then $$\pi^r(\sum_{i=1}^k\xi_i)=
\begin{cases}
\sum_{i=1}^k\pi^r\xi_i,& \hbox{ if }p>2 \hbox{ or } s>1,\\
\sum_{i=1}^k\pi^r\xi_i+\sum_{i<j}\pi^{r-1}[\xi_i,\xi_j],&\hbox{ if }p=2,\ s=1.
\end{cases}$$

We write $\langle T\rangle$ for the submodule of $A_\bullet$ generated by a subset $T$.

\[cor on gens\] Let $n\geq2$ and for each $1\leq s\leq n$ let $T_s$ be a subset of $A_s$. When $p=2$ assume also that $[\tau_1,\tau_2]\in T_2\cup\{0\}$ for every $\tau_1,\tau_2\in T_1$. If the sets $\pi^{n-s}\langle T_s\rangle$, $s=1,2{,\ldots,}n$, generate $A_n$, then the sets $\pi^{n-s}T_s$, $s=1,2{,\ldots,}n$, also generate $A_n$.

When $p>2$ or $s>1$ Lemma \[ZpPi algebras\] shows that $\pi^{n-s}\langle T_s\rangle=\langle\pi^{n-s}T_s\rangle$. When $p=2$ and $s=1$, it shows that $$\pi^{n-1}\langle T_1\rangle\subseteq \langle\pi^{n-1}T_1\rangle+\langle\pi^{n-2}T_2\rangle\subseteq A_n.$$ Therefore the subgroup of $A_n$ generated by the sets $\pi^{n-s}T_s$, $s=1,2{,\ldots,}n$, contains the sets $\pi^{n-s}\langle T_s\rangle$, $s=1,2{,\ldots,}n$, and hence equals $A_n$.

Motivated by e.g., [@Lazard54], [@SerreDemuskin], [@Labute67], we now specialize to a graded Lie algebra defined using the lower $p$-central filtration. We refer to [@NeukirchSchmidtWingberg]\*[Ch. III, §8]{} for the following facts. For the free profinite group $S$ on the basis $X$ and for $n\geq1$ we set ${\mathrm{gr}}_n(S)=S^{(n,p)}/S^{(n+1,p)}$. It is an elementary abelian $p$-group, which we write additively. The commutator map induces a map $[\cdot,\cdot]\colon {\mathrm{gr}}_n(S)\times{\mathrm{gr}}_m(S)\to{\mathrm{gr}}_{n+m}(S)$, which endows a graded Lie algebra structure on ${\mathrm{gr}}_\bullet(S)=\bigoplus_{n=1}^\infty{\mathrm{gr}}_n(S)$. The map $\tau\mapsto \tau^p$ maps $S^{(r,p)}$ into $S^{(r+1,p)}$, and induces a map $\pi_r\colon{\mathrm{gr}}_r(S)\to{\mathrm{gr}}_{r+1}(S)$. The map $(\pi^r,\xi)\mapsto \pi_r(\xi)$ for $\xi\in{\mathrm{gr}}_r(S)$ extends to a map ${\mathbb{Z}}/p[\pi]\times{\mathrm{gr}}_\bullet(S)\to{\mathrm{gr}}_\bullet(S)$ which is ${\mathbb{Z}}/p$-linear in the first component and which satisfies (\[properties of pi\]).

\[generators\] Let $n\geq1$. The cosets of $\tau_w^{p^{n-s}}$, with $1\leq s\leq n$ and $w\in \operatorname{Lyn}_s(X)$, generate $S^{(n,p)}/S^{(n+1,p)}$.

The case $n=1$ is immediate, so we assume that $n\geq2$. For every $1\leq s\leq n$ let $T_s$ be the set of cosets of $\tau_w$, $w\in\operatorname{Lyn}_s(X)$, in ${\mathrm{gr}}_s(S)$. By Proposition \[the taus generate\], $\langle T_s\rangle$ is the image of $S^{(s,0)}$ in ${\mathrm{gr}}_s(S)$. Hence $\pi^{n-s}\langle T_s\rangle$ consists of the cosets in ${\mathrm{gr}}_n(S)$ of the $p^{n-s}$-powers of $S^{(s,0)}$. One has $$S^{(n,p)}=\prod_{s=1}^n(S^{(s,0)})^{p^{n-s}}$$ [@NeukirchSchmidtWingberg]\*[Prop. 3.8.6]{}. Thus the sets $\pi^{n-s}\langle T_s\rangle$, $s=1,2{,\ldots,}n$, generate ${\mathrm{gr}}_n(S)$.

Further, $T_1$ consists of the cosets of $x$, with $x\in X$, and $T_2$ consists of the cosets of commutators $[x,y]$ with $x<y$ in $X$. Moreover, when $p=2$ the cosets of $[x,y]$ and $[y,x]=[x,y]{^{-1}}$ in ${\mathrm{gr}}_2(S)$ coincide. Lemma \[cor on gens\] therefore implies that even the sets $\pi^{n-s}T_s$, $s=1,2{,\ldots,}n$, generate ${\mathrm{gr}}_n(S)$, as required.

The pairing $\langle w,w'\rangle_n$ {#section on pairings}
===================================

For a commutative unitary ring $R$ and a positive integer $m$, let ${\mathbb{U}}_m(R)$ be the group of all $m\times m$ upper-triangular unipotent matrices over $R$. We write $I_m$ for the identity matrix in ${\mathbb{U}}_m(R)$, and $E_{ij}$ for the matrix with $1$ at entry $(i,j)$ and $0$ elsewhere. As above, $X$ will be a totally ordered set.

For the following fact we refer, e.g., to [@Efrat14]\*[Lemma 7.5]{}. We recall from §\[section on power series\] that ${\epsilon}_{u,R}({\sigma})$ is the coefficient of the word $u\in X^*$ in the formal power series ${\Lambda}_R({\sigma})\in R\langle\langle X\rangle\rangle^\times$.

\[rho\] Given a profinite ring $R$ and a word $w=(x_1\cdots x_s)$ in $X^*$ there is a well defined homomorphism of profinite groups $$\rho^w_R\colon S\to {\mathbb{U}}_{s+1}(R), \quad {\sigma}\mapsto ({\epsilon}_{(x_i\cdots x_{j-1}),R}({\sigma}))_{1\leq i<j\leq s+1}.$$

\[dual basis\] In particular, for each $x\in X$ the map $\chi_{x,R}={\epsilon}_{(x),R}\colon S\to R$ is a group homomorphism, where $R$ is considered as an additive group. The homomorphisms $\chi_{x,R}$, $x\in X$, are dual to the basis $X$, in the sense that $\chi_{x,R}(x)=1$, and $\chi_{x,R}(y)=0$ for $x\neq y$ in $X$.

\[properties of dbU\] Let $1\leq s\leq n$. For $R={\mathbb{Z}}/p^{n-s+1}$ one has:

1.  ${\mathbb{U}}_{s+1}(R)^{(n,p)}=I_{s+1}+{\mathbb{Z}}p^{n-s}E_{1,s+1}$.

2.  ${\mathbb{U}}_{s+1}(R)^{(n,p)}$ is central in ${\mathbb{U}}_{s+1}(R)$.

\(a) We follow the argument of [@MinacTan15a]\*[Lemma 2.4]{}. Take $X=\{x_1{,\ldots,}x_s\}$ be a set of $s$ elements, let $S=S_X$, and let $w=(x_1\cdots x_s)$. The matrices $\rho^w_R(x_i)=I_{s+1}+E_{i,i+1}$, $i=1,2{,\ldots,}s$, generate ${\mathbb{U}}_{s+1}(R)$ [@Weir55]\*[p. 55]{}, so $\rho^w_R$ is surjective. Therefore it maps $S^{(n,p)}$ onto ${\mathbb{U}}_{s+1}(R)^{(n,p)}$.

By Proposition \[Koch\](b), for ${\sigma}\in S^{(n,p)}$ and $u\in X^*$ of length $1\leq |u|\leq s$ one has ${\epsilon}_{u,{\mathbb{Z}}_p}({\sigma})\in p^{n-|u|}{\mathbb{Z}}_p$.

If $|u|<s$, then ${\epsilon}_{u,{\mathbb{Z}}_p}({\sigma})\in p^{n-|u|}{\mathbb{Z}}_p\subseteq p^{n-s+1}{\mathbb{Z}}_p$. Hence ${\epsilon}_{u,R}({\sigma})=0$ in this case.

If $|u|=s$, then ${\epsilon}_{u,{\mathbb{Z}}_p}({\sigma})\in p^{n-s}{\mathbb{Z}}_p$, so ${\epsilon}_{u,R}({\sigma})\in p^{n-s}R$.

Moreover, $\tau_w^{p^{n-s}}\in(S^{(s,0)})^{p^{n-s}}\leq S^{(n,p)}$. By Proposition \[Lam(tau w)\](c), ${\Lambda}_{{\mathbb{Z}}_p}(\tau_w)=1+w+f$, where $f$ is a combination of words strictly larger than $w$ in $\preceq$. Hence ${\Lambda}_{{\mathbb{Z}}_p}(\tau_w^{p^{n-s}})=1+p^{n-s}w+g$, where $g$ is also a combination of words strictly larger than $w$ in $\preceq$, which implies that ${\epsilon}_{w,R}(\tau_w^{p^{n-s}})=p^{n-s}\cdot 1_R$.

Consequently, ${\mathbb{U}}_{s+1}(R)^{(n,p)}=\rho^w_R(S^{(n,p)})=I_{s+1}+{\mathbb{Z}}p^{n-s}E_{1,s+1}$.

\(b) It is straightforward to see that $I_{s+1}+{\mathbb{Z}}E_{1,s+1}$ is central in ${\mathbb{U}}_{s+1}(R)$, so the assertion follows from (a).

See [@Borge04]\*[§2]{} for a related analysis of the lower $p$-central filtration of ${\mathbb{U}}_{s+1}({\mathbb{Z}}/p^{n-s+1})$.

Consider the obvious isomorphism $$\iota_{n,s}\colon p^{n-s}{\mathbb{Z}}/p^{n-s+1}{\mathbb{Z}}\xrightarrow{\sim}{\mathbb{Z}}/p, \qquad ap^{n-s}\hbox{ (mod }p^{n-s+1}\hbox{)}\mapsto a\hbox{ (mod }p\hbox{)}.$$ In view of Proposition \[properties of dbU\](a), we may define a group isomorphism $$\iota_{n,s}^{\mathbb{U}}\colon {\mathbb{U}}_{s+1}({\mathbb{Z}}/p^{n-s+1})^{(n,p)}\xrightarrow{\sim}{\mathbb{Z}}/p, \quad
(a_{ij})\mapsto \iota_{n,s}(a_{1,s+1}).$$

Next let $w,w'\in X^*$ be words of lengths $1\leq s,s'\leq n$, respectively, where $w$ is Lyndon. We have $\tau_w^{p^{n-s}}\in (S^{(s,0)})^{p^{n-s}}\leq S^{(n,p)}$. By Proposition \[Koch\](b), ${\epsilon}_{w',{\mathbb{Z}}_p}(\tau_w^{p^{n-s}})\in p^{n-s'}{\mathbb{Z}}_p$, and therefore ${\epsilon}_{w',{\mathbb{Z}}/p^{n-s'+1}}(\tau_w^{p^{n-s}})\in p^{n-s'}{\mathbb{Z}}/p^{n-s'+1}{\mathbb{Z}}$. We set $$\label{description of pairing}
\langle w,w'\rangle_n=\iota_{n,s'}({\epsilon}_{w',{\mathbb{Z}}/p^{n-s'+1}}(\tau_w^{p^{n-s}}))\in{\mathbb{Z}}/p.$$ Alternatively, $$\label{description of pairing 2}
\langle w,w'\rangle_n=\iota_{n,s'}^{\mathbb{U}}(\rho^{w'}_{{\mathbb{Z}}/p^{n-s'+1}}(\tau_w^{p^{n-s}})).$$

Let $\preceq$ be as in (\[preceq\]).

\[vanishing of iota\] Let $w,w'$ be words in $X^*$ of lengths $1\leq s,s'\leq n$, respectively, with $w$ Lyndon.

1.  If $w'\prec w$, then $\langle w,w'\rangle_n=0$;

2.  $\langle w,w\rangle_n=1$;

3.  If $w'$ contains letters which do not appear in $w$, then $\langle w,w'\rangle_n=0$;

4.  If $s<s'<2s$, then $\langle w,w'\rangle_n=0$.

(a), (b) Proposition \[Lam(tau w)\](c) implies that ${\Lambda}_{{\mathbb{Z}}_p}(\tau_w^{p^{n-s}})-1-p^{n-s}w$ is a combination of words strictly larger than $w$ with respect to $\preceq$, and the same therefore holds over the coefficient ring ${\mathbb{Z}}/p^{n-s'+1}$. Hence, if $w'\prec w$, then ${\epsilon}_{w',{\mathbb{Z}}/p^{n-s'+1}}(\tau_w^{p^{n-s}})=0$, so $\langle w,w'\rangle_n=0$. If $w=w'$, then ${\epsilon}_{w,{\mathbb{Z}}/p^{n-s+1}}(\tau_w^{p^{n-s}})=p^{n-s}\cdot1_{{\mathbb{Z}}/p^{n-s+1}}$, whence $\langle w,w\rangle_n=1$.

\(c) Here we clearly have ${\epsilon}_{w',{\mathbb{Z}}/p^{n-s'+1}}(\tau_w^{p^{n-s}})=0$.

\(d) Since $\tau_w\in S^{(s,0)}$, one may write ${\Lambda}_{{\mathbb{Z}}_p}(\tau_w)=1+P+O(s'+1)$, where $P$ is a combination of words $w''$ of length $s\leq |w''|\leq s'$, and $O(s'+1)$ denotes a combination of words of length $\geq s'+1$ (Proposition \[Koch\](a)). Since $s'<2s$, this implies that ${\Lambda}_{{\mathbb{Z}}_p}(\tau_w^{p^{n-s}})=1+p^{n-s}P+O(s'+1)$. In particular, ${\epsilon}_{w',{\mathbb{Z}}_p}(\tau_w^{p^{n-s}})\in p^{n-s}{\mathbb{Z}}_p$, and therefore $${\epsilon}_{w',{\mathbb{Z}}/p^{n-s'+1}}(\tau_w^{p^{n-s}})\in p^{n-s}({\mathbb{Z}}/p^{n-s'+1})=\{0\},$$ since $s<s'$. Hence $\langle w,w'\rangle_n=0$.

Transgressions {#section on transgression}
==============

Given a profinite group $G$ and a discrete $G$-module $A$, we write as usual $C^i(G,A)$, $Z^i(G,A)$, and $H^i(G,A)$ for the corresponding group of continuous $i$-cochains, group of continuous $i$-cocycles, and the $i$th profinite cohomology group, respectively. For $x\in Z^i(G,A)$ let $[x]$ be its cohomology class in $H^i(G,A)$.

For a normal closed subgroup $N$ of $G$, let $\operatorname{trg}\colon H^1(N,A)^G\to H^2(G/N,A^N)$ be the transgression homomorphism. It is the map $d_2^{0,1}$ of the Lyndon–Hochschild–Serre spectral sequence associated with $G$ and $N$ [@NeukirchSchmidtWingberg]\*[Th. 2.4.3]{}. We recall the explicit description of $\operatorname{trg}$, assuming for simplicity that the $G$-action on $A$ is trivial [@NeukirchSchmidtWingberg]\*[Prop. 1.6.6]{}: If $x\in Z^1(N,A)$, then there exists $y\in C^1(G,A)$ such that $y|_N=x$ and $(\partial y)({\sigma}_1,{\sigma}_2)$ depends only on the cosets of ${\sigma}_1,{\sigma}_2$ modulo $N$, so that $\partial y$ may be viewed as an element of $Z^2(G/N,A)$. For any such $y$ one has $\operatorname{trg}([x])=[\partial y]$.

We fix for the rest of this section a finite group ${\mathbb{U}}$ and a normal subgroup $N$ of ${\mathbb{U}}$ satisfying:

1.  $N{\cong}{\mathbb{Z}}/p$; and

2.  $N$ lies in the center of ${\mathbb{U}}$.

We set $\bar{\mathbb{U}}={\mathbb{U}}/N$, and let it act trivially on ${\mathbb{U}}$. We denote the image of $u\in{\mathbb{U}}$ in $\bar{\mathbb{U}}$ by $\bar u$. We may choose a section ${\lambda}$ of the projection ${\mathbb{U}}\to\bar{\mathbb{U}}$ such that ${\lambda}(\bar 1)=1$. We define a map ${\delta}\in C^2(\bar{\mathbb{U}},N)$ by $${\delta}(\bar u,\bar u')={\lambda}(\bar u)\cdot{\lambda}(\bar u')\cdot{\lambda}(\bar u\bar u'){^{-1}}.$$ It is normalized, i.e., ${\delta}(\bar u,1)={\delta}(1,\bar u)=1$ for every $\bar u\in\bar{\mathbb{U}}$.

We also define $y\in C^1({\mathbb{U}},N)$ by $y(u)=u{\lambda}(\bar u){^{-1}}$. Note that $y|_N=\operatorname{id}_N$.

\[lemma with centers\] For every $u,u'\in{\mathbb{U}}$ one has $${\delta}(\bar u,\bar u')\cdot y(u)\cdot y(u')=y(uu').$$

Since $y(u)$ and $y(u')$ are in $N$, they are central in ${\mathbb{U}}$, so $$\begin{split}
{\delta}(\bar u,\bar u')\cdot y(u)\cdot y(u')
&={\lambda}(\bar u)\cdot{\lambda}(\bar u')\cdot{\lambda}(\bar u\bar u'){^{-1}}\cdot y(u)\cdot y(u')\\
&=y(u)\cdot{\lambda}(\bar u)\cdot y(u')\cdot {\lambda}(\bar u')\cdot{\lambda}(\bar u\bar u'){^{-1}}\\
&=uu'{\lambda}(\bar u\bar u'){^{-1}}=y(uu').
\end{split}$$

For the correspondence between elements of $H^2$ and central extensions see e.g., [@NeukirchSchmidtWingberg]\*[Th. 1.2.4]{}.

\[properties of del\] Using the notation above, the following holds.

1.  ${\delta}\in Z^2(\bar{\mathbb{U}},N)$;

2.  One has $\operatorname{trg}(\operatorname{id}_N)=-[{\delta}]$ for the transgression map $\operatorname{trg}\colon H^1(N,N)^{\mathbb{U}}\to H^2(\bar{\mathbb{U}},N)$.

3.  The cohomology class $[{\delta}]\in H^2(\bar{\mathbb{U}},N)$ corresponds to the equivalence class of the central extension $$\label{basic extension}
    1\to N\to {\mathbb{U}}\to\bar{\mathbb{U}}\to1.$$

(a), (b): For $u,u'\in{\mathbb{U}}$ Lemma \[lemma with centers\] gives $$(\partial y)(u,u')=y(u)\cdot y(u')\cdot y(uu'){^{-1}}={\delta}(\bar u,\bar u'){^{-1}}.$$ This shows that ${\delta}$ is a 2-cocycle, and that $(\partial y)(u,u')$ depends only on the cosets $\bar u,\bar u'$. Further, $\operatorname{id}_N\in Z^1(N,N)$. By the explicit description of the transgression above, $\operatorname{trg}(\operatorname{id}_N)=-[{\delta}]$.

\(c) Consider the set $B=N\times\bar{\mathbb{U}}$ with the binary operation $$(u,\bar v)*(u',\bar v')=({\delta}(\bar v,\bar v')uu',\bar v\bar v').$$ The proof of [@NeukirchSchmidtWingberg]\*[Th. 1.2.4]{} shows that this makes $B$ a group, and $[{\delta}]$ corresponds to the equivalence class of the central extension $$\label{NBU}
1\to N\to B\to\bar{\mathbb{U}}\to1.$$ Moreover, the map $h\colon {\mathbb{U}}\to B$, $u\mapsto(y(u),\bar u)$ is clearly bijective. We claim that it is a homomorphism, whence an isomorphism. Indeed, for $u,u'\in{\mathbb{U}}$ Lemma \[lemma with centers\] gives: $$\begin{split}
h(u)*h(u')&=(y(u),\bar u) *(y(u'),\bar u')=({\delta}(\bar u,\bar u')y(u)y(u'),\bar u\bar u')\\
&=(y(uu'),\bar u\bar u')=h(uu').
\end{split}$$ We obtain that the central extension (\[NBU\]) is equivalent to the central extension (\[basic extension\]).

Next let $\bar G$ be a profinite group, and let $\bar\rho\colon \bar G\to\bar{\mathbb{U}}$ be a continuous homomorphism. Let $\iota\colon N\xrightarrow{\sim}{\mathbb{Z}}/p$ be a fixed isomorphism (see (i)). Set $$\label{alp}
{\alpha}=(\bar\rho^*\circ\iota_*)([{\delta}])=-(\bar\rho^*\circ\iota_*\circ\operatorname{trg})(\operatorname{id}_N)\in H^2(\bar G,{\mathbb{Z}}/p),$$ where the second equality is by Proposition \[properties of del\](b). Then ${\alpha}$ corresponds to the equivalence class of the central extension $$\label{central extension revised}
0\to{\mathbb{Z}}/p\xrightarrow{\iota{^{-1}}\times1} {\mathbb{U}}\times_{\bar{\mathbb{U}}}\bar G\to \bar G\to1,$$ where ${\mathbb{U}}\times_{\bar{\mathbb{U}}}\bar G$ is the fiber product with respect to the natural projection ${\mathbb{U}}\to\bar{\mathbb{U}}$ and to $\bar\rho$; See [@Hoechsmann68]\*[Proof of 1.1]{}.

Suppose further that there is a profinite group $G$, a closed normal subgroup $M$ of $G$, and a continuous homomorphism $\rho\colon G\to{\mathbb{U}}$ such that $\bar G=G/M$, $\rho(M)\leq N$, and $\bar\rho\colon \bar G\to\bar{\mathbb{U}}$ is induced from $\rho$. The functoriality of transgression yields a commutative diagram $$\xymatrix{
H^1(N,N)^{{\mathbb{U}}}\ar[r]^{\iota_*}_{\sim}\ar[d]^{\operatorname{trg}}& H^1(N,{\mathbb{Z}}/p)^{{\mathbb{U}}}\ar[r]^{\rho^*}\ar[d]^{\operatorname{trg}} &
H^1(M,{\mathbb{Z}}/p)^G\ar[d]^{\operatorname{trg}} \\
H^2(\bar{\mathbb{U}},N)\ar[r]^{\iota_*}_{\sim} & H^2(\bar{\mathbb{U}},{\mathbb{Z}}/p)\ar[r]^{\bar\rho^*}& H^2(\bar G,{\mathbb{Z}}/p).}$$ The image of $\operatorname{id}_N\in H^1(N,N)$ in $H^1(M,{\mathbb{Z}}/p)^G$ is $$\label{theta and rho}
\theta=\iota\circ(\rho|_M)\in H^1(M,{\mathbb{Z}}/p).$$ By (\[alp\]) and the commutativity of the diagram, $$\label{alp and del}
{\alpha}=-\operatorname{trg}(\theta)\in H^2(\bar G,{\mathbb{Z}}/p)$$

\[alp as a connecting hom\] Suppose that $\bar{\mathbb{U}}$ is abelian and that $\bar G$ acts trivially on $\bar{\mathbb{U}}$. A $2$-cocycle representing ${\alpha}$ is $$(\bar{\sigma},\bar{\sigma}')\mapsto\iota({\lambda}(\bar\rho(\bar{\sigma}))\cdot{\lambda}(\bar\rho(\bar{\sigma}'))\cdot{\lambda}(\bar\rho(\bar{\sigma}\bar{\sigma}')){^{-1}}).$$ But ${\lambda}(\bar\rho(\bar{\sigma}))\cdot{\lambda}(\bar\rho(\bar{\sigma}'))\cdot{\lambda}(\bar\rho(\bar{\sigma}\bar{\sigma}')){^{-1}}$ is a $2$-cocycle representing the image of $\bar\rho$ under the connecting homomorphism $H^1(\bar G,\bar{\mathbb{U}})\to H^2(\bar G,N)$ arising from (\[basic extension\]). Thus ${\alpha}$ is the image of $\bar\rho$ under the composition $$H^1(\bar G,\bar{\mathbb{U}})\to H^2(\bar G,N)\xrightarrow{\iota_*}H^2(\bar G,{\mathbb{Z}}/p).$$

\[examples of alp\] We give several examples of the above construction with the group ${\mathbb{U}}={\mathbb{U}}_{s+1}({\mathbb{Z}}/p^{n-s+1})$ (where $1\leq s\leq n$), a continuous homomorphism $\rho\colon G\to{\mathbb{U}}$, where $G$ is a profinite group, and the induced homomorphism $\bar\rho\colon  G^{[n,p]}\to {\mathbb{U}}^{[n,p]}$. Note that assumptions (i) and (ii) then hold for $N={\mathbb{U}}^{(n,p)}$, by Proposition \[properties of dbU\]. We will be especially interested in the case where $G=S=S_X$ is a free profinite group, $M=S^{(n,p)}$, $\rho=\rho_{{\mathbb{Z}}/p^{n-s+1}}^{w}$ for a word $w\in X^*$ of length $1\leq s\leq n$, and $\bar\rho=\bar\rho^w_{{\mathbb{Z}}/p^{n-s+1}}\colon S^{[n,p]}\to{\mathbb{U}}^{[n,p]}$ is the induced homomorphism. In this setup we write ${\alpha}_{w,n}$ for ${\alpha}$.

\(1) [*Bocksteins.*]{} For a positive integer $m$ and a profinite group $\bar G$, the connecting homomorphism arising from the short exact sequence of trivial $\bar G$-modules $$0\to {\mathbb{Z}}/p\to{\mathbb{Z}}/pm\to{\mathbb{Z}}/m\to0$$ is the [**Bockstein homomorphism**]{} $${\mathrm{Bock}}_{m,\bar G}\colon H^1(\bar G,{\mathbb{Z}}/m)\to H^2(\bar G,{\mathbb{Z}}/p).$$ Let ${\mathbb{U}}={\mathbb{U}}_2({\mathbb{Z}}/p^n)$ (i.e., $s=1$). There is a commutative diagram of central extensions $$\xymatrix{
1\ar[r]&{\mathbb{U}}^{(n,p)}\ar[r]\ar[d]_{\wr}&{\mathbb{U}}\ar[r]\ar[d]_{\wr}&{\mathbb{U}}^{[n,p]}\ar[r]\ar[d]_{\wr}&1\\
0\ar[r]&p^{n-1}{\mathbb{Z}}/p^n{\mathbb{Z}}\ar[r]&{\mathbb{Z}}/p^n\ar[r]&{\mathbb{Z}}/p^{n-1}\ar[r]&0.
}$$ For a profinite group $\bar G$ and a homomorphism $\bar\rho\colon \bar G\to{\mathbb{Z}}/p^{n-1}$, Remark \[alp as a connecting hom\] therefore implies that ${\alpha}={\mathrm{Bock}}_{p^{n-1},\bar G}(\bar\rho)$.

In particular, for $x\in X$ take $$\bar\rho=\bar\rho^{(x)}_{{\mathbb{Z}}/p^n}\colon \bar G=S^{[n,p]}\to {\mathbb{U}}_2({\mathbb{Z}}/p^n)^{[n,p]}.$$ Identifying ${\mathbb{U}}_2({\mathbb{Z}}/p^n)^{[n,p]}={\mathbb{Z}}/p^{n-1}$, we obtain $${\alpha}_{(x),n}={\mathrm{Bock}}_{p^{n-1},S^{[n,p]}}({\epsilon}_{(x),{\mathbb{Z}}/p^{n-1}}).$$

\(2) Let $n=s\geq2$, so ${\mathbb{U}}={\mathbb{U}}_{n+1}({\mathbb{Z}}/p)$. Let $\bar G$ be a profinite group, let $\bar\rho\colon \bar G\to{\mathbb{U}}^{[n,p]}$ be a continuous homomorphism, and let $\rho_{i,i+1}\colon \bar G\to{\mathbb{Z}}/p$ denote its projection on the $(i,i+1)$-entry, $i=1,2{,\ldots,}n$. By a result of Dwyer [@Dwyer75]\*[Th. 2.6]{}, the extension (\[central extension revised\]) then corresponds to a defining system for the $n$-fold Massey product $$\langle\rho_{12},\rho_{23}{,\ldots,}\rho_{n,n+1}\rangle\subseteq H^2(\bar G,{\mathbb{Z}}/p)$$ (see [@Efrat14]\*[Prop. 8.3]{} for the profinite analog of this fact). Thus, for a fixed $\bar G$ and for homomorphisms $\bar\rho_1{,\ldots,}\bar\rho_n\colon \bar G\to{\mathbb{Z}}/p$, with $\bar\rho$ varying over all homomorphisms such that $\bar\rho_{i,i+1}=\bar\rho_i$, $i=1,2{,\ldots,}n$, the cohomology element ${\alpha}$ ranges over the elements of the Massey product $\langle\bar\rho_1{,\ldots,}\bar\rho_n\rangle$.

In particular, for $\bar G=S^{[n,p]}$ and for a word $w=(x_1\cdots x_n)\in X^*$ of length $n$, the cohomology elements ${\alpha}_{w,n}$ range over the Massey product $\langle{\epsilon}_{(x_1),{\mathbb{Z}}/p}{,\ldots,}{\epsilon}_{(x_n),{\mathbb{Z}}/p}\rangle\subseteq H^2(S^{[n,p]},{\mathbb{Z}}/p)$, where the ${\epsilon}_{(x_i),{\mathbb{Z}}/p}$ are viewed as elements of $H^1(S^{[n,p]},{\mathbb{Z}}/p)$.

\(3) In the special case $n=s=2$, the Massey product contains only the cup product. Hence for every profinite group $\bar G$ and a homomorphism $\bar\rho\colon\bar G\to{\mathbb{U}}_3({\mathbb{Z}}/p)$ the cohomology element ${\alpha}\in H^2(\bar G,{\mathbb{Z}}/p)$ is the cup product $\bar\rho_{12}\cup\bar\rho_{23}$. In particular, for $w=(xy)$ we have $${\alpha}_{(xy),{\mathbb{Z}}/p}={\epsilon}_{(x),{\mathbb{Z}}/p}\cup{\epsilon}_{(y),{\mathbb{Z}}/p}\in H^2(S^{[2,p]},{\mathbb{Z}}/p).$$

Cohomological duality
=====================

Let $S=S_X$ be again a free profinite group on the totally ordered set $X$, and let it act trivially on ${\mathbb{Z}}/p$. Let $n\geq2$, so $S^{(n,p)}\leq S^p[S,S]$. Then the inflation map $H^1(S^{[n,p]},{\mathbb{Z}}/p)\to H^1(S,{\mathbb{Z}}/p)$ is an isomorphism. Further, $H^2(S,{\mathbb{Z}}/p)=0$. By the five-term sequence of cohomology groups [@NeukirchSchmidtWingberg]\*[Prop. 1.6.7]{}, $\operatorname{trg}\colon H^1(S^{(n,p)},{\mathbb{Z}}/p)^S\to H^2(S^{[n,p]},{\mathbb{Z}}/p)$ is an isomorphism.

There is a natural non-degenerate bilinear map $$S^{(n,p)}/S^{(n+1,p)}\times H^1(S^{(n,p)},{\mathbb{Z}}/p)^S\to{\mathbb{Z}}/p, \quad (\bar{\sigma},\varphi)\mapsto\varphi({\sigma})$$ (see [@EfratMinac11]\*[Cor. 2.2]{}). It induces a bilinear map $$(\cdot,\cdot)_n\colon S^{(n,p)}\times H^2(S^{[n,p]},{\mathbb{Z}}/p)\to{\mathbb{Z}}/p, \quad ({\sigma},{\alpha})_n=-(\operatorname{trg}{^{-1}}({\alpha}))({\sigma}),$$ with left kernel $S^{(n+1,p)}$ and trivial right kernel.

Now let $w\in X^*$ be a word of length $1\leq s\leq n$. As in Examples \[examples of alp\], we apply the computations in Section \[section on transgression\] to the group ${\mathbb{U}}={\mathbb{U}}_{s+1}({\mathbb{Z}}/p^{n-s+1})$, the open normal subgroup $N={\mathbb{U}}^{(n,p)}$, the homomorphism $\rho=\rho^w_{{\mathbb{Z}}/p^{n-s+1}}\colon S\to{\mathbb{U}}$, the induced homomorphism $\bar\rho=\bar\rho^w_{{\mathbb{Z}}/p^{n-s+1}}\colon S^{[n,p]}\to{\mathbb{U}}^{[n,p]}$, and the closed normal subgroup $M=S^{(n,p)}$ of $S$. We write $\theta_{w,n},{\alpha}_{w,n}$ for $\theta,{\alpha}$, respectively.

For ${\sigma}\in S^{(n,p)}$ and a word $w\in X^*$ of length $1\leq s\leq n$ one has $$({\sigma},{\alpha}_{w,n})_n=\iota_{n,s}({\epsilon}_{w,{\mathbb{Z}}/p^{n-s+1}}({\sigma})).$$

By (\[alp and del\]) and (\[theta and rho\]), $$({\sigma},{\alpha}_{w,n})_n=\theta_{w,n}({\sigma})=\iota_{n,s}^{\mathbb{U}}(\rho_{{\mathbb{Z}}/p^{n-s+1}}^w({\sigma}))=\iota_{n,s}({\epsilon}_{w,{\mathbb{Z}}/p^{n-s+1}}({\sigma})).
\qedhere$$

This and (\[description of pairing\]) give:

\[equality of the two pairings\] Let $w,w'$ be words in $X^*$ of lengths $1\leq s,s'\leq n$, respectively, with $w$ Lyndon. Then $$(\tau_w^{p^{n-s}},{\alpha}_{w',n})_n=\langle w,w'\rangle_n.$$

Proposition \[vanishing of iota\](a)(b) now gives:

\[upper-triangular\] Let $\operatorname{Lyn}_{\leq n}(X)$ be totally ordered by $\preceq$. The matrix $$\Bigl((\tau_w^{p^{n-|w|}},{\alpha}_{w',n})_n\Bigr),$$ where $w,w'\in \operatorname{Lyn}_{\leq n}(X)$, is upper-triangular unipotent.

In general the above matrix need not be the identity matrix – see e.g., Proposition \[uuu\] below. Next we observe the following general fact:

\[linear algebra lemma\] Let $R$ be a commutative ring and let $(\cdot,\cdot)\colon A\times B\to R$ be a non-degenerate bilinear map of $R$-modules. Let $(L,\leq)$ be a finite totally ordered set, and for every $w\in L$ let $a_w\in A$, $b_w\in B$. Suppose that the matrix $\bigl((a_w,b_{w'})\bigr)_{w,w'\in L}$ is invertible, and that $a_w$, $w\in L$, generate $A$. Then $a_w$, $w\in L$, is an $R$-linear basis of $A$, and $b_w$, $w\in L$, is an $R$-linear basis of $B$.

Let $b\in B$, and consider $r_{w'}\in R$, with $w'\in L$. The assumptions imply that $b=\sum_{w'}r_{w'}b_{w'}$ if and only if $(a_w,b-\sum_{w'}r_{w'}b_{w'})=0$ for every $w$. Equivalently, the $r_{w'}$ solve the linear system $\sum_{w'}(a_w,b_{w'})X_{w'}=(a_w,b)$, for $w\in L$. By the invertibility, the latter system has a unique solution. This shows that $b_w$, $w\in L$, is an $R$-linear basis of $B$.

By reversing the roles of $a_w,b_w$, we conclude that the $a_w$, $w\in L$, form an $R$-linear basis of $A$.

\[basis\]

1.  The cohomology elements ${\alpha}_{w,n}$, where $w\in\operatorname{Lyn}_{\leq n}(X)$, form a ${\mathbb{Z}}/p$-linear basis of $H^2(S^{[n,p]},{\mathbb{Z}}/p)$.

2.  When $X$ is finite, the cosets of the powers $\tau_w^{p^{n-s}}$, $w\in\operatorname{Lyn}_{\leq n}(X)$, form a basis of the ${\mathbb{Z}}/p$-module $S^{(n,p)}/S^{(n+1,p)}$.

When $X$ is finite, the set $\operatorname{Lyn}_{\leq n}(X)$ is also finite. By Theorem \[generators\], the cosets $a_w$ of $\tau_w^{p^{n-|w|}}$, where $w\in \operatorname{Lyn}_{\leq n}(X)$, generate the ${\mathbb{Z}}/p$-module $S^{(n,p)}/S^{(n+1,p)}$. We apply Lemma \[linear algebra lemma\] with the ${\mathbb{Z}}/p$-modules $A=S^{(n,p)}/S^{(n+1,p)}$ and $B=H^2(S^{[n,p]},{\mathbb{Z}}/p)$, the non-degenerate bilinear map $A\times B\to{\mathbb{Z}}/p$ induced by $(\cdot,\cdot)_n$, the generators $a_w$ of $A$, and the elements $b_w={\alpha}_{w,n}$ of $B$.

Corollary \[upper-triangular\] implies that the matrix $(a_w,b_{w'})$ is invertible. Therefore Lemma \[linear algebra lemma\] gives both assertions in the finite case.

The general case of (a) follows from the finite case by a standard limit argument.

We call ${\alpha}_{w,n}$, $w\in\operatorname{Lyn}_{\leq n}(X)$, the [**Lyndon basis**]{} of $H^2(S^{[n,p]},{\mathbb{Z}}/p)$.

Recall that the number of relations in a minimal presentation of a pro-$p$ group $G$ is given by $\dim H^2(G,{\mathbb{Z}}/p)$ [@NeukirchSchmidtWingberg]\*[Cor. 3.9.5]{}. In view of (\[size of Lyn\]), Theorem \[basis\] gives this number for $G=S^{[n,p]}$:

\[dim of H2\] One has $$\dim_{{\mathbb{F}}_p}H^2(S^{[n,p]},{\mathbb{Z}}/p)=\dim_{{\mathbb{F}}_p}(S^{(n,p)}/S^{(n+1,p)})=\sum_{s=1}^n\varphi_s(|X|),$$ where $\varphi_s$ is the necklace map.

The shuffle relations
=====================

We recall the following constructions from [@ChenFoxLyndon58], [@Reutenauer93]\*[pp. 134–135]{}. Let $u_1{,\ldots,}u_t\in X^*$ be words of lengths $s_1{,\ldots,}s_t$, respectively. We say that a word $w\in  X^*$ of length $1\leq n\leq s_1+\cdots+s_t$ is an [**infiltration**]{} of $u_1{,\ldots,}u_t$, if there exist sets $I_1{,\ldots,}I_t$ of respective cardinalities $s_1{,\ldots,}s_t$ such that $\{1,2{,\ldots,}n\}=I_1\cup\cdots \cup I_t$ and the restriction of $w$ to the index set $I_j$ is $u_j$, $j=1,2{,\ldots,}t$. We then write $w=w(I_1{,\ldots,}I_t,u_1{,\ldots,}u_t)$. We write $\operatorname{Infil}(u_1{,\ldots,}u_t)$ for the set of all infiltrations of $u_1{,\ldots,}u_t$. The [**infiltration product**]{} $u_1\downarrow\cdots\downarrow u_t$ of $u_1{,\ldots,}u_t$ is the polynomial $\sum w$ in ${\mathbb{Z}}\langle X\rangle$, where the sum is over all such infiltrations, taken with multiplicity.

If in the above setting, the sets $I_1{,\ldots,}I_t$ are pairwise disjoint, then $w(I_1{,\ldots,}I_t,u_1{,\ldots,}u_t)$ is called a [**shuffle**]{} of $u_1{,\ldots,}u_t$. We write $\operatorname{Sh}(u_1{,\ldots,}u_t)$ for the set of all shuffles of $u_1{,\ldots,}u_t$. It consists of the words in $\operatorname{Infil}(u_1{,\ldots,}u_t)$ of length $s_1+\cdots+s_t$. The [**shuffle product**]{} $u_1\sha\cdots\sha u_t$ is the polynomial $\sum w(I_1{,\ldots,}I_t,u_1{,\ldots,}u_t)$ in ${\mathbb{Z}}\langle X\rangle$, where the sum is over all shuffles of $u_1{,\ldots,}u_t$, taken with multiplicity. Thus $u_1\sha\cdots\sha u_t$ is the homogenous part of $u_1\downarrow\cdots\downarrow u_t$ of (maximal) degree $s_1+\cdots+s_t$. For instance $$\begin{split}
(xy)\downarrow(xz)&=(xyxz)+2(xxyz)+2(xxzy)+(xzxy)+(xyz)+(xzy), \quad \\
(xy)\sha(xz)&=(xyxz)+2(xxyz)+2(xxzy)+(xzxy)\\
(x)\downarrow(x)&=2(xx)+(x), \quad (x)\sha(x)=2(xx).
\end{split}$$

We may view infiltration and shuffle products also as elements of ${\mathbb{Z}}_p\langle X\rangle$. Let $\operatorname{Shuffles}(X)$ be the ${\mathbb{Z}}$-submodule of ${\mathbb{Z}}\langle X\rangle$ generated by all shuffle products $u\sha v$, with $\emptyset \neq u,v\in X^*$. Let $\operatorname{Shuffles}_n(X)$ be its homogenous component of degree $n$.

\[Shuffles for small n\] $\operatorname{Shuffles}_1(X)=\{0\}$, $$\begin{split}
\operatorname{Shuffles}_2(X)&=\langle (xy)+(yx)\ |\ x,y\in X\rangle,\\
\operatorname{Shuffles}_3(X)&=\langle(xyz)+(xzy)+(zxy)\ |\ x,y,z\in X\rangle.
\end{split}$$

Let $(\cdot,\cdot)$ be the pairing of (\[bilinear\]) for the ring $R={\mathbb{Z}}_p$. As before, $S=S_X$ is the free profinite group on the set $X$. The following fact is due to Chen, Fox, and Lyndon in discrete case [@ChenFoxLyndon58]\*[Th. 3.6]{} (see also [@Morishita12]\*[Prop. 8.6]{}, [@Reutenauer93]\*[Lemma 6.7]{}), as well as [@Vogel05]\*[Prop. 2.25]{} in the profinite case.

\[CFL\] For every $\emptyset\neq u,v\in X^*$ and every ${\sigma}\in S$ one has $${\epsilon}_{u,{\mathbb{Z}}_p}({\sigma}){\epsilon}_{v,{\mathbb{Z}}_p}({\sigma})=({\Lambda}_{{\mathbb{Z}}_p}({\sigma}),u\downarrow v).$$

\[Lam and shuffles\] Let $u,v$ be nonempty words in $X^*$ with $s=|u|+|v|\leq n$. For every ${\sigma}\in S^{(n,p)}$ one has $({\Lambda}_{{\mathbb{Z}}_p}({\sigma}),u\sha v)\in p^{n-s+1}{\mathbb{Z}}_p$.

If $w$ is a nonempty word of length $|w|<s$, then by Proposition \[Koch\](b), ${\epsilon}_{w,{\mathbb{Z}}_p}({\sigma})\in p^{n-|w|}{\mathbb{Z}}_p\subseteq p^{n-s+1}{\mathbb{Z}}_p$. In particular, this is the case for $w=u$, $w=v$, and when $w\in\operatorname{Infil}(u,v)\setminus\operatorname{Sh}(u,v)$. It follows from Proposition \[CFL\] that $({\Lambda}_{{\mathbb{Z}}_p}({\sigma}),u\sha v)\in p^{n-s+1}{\mathbb{Z}}_p$.

We obtain the following [**shuffle relations**]{} (see also [@VogelThesis]\*[Cor. 1.2.10]{} and [@FennSjerve84]\*[Th. 6.8]{}). We write $X^s$ for the set of words in $X^*$ of length $s$.

\[shuffle relations\] For every $\emptyset\neq  u,v\in X^*$ with $s=|u|+|v|\leq n$ one has $$\sum_{w\in X^s}(u\sha v)_w{\alpha}_{w,n}=0.$$

For ${\sigma}\in S^{(n,p)}$, Corollary \[Lam and shuffles\] gives $$\sum_{w\in X^s}(u\sha v)_w{\epsilon}_{w,{\mathbb{Z}}_p}({\sigma})=\sum_{w\in X^*}(u\sha v)_w{\epsilon}_{w,{\mathbb{Z}}_p}({\sigma})=({\Lambda}_{{\mathbb{Z}}_p}({\sigma}),u\sha v)\in p^{n-s+1}{\mathbb{Z}}_p.$$ Therefore, by Lemma \[description of pairing 2\], $$\begin{split}
({\sigma},\sum_{w\in X^s}(u\sha v)_w{\alpha}_{w,n})_n&=\sum_{w\in X^s}(u\sha v)_w({\sigma},{\alpha}_{w,n})_n
=\sum_{w\in X^s}(u\sha v)_w\,\iota_{n,s}({\epsilon}_{w,{\mathbb{Z}}/p^{n-s+1}}({\sigma}))\\
&=\iota_{n,s}\Bigl(\sum_{w\in X^s}(u\sha v)_w{\epsilon}_{w,{\mathbb{Z}}/p^{n-s+1}}({\sigma})\Bigr)=0.
\end{split}$$ Now use the fact that $(\cdot,\cdot)_n\colon S^{(n,p)}\times H^2(S^{[n,p]},{\mathbb{Z}}/p)\to{\mathbb{Z}}/p$ has a trivial right kernel.

\[structure theorem\] There is a canonical epimorphism $$\begin{split}
\bigoplus_{s=1}^n\Bigl(\bigl(\bigoplus_{w\in X^s} {\mathbb{Z}}\bigr)/&\operatorname{Shuffles}_s(X)\Bigr){\otimes}({\mathbb{Z}}/p)\to H^2(S^{[n,p]},{\mathbb{Z}}/p) \\
& (\bar r_w)_w\mapsto\sum_w r_w{\alpha}_{w,n}.
\end{split}$$

By Theorem \[shuffle relations\] this homomorphism is well defined. By Theorem \[basis\](a), it is surjective.

In view of Lemma \[description of pairing 2\], the epimorphism of Corollary \[structure theorem\] and the canonical pairing $(\cdot,\cdot)_n$ induce a bilinear map $$\begin{split}
S^{(n,p)} &\times \bigoplus_{s=1}^n\Bigl(\bigl(\bigoplus_{w\in X^s}{\mathbb{Z}}\bigr)/\operatorname{Shuffles}_s(X)\Bigr)\to {\mathbb{Z}}/p, \quad \\
&({\sigma},\overline{(r_w)}_w)=\sum_wr_w\iota_{n,s}({\epsilon}_{w,{\mathbb{Z}}/p^{n-s+1}}({\sigma}))
\end{split}$$ with left kernel $S^{(n+1,p)}$.

\[example\] We show that for every $x_1,x_2{,\ldots,}x_k\in X$ one has $$(x_1x_2\cdots x_k)+(-1)^{k-1}(x_k\cdots x_2x_1)\in\operatorname{Shuffles}_n(X).$$ We may assume that $x_1,x_2{,\ldots,}x_k$ are distinct. For $1\leq l\leq k-1$ let $u_l=(x_l\cdots x_2x_1)$ and $v_l=(x_{l+1}\cdots x_k)$. We consider the polynomial $\sum_{l=1}^{k-1}(-1)^{l-1}u_l\sha v_l$ in ${\mathbb{Z}}\langle X\rangle$. It is homogenous of degree $k$. If $w\in\operatorname{Sh}(u_l,v_l)$, then either:

1.  $x_l$ appears before $x_{l+1}$ in $w$, and then $w$ appears with an opposite sign also in $\operatorname{Sh}(u_{l-1},v_{l-1})$; or

2.  $x_{l+1}$ appears before $x_l$ in $w$, and then $w$ appears with opposite sign also in $\operatorname{Sh}(u_{l+1},v_{l+1})$.

The only exceptions are $w=(x_1x_2\cdots x_k)\in\operatorname{Sh}(u_1,v_1)$ and $w=(x_k\cdots x_2x_1)\in \operatorname{Sh}(u_{k-1},v_{k-1})$. This shows that $$(x_1x_2\cdots x_k)+(-1)^k(x_k\cdots x_2x_1)=\sum_{l=1}^{k-1}(-1)^{l-1}u_l\sha v_l.$$ For $1\leq k\leq n$ Corollary \[structure theorem\] therefore implies that $${\alpha}_{(x_1x_2\cdots x_k),n}=(-1)^{k-1}{\alpha}_{(x_k\cdots x_2x_1),n}.$$

Example: The case $n=2$ {#section on n=2}
=======================

Our results in this case are fairly well known, and are brought here in order to illustrate the general theory.

As before let $S=S_X$ with $X$ totally ordered. Here $S^{(2,p)}=S^p[S,S]$ and $\bar S=S^{[2,p]}$ is the maximal elementary $p$-abelian quotient of $S$. We may identify $H^1(S,{\mathbb{Z}}/p)=H^1(\bar S,{\mathbb{Z}}/p){\cong}\bigoplus_{x\in X}{\mathbb{Z}}/p$. Let $\chi_{x,{\mathbb{Z}}/p}={\epsilon}_{(x),{\mathbb{Z}}/p}$, $x\in X$, be the basis of $H^1(S,{\mathbb{Z}}/p)$ dual to $X$ (see Remark \[dual basis\]).

The Lyndon words $w$ of length $\leq2$ are $(x)$, where $x\in X$, and $(xy)$, where $x,y\in X$ and $x<y$. For these words we have $\tau_{(x)}=x$ and $\tau_{(xy)}=[x,y]$. By Examples \[examples of alp\](1)(3), $${\alpha}_{(x),2}={\mathrm{Bock}}_{p,\bar S}(\chi_{x,{\mathbb{Z}}/p}), \quad {\alpha}_{(xy),2}=\chi_{x,{\mathbb{Z}}/p}\cup\chi_{y,{\mathbb{Z}}/p}.$$ Hence, by Theorem \[basis\], ${\mathrm{Bock}}_{p,\bar S}(\chi_{x,{\mathbb{Z}}/p})$ and $\chi_{x,{\mathbb{Z}}/p}\cup\chi_{y,{\mathbb{Z}}/p}$, where $x<y$, form a ${\mathbb{Z}}/p$-linear basis of $H^2(\bar S,{\mathbb{Z}}/p)$. Furthermore, when $X$ is finite, the elements of the form $x^p$ and $[x,y]$ with $x,y\in X$, $x<y$, form a ${\mathbb{Z}}/p$-linear basis of $S^{(2,p)}/S^{(3,p)}$. In view of Examples \[Shuffles for small n\] and Corollary \[structure theorem\], the map $(\bar r_w)\mapsto\sum_w r_w{\alpha}_{w,2}$ induces an epimorphism $$\bigoplus_{x\in X}{\mathbb{Z}}/p\oplus\Bigl(\bigl(\bigoplus_{x,y\in X}{\mathbb{Z}}\bigr)/\langle (xy)+(yx)\ |\ x,y\in X\rangle\Bigr){\otimes}({\mathbb{Z}}/p)\to H^2(\bar S,{\mathbb{Z}}/p).$$ It coincides with the map $$H^1(\bar S,{\mathbb{Z}}/p)\oplus{\textstyle\bigwedge^2H^1(\bar S,{\mathbb{Z}}/p)}\to H^2(\bar S,{\mathbb{Z}}/p)$$ which is ${\mathrm{Bock}}_{p,\bar S}$ on the first component and $\cup$ on the second component. When $p\neq2$ the direct sum is a free ${\mathbb{Z}}/p$-module on $\operatorname{Lyn}_{\leq2}(X)$, and by comparing dimensions we see that the epimorphism is in fact an isomorphism (compare [@EfratMinac11]\*[Cor. 2.9(a)]{}). However when $p=2$ one has ${\mathrm{Bock}}_{2,\bar S}(\chi)=\chi\cup\chi$ [@EfratMinac11]\*[Lemma 2.4]{}, so the above epimorphism is not injective.

Next, Proposition \[vanishing of iota\] shows that the matrix $(\langle w,w'\rangle_2)$, where $w,w'\in\operatorname{Lyn}_{\leq2}(X)$, is the identity matrix. In view of Corollary \[equality of the two pairings\], it coincides with the matrix $\bigl((\tau_w^{p^{2-|w|}},{\alpha}_{w',2})_2\bigr)$. Thus $$\begin{split}
&(x^p,{\mathrm{Bock}}_{p,\bar S}(\chi_{x,{\mathbb{Z}}/p}))_2=1\hbox{ for every } x\in X ,\\
&(x^p,{\mathrm{Bock}}_{p,\bar S}(\chi_{y,{\mathbb{Z}}/p}))_2=0 \hbox{ for every } x,y\in X, x\neq y,\\
&(x^p,\chi_{y,{\mathbb{Z}}/p}\cup\chi_{z,{\mathbb{Z}}/p})_2=0 \hbox{ for every } x,y,z\in X,\\
&([x,y],{\mathrm{Bock}}_{p,\bar S}(\chi_{z,{\mathbb{Z}}/p}))_2=0 \hbox{ for every } x,y,z\in X,\\
&([x,y],\chi_{z,{\mathbb{Z}}/p}\cup\chi_{t,{\mathbb{Z}}/p})_2=0 \hbox{ for every } x,y,z,t\in X, (xy)\neq(zt),(tz),\\
&([x,y],\chi_{x,{\mathbb{Z}}/p}\cup\chi_{y,{\mathbb{Z}}/p})_2=1 \hbox{ for every } x,y\in X \hbox{ with } x<y.
\end{split}$$ This recovers well known facts from [@Labute66]\*[§2.3]{}, [@Koch02]\*[§7.8]{} and [@NeukirchSchmidtWingberg]\*[Th. 3.9.13 and Prop. 3.9.14]{}

Example: The case $n=3$. {#section on n=3}
========================

Here $S^{(3,p)}=S^{p^2}[S,S]^p[S,[S,S]]$. We abbreviate $\bar S=S^{[3,p]}$. Recall that $\operatorname{Lyn}_{\leq3}(X)$ consists of the words $$\begin{split}
&(x) \hbox{ for } x\in X,\\
& (xy), (xxy), (xyy) \hbox{ for } x,y\in X \hbox{ with } x<y, \\
&  (xyz), (xzy) \hbox{  for } x,y,z\in X \hbox{ with }  x<y<z.
\end{split}$$ For these words $$\begin{split}
\tau_{(x)}=x, \quad
&\tau_{(xy)}=[x,y],\quad
\tau_{(xxy)}=[x,[x,y]], \quad
\tau_{(xyy)}=[[x,y],y],\quad \\
&\tau_{(xyz)}=[x,[y,z]], \quad
\tau_{(xzy)}=[[x,z],y].
\end{split}$$

By Theorem \[generators\], the cosets of $$x^{p^3},\  [x,y]^p,\  [x,[x,y]],\ [[x,y],y],\ [x,[y,z]],\ [[x,z],y],$$ with $x,y,z$ as above, generate $S^{(3,p)}/S^{(4,p)}$. When $X$ is finite, they form a linear basis of $S^{(3,p)}/S^{(4,p)}$ over ${\mathbb{Z}}/p$ (Theorem \[basis\](b)). Furthermore, Theorem \[basis\](a) gives:

The following cohomology elements form a ${\mathbb{Z}}/p$-linear basis of $H^2(\bar S,{\mathbb{Z}}/p)$: $${\alpha}_{(x),3}, \ {\alpha}_{(xy),3},\ {\alpha}_{(xxy),3},\ {\alpha}_{(xyy),3},\ {\alpha}_{(xyz),3},\ {\alpha}_{(xzy),3},$$ where $x,y,z\in X$ and we assume that $x<y<z$.

By Examples \[examples of alp\], ${\alpha}_{(x),3}={\mathrm{Bock}}_{p^2,\bar S}(\chi_{x,{\mathbb{Z}}/p^2})$, and for every $x,y,z\in X$, ${\alpha}_{(xyz),3}$ belongs to the triple Massey product $\langle\chi_{x,{\mathbb{Z}}/p},\chi_{y,{\mathbb{Z}}/p},\chi_{z,{\mathbb{Z}}/p}\rangle\subseteq H^2(\bar S,{\mathbb{Z}}/p)$.

We further recall that ${\alpha}_{(xy),3}$ is the pullback to $H^2(\bar S,{\mathbb{Z}}/p)$ under $\bar\rho^{(xy)}_{{\mathbb{Z}}/p^2}\colon \bar S\to{\mathbb{U}}_3({\mathbb{Z}}/p^2)^{[3,p]}$ of the cohomology element in $H^2({\mathbb{U}}_3({\mathbb{Z}}/p^2)^{[3,p]},{\mathbb{Z}}/p)$ corresponding to the central extension $$0\to{\mathbb{Z}}/p\to {\mathbb{U}}_3({\mathbb{Z}}/p^2)\to {\mathbb{U}}_3({\mathbb{Z}}/p^2)^{[3,p]}\to1.$$ Alternatively, it has the following explicit description: By Proposition \[properties of dbU\](a), $ {\mathbb{U}}_3({\mathbb{Z}}/p^2)^{(3,p)}=I_3+{\mathbb{Z}}pE_{13}$, and let $\iota=\iota_{3,2}^{\mathbb{U}}\colon {\mathbb{U}}_3({\mathbb{Z}}/p^2)^{(3,p)}\xrightarrow{\sim}{\mathbb{Z}}/p$ be the natural isomorphism. By (\[theta and rho\]) and (\[alp and del\]), ${\alpha}_{(xy),3}=-\operatorname{trg}(\theta)$, where $\theta=\iota\circ(\rho^{(xy)}_{{\mathbb{Z}}/p^2}|_{S^{(3,p)}})$ and $\operatorname{trg}\colon H^1(S^{(3,p)},{\mathbb{Z}}/p)^S\xrightarrow{\sim} H^2(\bar S,{\mathbb{Z}}/p)$ is the transgression isomorphism.

Next we compute the matrix $((\tau_w^{p^{3-|w|}},{\alpha}_{w',3})_3)=(\langle w,w'\rangle_3)$, where $w,w'\in\operatorname{Lyn}_{\leq3}(X)$:

\[uuu\] For $w,w'\in\operatorname{Lyn}_{\leq3}(X)$ one has $$\langle w,w'\rangle_3=
\begin{cases}
\ \ 1, &\hbox{if } w=w';\\
-1,&\hbox{if } w=(xyz), \ w'=(xzy)  \hbox{ for some } x,y,z\in X, \ x<y<z;
\\
\ \ 0,&\hbox{otherwise}.
\end{cases}$$

In view of Proposition \[vanishing of iota\], it is enough to show the assertion when $w\neq w'$, either $|w|=|w'|$ or $2|w|\leq|w'|$, and the letters of $w'$ appear in $w$. Furthermore, when $|w|=|w'|$ we may assume that $w\leq_{\rm alp} w'$.

Thus when $w$ has one of the forms $(x),(xy),(xyy),(xzy)$ (where $x<y<z$) there is nothing more to show.

When $w=(xxy)$ with $x<y$ we need to check only the word $w'=(xyy)$. Then Lemma \[commutators\] gives $$\begin{split}
\langle(xxy),(xyy)\rangle_3&={\epsilon}_{(xyy),{\mathbb{Z}}/p}([x,[x,y]])\\
&={\epsilon}_{(x),{\mathbb{Z}}/p}(x)\cdot{\epsilon}_{(yy),{\mathbb{Z}}/p}([x,y])-{\epsilon}_{(y),{\mathbb{Z}}/p}(x)\cdot{\epsilon}_{(xy),{\mathbb{Z}}/p}([x,y])\\
&=1\cdot0-0\cdot1=0.
\end{split}$$

When $w=(xyz)$ with $x<y<z$ we need to check only the word $w'=(xzy)$. Then Lemma \[commutators\] gives $$\begin{split}
\langle(xyz),(xzy)\rangle_3&={\epsilon}_{(xzy),{\mathbb{Z}}/p}([x,[y,z]])\\
&={\epsilon}_{(x),{\mathbb{Z}}/p}(x)\cdot{\epsilon}_{(zy),{\mathbb{Z}}/p}([y,z])-{\epsilon}_{(y),{\mathbb{Z}}/p}(x)\cdot{\epsilon}_{(xz),{\mathbb{Z}}/p}([y,z])\\
&=1\cdot(-1)-0\cdot0=-1.
\end{split}$$ This completes the verification in all cases.

In view of Examples \[Shuffles for small n\], Corollary \[structure theorem\] gives rise to an epimorphism $$\label{big epimorphism}
\begin{split}
\bigoplus_{x\in X}{\mathbb{Z}}/p&\oplus\Bigl(\bigl(\bigoplus_{x,y\in X}{\mathbb{Z}}(xy)\bigr)/\langle (xy)+(yx)\ |\ x,y\in X\rangle\Bigr){\otimes}({\mathbb{Z}}/p)\\
&\oplus\Bigl(\bigl(\bigoplus_{x,y,z\in X}{\mathbb{Z}}(xyz)\bigr)/\langle (xyz)+(xzy)+(zxy)\ |\ x,y,z\in X\rangle\Bigr){\otimes}({\mathbb{Z}}/p)\\
&\to H^2(\bar S,{\mathbb{Z}}/p).
\end{split}$$ Moreover, for $x,y,z\in X$, $x<y<z$, we have $$\begin{split}
&(yx)=(x)\sha(y)-(xy)\\ &2(xx)=(x)\sha(x)\\ &(xyx)=(x)\sha(xy)-2(xxy)\\ &(yxx)=(x)\sha(yx)-(xx)\sha(y)+(xxy)\\&(yxy)=(xy)\sha(y)-2(xyy)\\&(yyx)=(yy)\sha(x)-(y)\sha(xy)+(xyy)\\&(yxz)=(y)\sha(xz)-(xyz)-(xzy)\\&(zxy)=(z)\sha(xy)-(xzy)-(xyz)\\&(yzx)=(zx)\sha(y)-(x)\sha(zy)+(xzy)\\&(zyx)=(yx)\sha(z)-(x)\sha(yz)+(xyz)\\&3(xxx)=(x)\sha(xx). \end{split}$$ These congruences and Example \[examples of Lyndon words\] imply that $$\begin{split}
&\sum_{w\in X^2}{\mathbb{Z}}w\equiv \sum_{w\in \operatorname{Lyn}_2(X)}{\mathbb{Z}}w+\hbox{ 2-torsion}
\pmod{\operatorname{Shuffles}_2(X)},\\
&\sum_{w\in X^3}{\mathbb{Z}}w\equiv \sum_{w\in \operatorname{Lyn}_3(X)}{\mathbb{Z}}w+\hbox{ 3-torsion} \pmod{\operatorname{Shuffles}_3(X)}.\\
\end{split}$$ Therefore, for $p>3$, the direct sum in (\[big epimorphism\]) is the free ${\mathbb{Z}}/p$-module on the basis $\operatorname{Lyn}_{\leq3}(X)$. Thus the epimorphism (\[big epimorphism\]) maps the ${\mathbb{Z}}/p$-linear basis $1w$, $w\in\operatorname{Lyn}_{\leq3}(X)$, bijectively onto the ${\mathbb{Z}}/p$-linear basis ${\alpha}_{w,3}$, $w\in\operatorname{Lyn}_{\leq3}(X)$ (see Theorem \[basis\]). Consequently we have:

\[shuffle relations for n=3\] For $n=3$ and $p>3$, (\[big epimorphism\]) is an isomorphism. Thus all relations in $H^2(S^{[3,p]},{\mathbb{Z}}/p)$ are consequences of the shuffle relations of Theorem \[shuffle relations\].

[^1]: This work was supported by the Israel Science Foundation (grant No. 152/13).
