This question is follow up of [this MO-post](https://mathoverflow.net/q/429619/61536).


First let us recall the necessary definitions.


A function $f:X\to X$ on a group $X$ is called a *polynomial* if there exists $n\in\mathbb N$ and elements $a\_0,\dots,a\_n\in X$ such that $f(x)=a\_0xa\_1x\cdots xa\_n$ for all $x\in X$.


Let $\mathrm{Poly(X)}$ be the set of all polynomials on a group $X$. It is a submonoid of the monoid $X^X$ of all self-maps of $X$.


Observe that each polynomial $f$ on a commutative group $X$ is of the form $f(x)=ax^n$ for some $a\in X$ and $n\in \mathbb N$, which implies that $|\mathrm{Poly}(X)|=|X|\cdot\exp(X)$ for each finite commutative group $X$.


Here $\exp(X):=\min\{n\ge 1:\forall x\in X\;\;(x^n=1)\}$ is the exponent of the group $X$.


Since any group $X$ acts effectively on $\mathrm{Poly}(X)$ by left (or right) shifts, the cardinal $|\mathrm{Poly}(X)|$ is divisible by $|X|$.



> 
> **Problem 1.** Is $|\mathrm{Poly}(X)|$ divisible by $|X|\cdot\exp(X)$ for every finite group $X$?
> 
> 
> 


The cardinality of the monoid $\mathrm{Poly}(X)$ was calculated by [Peter Taylor](https://gist.github.com/pjt33/b9e1e62291110b164e091ef7c2f7ead5) for all non-commutative groups $X$ of cardinality $|X|<24$.



> 
> **Problem 2.** Is $|\mathrm{Poly}(X)|$ divisible by $|X|^2$ for every non-commutative finite group $X$?
> 
> 
> 


Peter Taylow observed that the answer to Problem 2 is negative for the group $D\_{12}=GAP(12,4)$ with $|\mathrm{Poly}(D\_{12})|=648=2^3\times 3^4$. So, only Problems 1 and 3 remain open.


The calculations of Peter Taylor show that the following problem has affirmative answer for all finite groups of cardinality $<24$:



> 
> **Problem 3.** Let $X$ be a finite group and $p$ be a prime number dividing $|\mathrm{Poly}(X)|$. Is $p$ a divisor of $|X|$?
> 
> 
> 


**Remark 1.** The answer to Problems 2 and 3 are affirmative for finite simple groups since $\mathrm{Poly}(X)=X^X$ for any non-commutative simple finite group $X$, see the [answer of @YCor](https://mathoverflow.net/a/429635/61536) to [this MO-question](https://mathoverflow.net/q/429619/61536).



The number of polynomials on a finite group, II
This is an answer to problem 1 and problem 3:


As noted in the comments, $\operatorname{Poly}(G)$ with pointwise multiplication is a group for finite $G$. Consider the homomorphism $\operatorname{Poly}(G)\to G$ given by evaluating at $1$. It is surjective (as seen by constant polynomials), and the kernel contains an element of order $\operatorname{exp}(G)$, the identity polynomial. So the kernel has order divisible by $\operatorname{exp}(G)$, and thus $\operatorname{Poly}(G)$ has order divisible by $\operatorname{exp}(G)\cdot |G|$.


Let me also answer problem 3! If $|\operatorname{Poly}(G)|$ is divisible by $p$, then there is an element $f\in \operatorname{Poly}(G)$ of order $p$. This means all values of $f$ have order dividing $p$, and at least one is nontrivial. So $G$ must have an element of order $p$, thus $p$ divides $|G|$.


