Diameter of a finite group with respect to a generating set (source code)

= Diameter of a finite group with respect to a generating set
{title2=$\operatorname{diam}_S(G)$}

For a <finite group> $G$ with a symmetric <generating set> $S$, its diameter is
$$
\operatorname{diam}_S(G)=\min\{n:S^n=G\}.
$$
Equivalently, it is the diameter of the <Cayley graph> $\operatorname{Cay}_S(G)$.