\chapter*{Preface}

\mainmatter

\title{Conservation Law of Utility and Equilibria in Non-Zero Sum Games}
\author{Roman V. Belavkin\inst{1}}
\authorrunning{Roman Belavkin}
\tocauthor{Roman Belavkin}
\institute{School of Engineering and Information Sciences\\
Middlesex University, London NW4 4BT, UK\\
Draft of 12 October 2010}

\maketitle

\begin{abstract}
This short note demonstrates how one can define a transformation of a
non-zero sum game into a zero sum, so that the optimal mixed strategy
achieving equilibrium always exists.  The transformation is equivalent
to introduction of a passive player into a game (a player with a
singleton set of pure strategies), whose payoff depends on the actions
of the active players, and it is justified by the law of conservation
of utility in a game.  In a transformed game, each participant plays
against all other players, including the passive player.  The
advantage of this approach is that the transformed game is zero-sum
and has an equilibrium solution.  The optimal strategy and the value
of the new game, however, can be different from strategies that are
rational in the original game.  We demonstrate the principle using the
Prisoner's Dilemma example.\end{abstract}

\bibliographystyle{splncs}

Let $X$ and $Y$ be a dual pair of ordered linear spaces with respect
to bilinear form $\langle\cdot,\cdot\rangle:X\times Y\rightarrow\mathbb{R}$.
If $x\in X$ is a utility function $x:\Omega\rightarrow\mathbb{R}$, and $p\in
Y$, is a probability measure $p:\Omega\rightarrow[0,1]$, then the
expected utility is:
\[
\mathbb{E}_p\{x\}=\langle x,p\rangle
\]
Consider a game such that the space of outcomes of the game is
$\Omega:=\Omega_1\times\cdots\times\Omega_m$, where $\Omega_i$ is the
set of pure strategies of $i$th player, and $x_i:\Omega\rightarrow\mathbb{R}$
are the utility functions of the players.  In this case, the game is
zero-sum if and only if
\[
x_1+\cdots+x_m=0
\]
If $p_1,\dots,p_m\in Y$ are mixed strategies, then
\[
\sup_{p_1}\inf_{p_2,\dots,p_m}\mathbb{E}_{p_1\times\cdots\times p_m}\{x_1\}
\leq\inf_{p_2,\dots,p_m}\sup_{p_1}\mathbb{E}_{p_1\times\cdots\times p_2}\{x_1\}
\]
The famous Min-Max theorem \cite{Neumann-Morgenstern} states that in
zero-sum games, there always exists a mixed strategy $\bar
p_1\times\cdots\times\bar p_m$, called a {\em solution}, such that the
above holds with equality, and the common value is called the {\em
  value} of the game.

One of the problems in game theory is the existence of a solution to a
non-zero sum game.  Let us consider a game, such that
\[
x_1+\cdots+x_m\neq0
\]
If the utility functions add up to a constant function, so that $\sum
x_i\in\bR1:=\{\beta 1\in X:\beta\in\mathbb{R}\}$, then one can add a constant
function $x_0:=-\frac1m\sum x_i$ to each $x_i$ so that the new
utilities $\tilde x_i=x_i+x_0$ are zero-sum.  We argue that the same
can be done in the case when $x_0$ is not a constant function.  Thus,
we define a bijection $T:X\rightarrow\tilde X$ by
\[
T(x):=x+x_0=x-\frac1m\sum_{i=1}^m x_i
\]
It is easy to see that the new utility functions are zero sum:
\[
\tilde x_1+\cdots+\tilde x_m=\sum_{i=1}^m(x_i+x_0)=\sum_{i=1}^mx_i+mx_0
=\sum_{i=1}^mx_i-\sum_{i=1}^mx_i=0
\]
Notice also that the new utility functions are proportional to the differences between the original utility functions and the sum of utilities of other players
\[
\tilde x_i=T(x_i)
=x_i-\frac1m\sum x_i
=\frac1m\left((m-1)x_i-\sum_{j\neq i}x_j\right)
\]
In zero-sum games, $\tilde x_i=x_i$ (i.e. $T(x)=x$), because $x_0=0$,
or equivalently the utility functions differ by some constant function
$x_i-x_i\in\bR1$.  Our transformation applies also to the case when
these differences are not constant functions.

The interpretation of adding utility $x_0$ to $x_i$ is as follows.  We
can extend $\Omega=\prod_{i=1}^m\Omega_i$ to
$\tilde\Omega:=\Omega_0\times\Omega$, where $\Omega_0:=\{0\}$ is a
singleton set so that $\tilde \Omega=\Omega_0\times\Omega=\Omega$
(because a singleton set plays the role of a unit with respect to
multiplication of sets).  The singleton set $\Omega_0=\{0\}$
represents a player with only one pure strategy, and we refer to it as
a {\em passive player}.  In another interpretation, $\Omega_0$ may
represent a player, whose pure strategy has already been chosen.  The
payoff $mx_0:\Omega\rightarrow\mathbb{R}$ to this player, however, may be
non-constant, and depend on strategies of the other {\em active}
players (whose pure strategies have not yet been chosen).  We argue
that without including $\Omega_0$ and $x_0$ into the representation,
the total utility of active players $x_1+\cdots+x_m=-mx_0$ is not
constant, and therefore such a representation contradicts the {\em
  conservation law of utility} in a game:
\[
x_1+\cdots+x_m\in\bR1
\]
We argue that games, in which the above law is broken, such as the
non-zero sum games, have incomplete representation whereby some
passive player (or players) has not been taken into account.  The
complete representation is achieved by transformation $T(X)=X+x_0$,
and the transformed game is zero sum.  A solution to such a game
always exists, and its value is
\[
\mathbb{E}_{\bar p_1\times\cdots\times\bar p_m}\{\tilde x_i\}=
\mathbb{E}_{\bar p_1\times\cdots\times\bar p_m}\{x_i+x_0\}
\]
If $\mathbb{E}_{\bar p_1\times\cdots\times\bar p_m}\{x_0\}=0$ (e.g. if
$x_0=0$), then this value equals the value of the original game.

\begin{example}[Prisonner's Dilemma]
Let us consider the classical example of two-person game, when
$\Omega=\Omega_1\times\Omega_2$, and each player (the prisoner) has
two pure strategies $\Omega_i=\{0,1\}$ --- cooperate ($\omega=0$) or
defect ($\omega=1$).  The payoff to each player is given by the
utility function $x_i:\Omega\rightarrow\mathbb{R}$, which can be written in a
$2\times 2$-matrix form
\[
x_1=(x_{1ij})=\left(\begin{array}{rr}
-.6 & -10\\
0 & -5
\end{array}
\right)\,,\quad x_2=x_1^\dag
\]
The classical `rational' solution to this game is for each player to
use strategy $\omega=0$ (cooperate), so that $p_i(0)=1$, and
the value of the game is
\[
\mathbb{E}_{0\times0}\{x_i\}=-.6
\]
However, when human participants play this game, they usually
cooperate or defect with almost equal probability so that the observed
strategies are dramatically different from $p_i(0)=1$.  Note that for
$p_i(0)=.5$, the expected payoff to each player becomes significantly
lower
\[
\mathbb{E}_{.5\times.5}\{x_i\}=-3.9
\]
This `irrational' behaviour presents a paradox that defied many
attempts to explain it.

Observe that the game described is not zero-sum, because
\[
(x_{1ij})+(x_{2ij})=\left(\begin{array}{rr}
-1.2 & -10\\
-10 & -10
\end{array}\right)\quad\Rightarrow\quad
x_1+x_2\notin\bR1
\]
so that in fact the utilities $x_1$ and $x_2$ do not differ by any
constant function.  Let us now introduce the passive player
$\Omega_0=\{0\}$ (the detective), whose payoff is $2x_0=-(x_1+x_2)$,
and so $x_0$ is
\[
x_0=(x_{0ij})=-\frac12\Bigl[(x_{1ij})+(x_{2ij})\Bigr]=\left(
\begin{array}{rr}
.6&5\\
5&5
\end{array}\right)
\]
Thus, the payoff to the detective depends on the strategies of the
prisoners, and it is maximised if at least one of the prisoners
defects.  The utilities of the prisoners are transformed $T(x)=x+x_0$
to
\[
\tilde x_1=(\tilde x_{1ij})=\left(\begin{array}{rr}
0 & -5\\
5 & 0
\end{array}
\right)\,,\quad\tilde x_2=-\tilde x_1
\]
In this representation, the game becomes zero-sum, and it has solution
$\bar p_i(0)=.5$ and the value $\mathbb{E}_{.5\times.5}\{\tilde
x_i\}=\mathbb{E}_{.5\times.5}\{x_i+x_0\}=-3.9+3.9=0$.  This expected payoff
to each player is lower than that of the strategy $p_i(0)=1$, but it
is independent of the decision of the other player to defect.
\end{example}

Computer Science and Game Theory (cs.GT); Artificial Intelligence (cs.AI); Optimization and Control (math.OC)


Normal approximations for descents and inversions of permutations of multisets

Abstract: Normal approximations for descents and inversions of permutations of the set $\{1,2,...,n\}$ are well known. A number of sequences that occur in practice, such as the human genome and other genomes, contain many repeated elements. Motivated by such examples, we consider the number of inversions of a permutation $\pi(1), \pi(2),...,\pi(n)$ of a multiset with $n$ elements, which is the number of pairs $(i,j)$ with $1\leq i < j \leq n$ and $\pi(i)>\pi(j)$. The number of descents is the number of $i$ in the range $1\leq i < n$ such that $\pi(i) > \pi(i+1)$. We prove that, appropriately normalized, the distribution of both inversions and descents of a random permutation of the multiset approaches the normal distribution as $n\to\infty$, provided that the permutation is equally likely to be any possible permutation of the multiset and no element occurs more than $\alpha n$ times in the multiset for a fixed $\alpha$ with $0<\alpha < 1$. Both normal approximation theorems are proved using the size biased version of Stein's method of auxiliary randomization and are accompanied by error bounds.

\section{Introduction}
Let $\pi(1), \pi(2), \ldots, \pi(n)$ be a permutation of the multiset
$\{1^{n_1},2^{n_2},\ldots, h^{n_h}\}$ with
$n_1+\cdots+n_h = n$.  The number of inversions,
denoted $\mathop{\mathrm{inv}}(\pi)$, is defined as the number of pairs $(i,j)$ with
$1\leq i < j \leq n$ and $\pi(i) > \pi(j)$.  The number of descents,
denoted $\mathop{\mathrm{des}}(\pi)$, is the number of positions $i$ with $1\leq i < n$
and $\pi(i) > \pi(i+1)$. Assume that $\pi$ is uniformly distributed. In
this article, we use Stein's method to prove normal approximations with
error bounds for $\mathop{\mathrm{inv}}(\pi)$ and $\mathop{\mathrm{des}}(\pi)$.

In the special case where $\pi$ is a uniformly distributed permutation
of the set $\{1,2,\ldots,n\}$, the distributions of both $\mathop{\mathrm{inv}}(\pi)$ and
$\mathop{\mathrm{des}}(\pi)$ admit simple descriptions. The distribution of $\mathop{\mathrm{inv}}(\pi)$
is equal to that of the sum $X_1+\cdots+X_{n-1}$, where the random variables
$X_i$, $1\leq i\leq n-1$, are  independent with $X_i$ uniformly distributed
over the set $\{0,1,\ldots, i\}$. To obtain the distribution of $\mathop{\mathrm{des}}(\pi)$,
we need the sum $X_1+\cdots+X_{n-1}+X_n$, where the $X_i$ are
independent and uniformly distributed in the interval $[0,1]$.
The probability that this sum lies in the interval $[d,d+1]$ equals
the probability that $\mathop{\mathrm{des}}(\pi)$ equals $d$. According to Knuth
\cite{KnuthVol3}, the first of these two results was noticed by
O. Rodriguez in 1839.  The result about $\mathop{\mathrm{des}}(\pi)$ was alluded to
by Barton and Mallows \cite{BM65}. An elegant proof is due to Stanley
\cite{Stanley1}.

Normal approximations to $\mathop{\mathrm{des}}(\pi)$ and $\mathop{\mathrm{inv}}(\pi)$ in this special
case can be obtained using these results and standard versions of the
central limit theorem.
The bounds
\begin{align}
\sublabon{equation}
\Bigl|P\Biggl(\frac{\mathop{\mathrm{des}}(\pi) - (n-1)/2}{\sqrt{(n+1)/12}}\leq x\Biggr)-\Phi(x)\Bigr|
&\leq \frac{C}{\sqrt{n}} \label{eqn-1-1a}\\
\Bigl|P\Biggl(\frac{\mathop{\mathrm{inv}}(\pi)-\frac{1}{2}\binom{n}{2}}{\sqrt{n(n-1)(2n+5)/72}}\leq x
\Biggr)-\Phi(x)\Bigr| &\leq \frac{C}{\sqrt{n}},
\label{eqn-1-1b}
\end{align}
\sublaboff{equation}
\noindent where $C$ is a constant and $\Phi$ is the standard normal distribution, were proved
using the method of exchangeable pairs \cite{RR97, SteinBook}
by Fulman \cite{Fulman04}. Other proofs of \eqref{eqn-1-1a}
using Stein's method are sketched
in \cite{Conger1} and \cite{Goldstein04}.

 From the survey by Barton and Mallows \cite{BM65}, it appears
that the asymptotic normality of a quantity closely related to
$\mathop{\mathrm{des}}(\pi)$, where $\pi$ is a uniformly distributed permutation of
the set $\{1,\ldots,n\}$, was stated by Bienyam\'e in 1874
(Bull. Soc. Math. France, vol. 2, p. 153-154). Bienyam\'e was interested
in statistical applications. So were Levene and Wolfowitz \cite{LW1} who stated
that {\it runs} were widely used in quality control and in the study of
economic time series. Runs are the monotone segments within a sequence
of numbers and are closely related to descents.
An early proof of the asymptotic normality of descents, which is
implied by \eqref{eqn-1-1a}, is due to Wolfowitz \cite{Wolfowitz44}.

Let $\{1^{n_1}, 2^{n_2},\ldots, h^{n_h}\}$ be a multiset, where $n_a$, $1\leq a\leq h$, are positive integers. Let $n=n_1+n_2+\ldots+n_h$ be the number of elements of the multiset.
Let $\alpha$ be a fixed number in $(0,1)$.
We assume that $n_a \leq \alpha n$ for $1\leq a\leq h$.
Let $\pi$ be a uniformly distributed permutation of this multiset.
We consider $\mathop{\mathrm{inv}}(\pi)$ and $\mathop{\mathrm{des}}(\pi)$ in this more general situation.
The bounds
that we obtain for the errors in the normal approximations to these
quantities  depend
upon $\alpha$ and become infinite  as $\alpha \rightarrow 1$.
Let $h:R\rightarrow R$
be a bounded and piecewise continuously differentiable function and
let $\beta = \max(1/2,\alpha)$.
We use the size-bias version of Stein's method introduced by
Baldi, Rinott and Stein \cite{BRS89} and  prove that, for $n$ large enough,
\[
\Abs{\E h\Bigl(\frac{\mathop{\mathrm{inv}}(\pi)-\mu}{\sigma}\Bigr) - \Phi h} \leq
C\Biggl(\frac{\norm{h}}{\beta(1-\beta)(\beta(1-\beta)n^{1/2}-C_1 n^{-1/2})}
+\frac{\norm{Dh}}{(\beta(1-\beta)n^{1/3}-C_2n^{-2/3})^{3/2}}\Biggr)
\]
where $C$, $C_1$, and $C_2$ are some positive constants, $\Phi h$ is the expectation of $h$ with respect
to the standard normal distribution, and $\mu$ and $\sigma^2$ are the mean
and variance of $\mathop{\mathrm{inv}}(\pi)$, respectively.
If $\alpha \geq 1/2$, then $\beta = \alpha$. Therefore the bound above
diverges as $\alpha \rightarrow 1$.
We prove a similar result for $\mathop{\mathrm{des}}(\pi)$.

Bounds such as the one given in the previous paragraph require $h$ to
be continuous. Goldstein \cite{Goldstein04} has proved a normal approximation
theorem that holds for non-smooth $h$. We use that theorem to prove that
\[\Bigl|\P\Biggl(\frac{\mathop{\mathrm{inv}}(\pi)-\mu}{\sigma} \leq x\Biggr) - \Phi(x)\Bigr|
\leq C(\beta)/\sqrt{n}\]
and that
\[\Bigl|\P\Biggl(\frac{\mathop{\mathrm{des}}(\pi)-\mu}{\sigma} \leq x\Biggr) - \Phi(x)\Bigr|
\leq C(\beta)/\sqrt{n}.\]
These results are contained in Theorems \ref{thm-2-12} and
\ref{thm-2-16}  of this paper. The quantity $C(\beta)$ diverges when
$\alpha \rightarrow 1$. As before $\beta = \max(1/2,\alpha)$.
When the $n$ elements of the multiset are distinct, with $n\geq 2$, we may  use
$\alpha = 1/n$ and $\beta = 1/2$. Therefore the results stated above
imply \eqref{eqn-1-1a} and \eqref{eqn-1-1b}.

The generating function of the number of permutations of a multiset with a given
number of inversions is a rational function. Using this generating function, Diaconis
\cite{DiaconisBook} has shown that the asymptotic distribution of
$\mathop{\mathrm{inv}}(\pi)$, where $\pi$ is uniformly distributed over permutations of a multiset,
is normal. Theorem \ref{thm-2-12} about $\mathop{\mathrm{inv}}(\pi)$ is accompanied by an error bound
of the correct order, which is $O(1/\sqrt{n})$, and the dependence of the error bound
on $\alpha$ is also explicitly shown in our theorem. The generating function for
the number of permutations of a multiset with a given number of descents,
which is related to Foata's correspondence, was found
by MacMahon \cite{KnuthVol3} \cite{MacMahonBook}.
However, normal approximations to this quantity, such as the approximation
given in Theorem \ref{thm-2-16}, do not
seem to be available.

Segments of $\pi(1),\ldots, \pi(n)$ between successive descents, or
runs, are in ascending order. Knuth \cite{KnuthVol3} has stated that
runs are important in the study of sorting algorithms because runs are
segments that are already in sorted order. Among the applications of
descents and inversions to the study of sorting algorithms, multiway
merging with replacement selection merits special mention.  In this
sorting method, the given sequence is first split into runs and the
runs are merged together. Our results are pertinent to sorting
algorithms if the keys used for sorting are allowed to repeat. For
example, Theorem
\ref{thm-2-16} about $\mathop{\mathrm{des}}(\pi)$ gives an idea of how many runs
to expect if multiway merging is used on a sequence of records with repeated
keys.

Descents and inversions have been used as test statistics in the
special case where $\pi$ is a permutation of $\{1,2,\ldots,n\}$. As
already mentioned, early work on runs and descents was stimulated by
statistical applications.  Of the ten empirical tests for the
randomness of a sequence of distinct numbers discussed by Knuth
\cite{KnuthVol2}, one is based on runs and descents.
Taking our results into account, inversions and descents can be used
to test if a given permutation of a multiset of numbers is
random. There are other ways to test if a given permutation of a
multiset of numbers is random. If a permutation passes $n$ empirical
tests for randomness but fails the $n+1$st, it is not
random. Therefore having a greater number of empirical tests available
makes for more robust testing \cite{KnuthVol2}.

DNA sequences are strings of the four letters $A$, $C$, $G$, and $T$.
It is now well known that these sequences are far from random
\cite{GNC1}.  It has even been suggested that these sequences are
similar to human languages \cite{Mantegna1}.  Some commonly used
compression algorithms such as the Lempel-Ziv method fail to compress
typical DNA sequences however \cite{GNC1}.  The entropy estimates of
DNA sequences given in \cite{GNC1} and \cite{Mantegna1} proceed by
dividing the sequence into blocks in some way. For instance, blocks of
$6$ consecutive letters are considered in \cite{GNC1}. These entropy
estimates show that  DNA sequences are not random.

In Section 3, we report the descents and inversions of the $19$th
chromosome of the human genome mainly as an illustration.  We consider
all $24$ possible orderings of $A$, $C$, $G$, and $T$. With respect to
each of these orderings, a calculation of descents and inversions
shows that the number of descents and inversions of the DNA sequence
departs from the mean by a large multiple of the standard
deviation. It may be of some interest that this method of showing the
DNA sequence to be far from random considers only single letters
without dividing them into blocks.

Although we consider all possible orderings of $A$, $C$, $G$, and $T$,
it must be noted that the molecular weights of the corresponding
compounds implies the order $C<T<A<G$. This is as natural as any order
one can hope to find among four physical objects.

Our interest in permutations of multisets was provoked by their connection
to riffle shuffles of decks with repeated cards \cite{CV1}.

We do not give explicit numerical constants in our Theorems
\ref{thm-2-12} and \ref{thm-2-16} about
descents and inversions of permutations of multisets. It is worth
noting that explicit numerical constants are not given for most of the
detailed examples in Stein's book \cite{SteinBook}, and all the
examples in the papers by Baldi, Rinott, and Stein
\cite{BRS89}, by Goldstein and Rinott \cite{GR96}, and by Rinott
and Rotar \cite{RR97}. Furthermore, even the asymptotic normality for
descents of permutations of multisets implied by Theorem
\ref{thm-2-16} is a new result, and so is Theorem \ref{thm-2-12} which
shows the dependence of the bounds for normal approximation on
the size of the multiset and the parameter $\alpha$ that characterizes
the multiset.

\section{Descents and inversions of permutations of multisets}

If $W\geq 0$ is a non-negative and integrable random variable, the distribution of
$W^{\ast}$ is said to be $W$-size biased, if $\E(W f(W)) = \E W \E(f(W^\ast))$
for all continuous functions $f$ for which the expectation on the left hand
side of the equality exists.

Stein's method \cite{Stein72} \cite{SteinBook} refers to the use of auxiliary
randomization to find normal approximations to the distribution of some random
variables. In the theorem below, the
auxiliary randomization requires the construction of $W^{\ast}$ which must be
$W$-size biased. The theorem below can be found in
\cite{BRS89}, but we follow its formulation in \cite{GR96}.

\begin{thm}
Let $W$ be a non-negative random variable with $\E W = \mu$ and $\mathop{\mathrm{Var}}(W) = \sigma^2$.
Let $W^\ast$ be jointly defined with $W$ such that its distribution is $W$-size
biased. Let $h$ be a function from $R$ to $R$ such that $h$ is continuous
and its derivative $Dh$ is piecewise continuous. Then
\[\Abs{\E h\Bigl(\frac{W-\mu}{\sigma}\Bigr) - \Phi h}
\leq 2 \norm{h} \frac{\mu}{\sigma^2} \sqrt{\mathop{\mathrm{Var}}\bigl(\E(W^\ast-W|W)\bigr)}
+\norm{Dh}  \frac{\mu}{\sigma^3}\E(W^\ast-W)^2,\]
where $\Phi h$ is the expectation of $h$ with respect to the
standard normal distribution and $\norm{\cdot}$ is the supremum norm.
\label{thm-2-1}
\end{thm}

When $h$ is the indicator function of the half line $(-\infty,x]$, the following
theorem found in \cite{Goldstein04} applies. Its proof uses a smoothing
inequality and other techniques found in \cite{RR97}.

\begin{thm}
Let $W$ be a non-negative random variable with $\E W = \mu$ and $\mathop{\mathrm{Var}}(W) = \sigma^2$.
Let $W^\ast$ be jointly defined with $W$ such that its distribution is $W$-size
biased. Let $\abs{W^\ast-W} \leq B$ and let $A = B/\sigma$.
Let $B\leq \sigma^{3/2}/\sqrt{6\mu}$.
Then
\[\Abs{P\Bigl(\frac{W-\mu}{\sigma} \leq x\Bigr) - \Phi(x)}
\leq 0.4 A + \frac{\mu}{\sigma}(64A^2+4A^3)+\frac{23\mu}{\sigma^2}
\sqrt{\mathop{\mathrm{Var}}\bigl(\E(W^\ast-W|W)\bigr)},\]
where $\Phi$ is the standard normal distribution.
\label{thm-2-2}
\end{thm}

In Theorems \ref{thm-2-1} and \ref{thm-2-2} above, we added the superscript
$*$ to $W$ to denote a random variable with the $W$-size biased
distribution. In the lemma below, random variables $X_i$ with the
superscript $*$ do not necessarily have the $X_i$-size biased
distribution. Here and later, our convention is to use the superscript
$*$ when random variables are constructed as a part of the size biasing
procedure. This notation is due to \cite{BRS89}.

The construction of size biased variables in this paper will be based on the
following lemma found in \cite{BRS89} and \cite{GR96}.

\begin{lem}
Let $W=X_1+X_2+\ldots+X_n$, where each $X_i$ is a non-negative random variable
with finite mean.
Let $I$ be a random variable which is independent of the $X_i$ and
which satisfies $\P(I=i) = \E X_i/\sum_{j=1}^n\E X_j$. Define $W^\ast$
as $W^\ast = X_1^\ast+ X_2^\ast+\cdots+X_n^\ast$, where for given $I$ $X_I^\ast$ has
the $X_I$-size biased distribution and
\begin{equation}
\P\bigl((X_1^\ast,X_2^\ast,\ldots,X_n^\ast)\in A\bigl|I=i, X_i^\ast=x\bigr)
= \P\bigl((X_1,X_2,\ldots,X_n)\in A\bigl|X_i = x).
\label{eqn-2-1}
\end{equation}
Then $W^\ast$ has the $W$-size biased distribution.
\label{lem-2-3}
\end{lem}
Whenever Lemma \ref{lem-2-3} is applied here, we will find $X_i$ are $0$-$1$ valued
random variables, and the size biased distribution for such variables is
concentrated at $1$. Therefore, for our purposes, \eqref{eqn-2-1} can be written
as
\(\P\bigl((X_1^\ast,X_2^\ast,\ldots,X_n^\ast)\in A\bigl|I=i\bigr)
= \P\bigl((X_1,X_2,\ldots,X_n)\in A\bigl|X_i = 1)\).

Let $\pi$ be a uniformly distributed permutation of the multiset
$\{1^{n_1}, 2^{n_2},\ldots,h^{n_h}\}$ and $n=n_1+n_2+\ldots+n_h$. Each $n_a$,
$1\leq a\leq h$, is a positive integer. The symbols $i,j,k,l$, with and without
numerical subscripts, are used to index the set $\{1,2,\ldots,n\}$. The
symbols $a,b,c,d$ are used to index the set $\{1,2,\ldots,h\}$. We also
assume $n_a \leq \alpha n$ for $1\leq a \leq h$ and for some $\alpha$
in $(0,1)$, $n\geq 4$, and $h\geq 2$.

Define $X_{ij}$, for $i<j$, as $1$ if $\pi(i) > \pi(j)$ and as $0$ otherwise.
Some facts about the joint distribution of $X_{ij}$ will be necessary.
Denote the probabilities
\begin{align*}
&\P(X_{ij} = 1)\;\text{with $i<j$},\\
&\P(X_{ij_1}=1,X_{ij_2}=1)\; \text{with $i<j_1$ and $i<j_2$},\\
&\P(X_{i_1j}=1,X_{i_2j}=1)\; \text{with $i_1<j$ and $i_2<j$},\\
&\P(X_{ik}=1, X_{kj}=1)\; \text{with $i<k<j$,}\\
&\P(X_{i_1j_1}=1,X_{i_2j_2}=1)\;\text{with $i_1<j_1$, $i_2<j_2$, and
$(i_1,j_1)\neq(i_2,j_2)$}
\end{align*}
by $p_1$, $p_2$, $p_3$, $p_4$, and $p_5$, respectively.  Elementary arguments
can be used to deduce formulas, such as $p_1 = \sum_{a<b}n_a n_b/(n(n-1))$
and $p_4= \sum_{a<b<c}n_an_bn_c/(n(n-1)(n-2))$, for $p_1$, $p_2$, $p_3$,
$p_4$, and $p_5$. From such formulas, we deduce
\begin{align}
p_1 &= \frac{n^2-\sum_a n_a^2}{2n(n-1)}\nonumber\\
p_2+p_3+p_4 &= \frac{5n^3/6-n^2+(-3n/2+1)\sum_a n_a^2+(2/3)\sum_a n_a^3}{n(n-1)(n-2)}
\nonumber\\
p_4 &= \frac{n^3/6-(n/2)\sum_a n_a^2 + (1/3)\sum_an_a^3}{n(n-1)(n-2)}\nonumber\\
p_5 &= \frac{n^4/4-n^3+n^2/2+(1/4)\bigl(\sum_a n_a^2\bigr)^2+(-n^2/2+2n-1/2)\sum_{a}n_a^2
      -\sum_a n_a^3}{n(n-1)(n-2)(n-3)}.
\label{eqn-2-2}
\end{align}
The formulas in \eqref{eqn-2-2} will be used to derive expressions for
$\mathop{\mathrm{Var}}(\mathop{\mathrm{inv}}(\pi))$ and $\mathop{\mathrm{Var}}(\mathop{\mathrm{des}}(\pi))$.

The assumption $n_a \leq \alpha n$, for
some $\alpha \in (0,1)$, is used in the two lemmas below.
The lemmas, however, are worded in terms of $\beta = \max(1/2,\alpha)$
and use the weaker assumption $n_a \leq \beta n$ for
$\beta \in [1/2,1)$.
In both the lemmas the assumption $n_a\leq \beta n$
implies $h\geq 2$.

\begin{lem}
Assume $\beta\in[1/2,1)$, $n_a\geq 0$ for all $a$,
and $\sum_a n_a = n$. If $n_a \leq \beta n$ for $1\leq a\leq h$,
then
\(2\beta(1-\beta)n^2 \leq n^2-\sum_a n_a^2\leq n^2\) and
\(3\beta(1-\beta)n^3 \leq n^3-\sum_a n_a^3\leq n^3\).
\label{lem-2-4}
\end{lem}
\begin{proof}
To lower bound $n^2-\sum_a n_a^2$, note that $x\geq y> 0$, $\delta>0$,
and $y-\delta\geq 0$ imply $(x+\delta)^2+(y-\delta)^2 > x^2+y^2$.
Thus for a given sum $x+y$, the quantity $x^2+y^2$ increases when
the difference $x-y$ is increased.
Thus given $\sum_a n_a = n$ and the constraints
$n_a\geq 0$, the quantity $\sum_a n_a^2$ is
increased whenever two positive numbers are chosen from
$n_a$, $1\leq a \leq h$, and the lesser of them is decreased
and the greater increased by the same amount.
Therefore,
under the constraints $n_a\leq \beta n$,
$\sum_a n_a^2$ is maximum when $n_1=\beta n$,
$n_2=(1-\beta)n$, and $n_a = 0$ for $a>2$. The lower bound for
$n^3-\sum_a n_a^3$ is also obtained when $n_1=\beta n$,
$n_2=(1-\beta)n$, and $n_a = 0$ for $a>2$. The upper bounds are trivial.
\end{proof}

Concerning the lemma below, it is worth noting that $\beta^4-4\beta^4+4\beta-1
= (1-\beta)^2(\beta^2+2\beta-1) > 0$ for $\beta\in [1/2,1)$.
\begin{lem}
Assume $\beta\in[1/2,1)$, $n_a\geq 0$ for all $a$,
and $\sum_a n_a = n$. If $n_a \leq \beta n$ for $1\leq a\leq h$,
\[
(\beta^4-4\beta^2+4\beta-1)n^4 \leq n^4/3+\bigl(\sideset{}{_a}\sum n_a^2\bigr)^2
-(4n/3)\sideset{}{_a}\sum n_a^3 \leq n^4/3.
\]
\label{lem-2-5}
\end{lem}
\begin{proof}
The upper bound follows from the inequality $n\sum_an_a^3 \geq
\bigl(\sum_a n_a^2\bigr)^2$.

We prove the lower bound assuming $\beta > 1/2$.
The proof for $\beta=1/2$
can be obtained with minor changes. The proof will make careful use of
the Kuhn-Tucker conditions as explained in \cite[Theorem 9.2-3]{CiarletBook}.

We attempt to minimize
$J(n_1,n_2,\ldots, n_h)=\bigl(\sum_an_a^2\bigr)^2-(4n/3)\sum_a n_a^3$ subject to
the affine constraints $\sum_a n_a = n$, $-n_a \leq 0$, and $n_a-\beta n\leq 0$,
where the last two constraints hold for $1\leq a \leq h$.
We assume $n_1\geq n_2\geq\cdots\geq n_h\geq 0$ without loss of generality.

 Let $DJ$ be the gradient vector whose $a$th entry is
\[ \frac{\partial J}{\partial n_a} = 4n_a \sideset{}{_b}\sum n_b^2 - 4n n_a^2
= 4n_a\sideset{}{_b}\sum n_b(n_b-n_a).\]
The sum of the entries of $DJ$ must be $0$
because the term  $4n_a n_b (n_b-n_a)$ in $\partial J/\partial n_a$
is canceled by the term $4n_a n_b (n_a-n_b)$ in
$\partial J/\partial n_a$.
 If there exists an $a$ such
that $n_1 > n_a > 0$, then the first entry of $DJ$ must be strictly negative\
and therefore some other entry must be strictly positive.

Let $u\in R^h$ be the vector with all entries equal to $1$. Let $v_a\in R^h$
be the vector with its $a$th entry equal to $-1$ and all other entries equal to
$0$. Let $w_1 = -v_1$. Note that $n_a-\beta n=0$ is possible only if $a=1$
as we have assumed $\beta > 1/2$ and  $n_1\geq n_2\geq\cdots$

Suppose $(n_1,n_2,\ldots,n_h)$ is a local minimum of $J$. The
Kuhn-Tucker conditions require that it must be possible to make all
entries of $DJ$ zero by adding multiples of certain vectors. We are
always allowed to add any real multiple of $u$ because the constraint
$\sum_a n_a = n$ is always in force.  We are allowed to add
a positive multiple of $v_a$ if and only if $n_a=0$
because the constraint $-n_a\leq 0$ can then be violated by
making an infinitesimal change to $n_a$.
We are allowed to add a
positive multiple of $w_1$ if and only if $n_1-\beta n = 0$ by
a similar reason.

Let us first consider the type of local minimum where the Kuhn-Tucker conditions
can be satisfied without adding a positive multiple of $w_1$. Suppose
$n_1 > n_a > 0$ for some $a$ for such a local minimum. Then the first entry of
$DJ$ is strictly negative and some other entry is strictly positive.
If the positive entry is $\partial J/\partial n_b$, then $n_b$ must
be nonzero and therefore $n_b > 0$.
Such
a $DJ$ cannot be made zero by adding a multiple of $u$ and positive multiples
of $v_c$ corresponding to $n_c = 0$.
The only way to make the $b$th entry of $DJ$ equal to $0$ is by
adding a negative multiple of $u$. But this means the first entry
remains negative and nonzero, and the only way to make it $0$ is
by adding a multiple of $w_1$ which is not allowed by assumption.
Therefore any local minimum of this type must have
$n_1=n_2=\cdots=n_s=n/s$ and $n_c = 0$ for $c > s$, where $2\leq s \leq h$.
The value of $J$ at such a point is $-n^4/(3s^2)$. Since
$s\geq 2$,
\begin{equation}
J \geq -n^4/12
\label{eqn-2-3a}
\end{equation}
at any local minimum of this type.

We next consider the type of local minimum where it is necessary to add a
positive multiple of $w_1$ to satisfy the Kuhn-Tucker conditions. At such
a local minimum $n_1 = \beta n$ and $n_1 > n_2\geq \cdots \geq n_h\geq 0$.
Suppose $n_h=0$. Then the first entry of $DJ$ is strictly negative, some other
entry is strictly positive, and the last entry is $0$. We cannot make all those
three entries zero by adding a real multiple of $u$, a positive multiple of $w_1$,
and a positive multiple of $v_h$ to $DJ$. Thus $n_h > 0$.  Next suppose
that the $a$th entry of $DJ$ is not equal to the $b$th entry of $DJ$ for
some $a,b>1$. It is impossible to make the $1$st, $a$th, and $b$th entries of
$DJ$ zero by adding a multiple of $u$ and a positive multiple of $w_1$. Therefore,
all entries of $DJ$ except the first must be equal. The expression for
$\partial J/\partial n_a$ given above is quadratic in $n_a$. Thus we may conclude
that at any local minimum of this type $n_1=\beta n$ and $n_2,\ldots,n_h$
can take on at most two different values. Although the argument assumed
$h\geq 3$, the conclusion holds when $h=2$ as well. When $h=2$
and a positive multiple of $w_1$ is added to DJ to satisfy
the Kuhn-Tucker conditions, we must have $n_1 = \beta n$
and $n_2 = (1-\beta)n$.

We now consider the value of $J$ assuming that $n_1 = \beta n$, that
$x$ of the $n_a$s
equal $n_x$, that $y$ of the $n_a$s equal $n_y$, and that $xn_x+yn_y = n(1-\beta)$.
We also assume that $x$ is a positive integer, that $y$ is a non-negative integer, that $x\geq y$, and of course that $n_x$ and $n_y$ are non-negative. Then
\[J = (\beta^4n^4-4\beta^3 n^4/3)+(xn_x^2+yn_y^2)^2 +2\beta^2 n^2(xn_x^2+yn_y^2)
-(4n/3)(xn_x^3+yn_y^3),\]
which we will think of as a sum of four terms. If follows from elementary inequalities
that the minimum of $xn_x^2+yn_y^2$ under the given constraints is
$n^2(1-\beta)^2/(x+y)$, and that the minimum of $-(4n/3)(xn_x^3+yn_y^3)$
occurs when $n_x = n(1-\beta)$, $x=1$, and $n_y=0$. We can minimize each of
the four terms of $J$ separately to obtain
\begin{equation}
J \geq \beta^4n^4-4\beta^3 n^4/3-4(1-\beta)^3n^4/3.
\label{eqn-2-3}
\end{equation}
The value of $J$ at any local minimum of the type discussed in the previous paragraph
must either equal or exceed the lower bound in \eqref{eqn-2-3}.

So far, we have proved that the value of $J$ at a local minimum satisfies
the lower bound given by either \eqref{eqn-2-3a} or
\eqref{eqn-2-3}, depending  upon the type of the local minimum.
For $\beta \in [1/2,1)$, $\beta^4-4\beta^3/3-4(1-\beta)^3/3 < -1/12$
by an elementary argument. Therefore the lower bound for $J$ given by
\eqref{eqn-2-3} holds at all local minima and the lower bound for
$J+n^4/3$ stated in the lemma is proved.

\end{proof}

\subsection{Inversions of permutations of multisets}
Let $W = \sum_{i<j} X_{ij}$. Then $W=\mathop{\mathrm{inv}}(\pi)$. We
assume that $\pi$ is uniformly distributed
over permutations of the multiset $\{1^{n_1}, 2^{n_2},\ldots,h^{n_h}\}$.

\begin{lem}
Let $\mu = \E W$ and $\sigma^2 = \mathop{\mathrm{Var}}(W)$. Then
\begin{equation*}
\mu = \frac{n^2 - \sum_a n_a^2}{4}\quad \text{and}\quad
\sigma^2 = \binom{n}{3}\frac{n^5-n^2\sum_a n_a^3}{6n^2(n-1)^2(n-2)}+O(n^2).
\end{equation*}
\label{lem-2-6}
\end{lem}
\begin{proof}
Since $\mu=\binom{n}{2} p_1$, where $p_1 = \E X_{ij}$, and $p_1$ is given
by \eqref{eqn-2-2}, the expression for $\mu$ in the lemma must hold.

We first show that
\begin{equation}
\sigma^2 = \binom{n}{2}(p_1-p_1^2)+2\binom{n}{3}(p_2+p_3+p_4-3p_1^2)
+6\binom{n}{4}(p_5-p_1^2),
\label{eqn-2-4}
\end{equation}
where the $p_i$ are given by \eqref{eqn-2-2}.
If $\mathop{\mathrm{Var}}(W)$ with $W=\sum_{i<j}X_{ij}$ is written as a sum of variances and covariances of the $X_{ij}$,
there are $\binom{n}{2}$ variance terms each of which is equal to
$p_1-p_1^2$. There are $\binom{n}{3}$ terms of the form
$2\mathop{\mathrm{Covar}}(X_{ij_1}, X_{ij_2})$ with $i<j_1<j_2$ and each of those
is equal to $2(p_2-p_1^2)$. We can account for terms of the form
$2\mathop{\mathrm{Covar}}(X_{i_1j},X_{i_2j})$ with $i_1<i_2<j$ and of the form
$2\mathop{\mathrm{Covar}}(X_{ik}, X_{kj})$ with $i<k<j$ similarly. Thus far we have explained
the first two terms of \eqref{eqn-2-4}. All the other terms in the
expansion of $\mathop{\mathrm{Var}}(W)$ are of the form
$2\mathop{\mathrm{Covar}}(X_{i_ij_1},X_{i_2j_2})$ with $i_1<j_1$, $i_2<j_2$, and
$(i_1,j_1)<(i_2,j_2)$ in lexicographic order. The last term of  \eqref{eqn-2-4}
follows if we note that the number of such terms is $3\binom{n}{4}$.

The expression for $\sigma^2$ in the lemma is deduced using \eqref{eqn-2-2},
\eqref{eqn-2-4}, and the two inequalities $\sum_a n_a^2 < n^2$ and
$\sum_a n_a^3 < n^3$.
\end{proof}

We now turn to the construction of the size biased variable $W^\ast$ required
by Theorems \ref{thm-2-1} and \ref{thm-2-2}. Let $I$
be uniformly distributed
over all pairs $(i,j)$ with $1\leq i < j\leq n$
and let it be independent of $\pi$. Let $J=(a,b)$, for
$h\geq a > b\geq 1$, with probability $n_an_b/\sum_{c<d}n_cn_d$, and let
$J$ be independent of both $\pi$ and $I$. Now $\pi^\ast$ is constructed from
$\pi$, $I$, and $J$ as follows. If $I=(i,j)$ and $\pi(i)>\pi(j)$, then
$\pi^\ast=\pi$. If $I=(i,j)$, $\pi(i)\leq \pi(j)$ and $J=(a,b)$, $\pi^\ast$
is constructed in the following steps:
\begin{enumerate}
\item Let $i^\ast$ and $j^\ast$ be uniformly distributed over
the sets $\{i\bigl|\pi(i)=a\}$ and
$\{j\bigl|\pi(j)=b\}$, respectively. They must be independent
of each other and all other random variables.
\item If $\{i,j\}\cap\{i^\ast,j^\ast\} = \phi$, or $i=i^\ast,j\neq j^\ast$,
or $i\neq i^\ast,j=j^\ast$, exchange $\pi(i)$ with $\pi(i^\ast)$ and
$\pi(j)$ with $\pi(j^\ast)$ to get $\pi^\ast$.
\item If $i=j^\ast,j=i^\ast$, exchange $\pi(i)$ and $\pi(j)$ to get $\pi^\ast$.
\item If $i=j^\ast, j\neq i^\ast$, then
$\pi^\ast(i) = \pi(i^\ast)$, $\pi^\ast(j) = \pi(j^\ast) = \pi(i)$,
$\pi^\ast(i^\ast) = \pi(j)$, and $\pi^\ast(k) = \pi(k)$ if
$k \neq i, j, i^\ast$.

\item If $i\neq j^\ast, j=i^\ast$, then
$\pi^\ast(i) = \pi(i^\ast) = \pi(j)$, $\pi^\ast(j) = \pi(j^\ast)$,
$\pi^\ast(j^\ast) = \pi(i)$,  and $\pi^\ast(k) = \pi(k)$ for
$k \neq i, j, j^\ast$.
\end{enumerate}
Finally, $W^\ast = \sum_{i<j} X^\ast_{ij}$, where $X^\ast_{ij}$ is $1$ if
$\pi^\ast(i) > \pi^\ast(j)$ and $0$ otherwise.

We prove below that $W^\ast$ has the $W$-size biased distribution.
If $\pi$ were a  uniformly distributed permutation of
$\{1,2,\ldots,n\}$, it would be enough to exchange $\pi(i)$
and $\pi(j)$ if $\pi(i)<\pi(j)$ to get $\pi^\ast$. The resulting
$W^\ast$ would have the $W$-size biased distribution. However, since
we are dealing with a multiset here, $\pi(i)=\pi(j)$ is also
a possibility. The construction of $\pi^\ast$ given above is not
as simple mainly because this possibility has to be dealt with.

The following lemma is needed to prove that $W^\ast$ has the $W$-size biased
distribution. Subtraction and union of multisets have the obvious meanings
in the statement of the lemma. The lemma is stated without proof.
\begin{lem}
Let $\pi$ be a uniformly distributed permutation of the multiset
$\{1^{n_1}, 2^{n_2},\ldots,h^{n_h}\}$. If one $a$
out of $n_a$ possible choices is chosen uniformly
from $\pi$ and changed to  $b$, the resulting permutation is a uniformly
distributed permutation of the multiset $(\{1^{n_1}, 2^{n_2},\ldots,h^{n_h}\}
-\{a\})\cup\{b\}$.
Similarly, if one of $n_a$ $a$s and one of $n_b$ $b$s are picked uniformly
and independently from $\pi$ and changed to  $c$ and $d$, respectively, then
the resulting permutation is a uniformly distributed permutation of a possibly
new multiset.
\label{lem-2-7}
\end{lem}

\begin{lem}
The random variable $W^\ast$ has the $W$-size biased distribution.
\label{lem-2-8}
\end{lem}
\begin{proof}
By Lemma \ref{lem-2-3}, it is enough to show that
\(\P\bigl(\pi^\ast\in A \bigl|I=(i,j)\bigr) = \P\bigl(\pi\in A\bigl| \pi(i)>\pi(j)\bigr)\). Now
\begin{multline*}\P\bigl(\pi^\ast\in A \bigl|I=(i,j)\bigr)
 =
\P\bigl(\pi\in A\bigl|\pi(i)>\pi(j)\bigr)\P(\pi(i)>\pi(j))\\
+\P\bigl(\pi^\ast\in A\bigl|\pi(i)\leq \pi(j), I=(i,j)\bigr)\P(\pi(i)\leq \pi(j)).
\end{multline*}
The first term in the right hand side of the equation above is not
conditioned on $I$ because $\P\bigl(\pi^\ast\in A\bigl| \pi(i)>\pi(j),
I = (i, j)\bigr) = \P\bigl(\pi\in A \bigl| \pi(i) > \pi(j), I = (i,j)\bigr)$,
by the construction of $\pi^\ast$, and because $\pi$ is independent
of $I$.
Thus, if we can show $\P\bigl(\pi^\ast\in A\bigl|\pi(i)\leq \pi(j), I=(i,j)\bigr)
= \P\bigl(\pi\in A\bigl| \pi(i)>\pi(j)\bigr)$, the proof will be complete.

The proof is completed by the sequence of equalities below and the explanation
that follows them.
\begin{align*}
\P&\bigl(\pi^\ast\in A \bigl| \pi(i)\leq \pi(j), I=(i,j)\bigr)\\
=&\sum_{a>b}\P\bigl(\pi^\ast\in A\bigl| \pi(i)\leq\pi(j), I=(i,j), J=(a,b)\bigr)
\P\bigl(\pi(i)=a,\pi(j)=b\bigl| \pi(i)>\pi(j)\bigr)\\
=&\sum_{a>b}\P\bigl(\pi\in A\bigl| \pi(i)=a,\pi(j)=b, I=(i,j), J=(a,b)\bigr)
\P\bigl(\pi(i)=a,\pi(j)=b\bigl| \pi(i)>\pi(j)\bigr)\\
=&\P\bigl(\pi\in A\bigl| \pi(i)>\pi(j)\bigr).
\end{align*}
The first equality is true because $J$ is independent of $\pi$ and $I$,
and $\P\bigl(J=(a,b)\bigr) = P\bigl(\pi(i)=a,\pi(j)=b\bigl|\pi(i)>\pi(j)\bigr)$.
The construction of $\pi^\ast$ from $\pi, I, J$ and Lemma \ref{lem-2-7} imply
the second equality. More specifically, we note that Lemma \ref{lem-2-7}
implies that given $\pi(i)\leq \pi(j)$, $I=(i,j)$ and $J=(a,b)$, the arrangement
$\pi^\ast(1), \pi^\ast(2), \ldots, \pi^\ast(n)$ with the $i$th and the $j$th
numbers {\it struck out} is  a uniformly distributed  permutation of the
multiset $\{1^{n_1},2^{n_2},\ldots,h^{n_h}\}-\{a,b\}$.
\end{proof}

We now focus on finding a useful upper bound for
 $\mathop{\mathrm{Var}}\bigl(\E(W^\ast-W\bigl| \pi)\bigr)$. Given a sequence of
numbers $s_1, s_2,\ldots,s_p$, we  throw $q$ and $r$ into the same set
if and only if $s_q=s_r$. In this way, we get a partition of $\{1,2,\ldots,p\}$ into
sets, and we may arrange the sets of the partition so that the values of $s_q$
for $q$ in the set increase.
We refer to such an ordered partition of $\{1,2,\ldots,p\}$ as the {\it relative
order} of $s_1,s_2,\ldots,s_p$. For our purpose, it is sufficient to note that
the number of possible relative orders is bounded by $2^p p!$.

\begin{lem}
Let $P_1$ be the probability that $\pi(1),\pi(2), \ldots,\pi(p)$ occur
in a certain relative order when $\pi$ is a uniformly distributed permutation
of $\{1^{n_1}, 2^{n_2},\ldots, h^{n_h}\}$, and let that probability be $P_2$
if $\pi$ is a uniformly distributed permutation of the multiset
$\{1^{n'_1},2^{n'_2},\ldots, h^{n'_h}\}$. Assume that $n_a\geq n'_a$,
$\sum_a (n_a-n'_a)\leq 5$. We allow $n'_a=0$. If $p\leq 5$ then
\(\Abs{P_1-P_2} \leq C/n\)
for some constant $C$.
\label{lem-2-9}
\end{lem}
\begin{proof}
The proof is obtained by writing down formulas for $P_1$ and $P_2$. We show
the proof for the relative order $\pi(1)<\pi(2)<\cdots<\pi(p)$.

Let $n'=\sum_an'_a$. The probability $P_1$ is given by
\begin{equation}
\frac{\sum n_{a_1}n_{a_2}\ldots n_{a_p}}{n(n-1)\ldots(n-p+1)},
\label{eqn-2-5}\
\end{equation}
where the sum is taken over $1\leq a_1<a_2<\cdots<a_p\leq h$. The formula
for $P_2$ is obtained by adding a prime to all the $n$s in \eqref{eqn-2-5}.
Now
\[ P_1 - P_2 =
\frac{\sum n_{a_1}n_{a_2}\ldots n_{a_p}- n'_{a_1}n'_{a_2}\ldots n'_{a_p}}
{n(n-1)\ldots(n-p+1)} -
P_2 \Biggl(1 -\frac{n'(n'-1)\ldots(n'-p+1)}{n(n-1)\ldots(n-p+1)}\Biggr),\]
$0\leq n-n'\leq 5$, and
\[n_{a_1}n_{a_2}\ldots n_{a_p}- n'_{a_1}n'_{a_2}\ldots n'_{a_p}
\leq n_{a_1}n_{a_2}\ldots n_{a_p}((n_{a_1}-n'_{a_1})/n_{a_1}+\cdots+
(n_{a_p}-n'_{a_p})/n_{a_p}),\]
together imply
$\abs{P_1-P_2} \leq C/n$.
\end{proof}

\begin{lem}
Let $f\bigl(\pi(1),\pi(2),\ldots,\pi(p)\bigr)$ and $g\bigl(\pi(p+1),\pi(p+2),\ldots,\pi(p+q)\bigr)$ be functions that depend
only upon the relative order of their argument lists. Assume that $\abs{f}$, $\abs{g}$,
$p$, and $q$ are all upper bounded by  $5$. If $\pi$ is
a uniformly distributed permutation of the multiset
$\{1^{n_1},2^{n_2},\ldots,h^{n_h}\}$, then
\[\Bigl|\mathop{\mathrm{Covar}}\bigl(f\bigl(\pi(1),\pi(2),\ldots,\pi(p)\bigr),
g\bigl(\pi(p+1),\pi(p+2),\ldots,\pi(p+q)\bigr)\bigr)\Bigr| \leq C/n\]
for some constant $C$.
\label{lem-2-10}
\end{lem}
\begin{proof}
It is enough to consider $f$ and $g$ to be indicator functions that are $1$
for a certain relative order of their argument lists and $0$ for all other
relative orders. All other $f$ and $g$ are linear combinations of a constant
number of indicator functions with coefficients that are bounded by constants.

We state the proof assuming $f$ and $g$ are $1$ if their arguments are in
strictly increasing order and $0$ otherwise. Let $\P(f=1)=P_1$ and
$\P(g=1)=P_2$. Then
\begin{multline*}
\P(fg = 1) = \sum
\P\bigl(\pi(1)<\pi(2)<\cdots<\pi(p)\bigl|\pi(p+1)=a_1,\ldots,\pi(p+q)=a_q\bigr)\\
\P\bigl(\pi(p+1)=a_1,\ldots,\pi(p+q)=a_q\bigr),
\end{multline*}
where the sum is over $1\leq a_1<a_2<\cdots<a_q\leq h$.
By the previous Lemma \ref{lem-2-9}, each conditional probability in the sum above
is $P_1 + O(1/n)$. Therefore, $\P(fg=1)=P_1P_2 + O(1/n)$ and
$\mathop{\mathrm{Covar}}(f,g)=O(1/n)$.
\end{proof}

\begin{lem}
\[\mathop{\mathrm{Var}}\bigl(\E\bigl(W^\ast-W\bigl|\pi\bigr)\bigr) \leq \frac{Cn^5}{(n^2-\sum_an_a^2)^2}\]
for some constant $C$.
\label{lem-2-11}
\end{lem}
\begin{proof}
If $\pi(i) > \pi(j)$, $\E\bigl(W^\ast-W\bigl|\pi, I=(i,j)\bigr) = 0$.
If $\pi(i)\leq \pi(j)$,
\[ \E\bigl(W^\ast-W\bigl|\pi, I=(i,j)\bigr) =
\frac{1}{\sum_{a>b}n_an_b} \sum_{i^\ast,j^\ast}\sum_{l=1}^n \psi_\pi(i,j,i^\ast,j^\ast,l),\]
where $(i^\ast,j^\ast)$ takes all $\sum_{a>b}n_an_b$ possible values with
$\pi(i^\ast) > \pi(j^\ast)$ and $\psi_\pi(i,j,i^\ast,j^\ast,l)$ is the change
in the number of inversions between position $l$ and positions $i,j,i^\ast,j^\ast$
when $\pi(i)$, $\pi(j)$, $\pi(i^\ast)$, $\pi(j^\ast)$ are exchanged to construct
$\pi^\ast$. Note that $\abs{\psi_\pi} \leq 4$. We now have
\begin{equation}
\E\bigl(W^\ast-W\bigl|\pi\bigr)
= \frac{1}{\binom{n}{2}\sum_{a>b}n_an_b}\sum_{i,j}\sum_{i^\ast,j^\ast}\sum_{l=1}^n
\psi_\pi(i,j,i^\ast,j^\ast, l),
\label{eqn-2-6}
\end{equation}
where $i,j$ take all values satisfying $1\leq i < j\leq h$ and $\pi(i)\leq \pi(j)$,
and where $i^\ast,j^\ast$ take values as already indicated.

We use \eqref{eqn-2-6} to write
$\mathop{\mathrm{Var}}\bigl(\E\bigl(W^\ast-W\bigl|\pi\bigr)\bigr)$ as a sum of variance and
covariance terms. The number of variance terms is bounded by $n^5$. The number
of covariance terms
\begin{equation}
\mathop{\mathrm{Covar}}\bigl(\psi_\pi(i_1,j_1,i_1^\ast,j_1^\ast,l_1), \psi_\pi(i_2,j_2,i_2^\ast,j_2^\ast,l_2)\bigr)
\label{eqn-2-7}
\end{equation}
with $\{i_1,j_1,i_1^\ast,j_1^\ast,l_1\}\cap\{i_2,j_2,i_2^\ast,j_2^\ast,l_2\}
\neq \phi$ is fewer than $25n^9$. Since $\abs{\psi_\pi} \leq 4$, the contribution
of the variance terms and covariance terms with the property just described
is bounded by $16(n^5+25 n^9)/\bigl(\binom{n}{2}\frac{1}{2}(n^2-\sum_an_a^2)\bigr)^2$. We have used $\sum_{a>b} n_a n_b = \frac{1}{2}(n^2-\sum_a n_a^2)$
to obtain this bound.

Covariance terms of the form \eqref{eqn-2-7} with
\(\{i_1,j_1,i_1^\ast,j_1^\ast,l_1\}\cap\{i_2,j_2,i_2^\ast,j_2^\ast,l_2\}
= \phi\)
remain to be considered. The number of such terms is fewer than $n^{10}$.
Lemma \ref{lem-2-10} can be applied to argue that such covariances are
$O(1/n)$ as we may use the fact that $\pi$ is uniformly distributed to
assume $i_1,j_1,i_1^\ast,j_1^\ast,l_1=1,2,3,4,5$ and
$i_2,j_2,i_2^\ast,j_2^\ast,l_2=6,7,8,9,10$ with no loss of generality.
The proof can now be easily completed.
\end{proof}

\begin{thm} Let $\pi$ be a uniformly distributed permutation of the multiset
$\{1^{n_1}, 2^{n_2},\ldots, h^{n_h}\}$, where $n_a\in Z^+$ for $1\leq a \leq h$.
Assume that $\alpha\in (0,1)$ is fixed and that $n_a\leq \alpha n$ for
$1\leq a \leq h$.
Let $\beta = \max(1/2,\alpha)$.
Let $h:R\rightarrow R$ be a bounded continuous function with
bounded piecewise continuous derivative $Dh$. Then for $n > n_0(\beta)$,
\[
\Abs{\E h\Bigl(\frac{\mathop{\mathrm{inv}}(\pi)-\mu}{\sigma}\Bigr) - \Phi h} \leq
C\Biggl(\frac{\norm{h}}{\beta(1-\beta)(\beta(1-\beta)n^{1/2}-C_1 n^{-1/2})}
+\frac{\norm{Dh}}{(\beta(1-\beta)n^{1/3}-C_2n^{-2/3})^{3/2}}\Biggr)
\]
where $C$, $C_1$, and $C_2$ are some positive constants, $\Phi h$ is the expectation of $h$ with respect
to the standard normal distribution, and $\mu$ and $\sigma^2$ are the mean
and variance of $\mathop{\mathrm{inv}}(\pi)$, respectively.

If $C(\beta)$ is allowed to depend upon $\beta$, we may assert
\[\Bigl|\P\Biggl(\frac{\mathop{\mathrm{inv}}(\pi)-\mu}{\sigma} \leq x\Biggr) - \Phi(x)\Bigr|
\leq C(\beta)/\sqrt{n}\]
for some positive constant $C(\beta)$.
\label{thm-2-12}
\end{thm}
\begin{proof}
Let $W=\mathop{\mathrm{inv}}(\pi)$. By Lemmas \ref{lem-2-4} and \ref{lem-2-6},
$\sigma^2 \geq (\beta(1-\beta)/12)n^3+O(n^2)$ and
$\mu\leq n^2/4$. By Lemmas \ref{lem-2-4} and \ref{lem-2-11},
$\mathop{\mathrm{Var}}\bigl(\E\bigl(W^\ast-W\bigl|\pi\bigr)\bigr)\leq Cn/(\beta(1-\beta))^2$
for some constant $C$.
By construction of the size biased variable $W^\ast$, $\Abs{W^\ast-W}
\leq 4n$, and therefore $\E\bigl(W^\ast-W\bigr)^2\leq 16n^2$. If we note
that $\mathop{\mathrm{Var}}\bigl(\E\bigl(W^\ast-W\bigl|W\bigr)\bigr)\leq \mathop{\mathrm{Var}}\bigl(\E\bigl(W^\ast-W\bigl|\pi\bigr)\bigr)$, Theorem \ref{thm-2-1}
can be applied to prove the first part of this theorem.

 The second part
is proved using Theorem \ref{thm-2-2}. By construction of $W^\ast$,
$\abs{W^\ast - W} \leq 4n$. Therefore we can take $B=4n$. The
inequality $B \leq \sigma^{3/2}/\sqrt{6\mu}$ must  hold
for large enough $n$  by bounds
for $\sigma $ and $\mu$ given above.
\end{proof}

\subsection{Descents of permutations of multisets}
Let $W=X_{12}+X_{23}+\cdots+X_{n-1,n}$. Then $W=\mathop{\mathrm{des}}(\pi)$, with $\pi$ uniformly
distributed over permutations of the multiset $\{1^{n_1},2^{n_2},\ldots,h^{n_h}\}$.

\begin{lem}
Let $\mu = \E W$ and $\sigma^2=\mathop{\mathrm{Var}}(W)$. Then
\begin{equation*}
\mu = \frac{n^2-\sum_a n_a^2}{2n}\quad \text{and}\quad
\sigma^2 = \frac{n^4/3+\Bigl(\sum_a n_a^2\Bigr)^2-(4n/3)\sum_a n_a^3}{4n(n-1)^2}
+ O(1).
\end{equation*}
\label{lem-2-13}
\end{lem}
\begin{proof}
Since $\mu=(n-1)p_1$, where $p_1 = \E X_{ij}$, and $p_1$ is given
by \eqref{eqn-2-2}, the expression for $\mu$ in the lemma must hold.

We first show that
\begin{equation}
\sigma^2 = (n-1)(p_1-p_1^2)+2(n-2)(p_4-p_1^2)+(n-2)(n-3)(p_5-p_1^2),
\label{eqn-2-8}
\end{equation}
where the $p_i$ are given by \eqref{eqn-2-2}. If $\mathop{\mathrm{Var}}(W)$, with
$W=X_{12}+X_{23}+\cdots+X_{n-1,n}$, is written as the sum
of variances and covariances of the $X_{i,i+1}$,
there are $(n-1)$ variance terms, each equal to $p_1-p_1^2$. There
are $(n-2)$ covariance terms of the form $\mathop{\mathrm{Covar}}\bigl(X_{i,i+1},X_{i+1,i+2}\bigr)$
each equal to $p_4-p_1^2$. The remaining covariance terms are all equal to
$p_5-p_1^2$.

The expression for $\sigma^2$ in the lemma is deduced using \eqref{eqn-2-2},
\eqref{eqn-2-8}, and the two inequalities $\sum_a n_a^2 < n^2$ and
$\sum_a n_a^3 < n^3$.
\end{proof}

The construction of the size biased variable $W^\ast$ is the same as the construction
for inversions given immediately after Lemma \ref{lem-2-6} with the following
differences. The random variable $I$ must be equal to one of $(1,2),(2,3),\ldots,
(n-1,n)$ with equal probability. In the construction of $\pi^\ast$, the symbol
$j$ must be replaced everywhere by $i+1$. Finally,
$W^\ast = X^\ast_{12}+X^\ast_{23}+\cdots+X^\ast_{n,n-1}$, where
$X^\ast_{ij}$ is $1$ if $\pi^\ast(i)>\pi^\ast(j)$ and $0$ otherwise.

\begin{lem}
The random variable $W^\ast$ has the $W$-size biased distribution.
\label{lem-2-14}
\end{lem}
\begin{proof}
Similar to the proof of Lemma \ref{lem-2-8}.
\end{proof}

\begin{lem}
\[\mathop{\mathrm{Var}}\bigl(\E\bigl(W^\ast-W\bigl|\pi\bigr)\bigr)\leq
\frac{Cn^5}{n^2(n^2-\sum_a n_a^2)^2}\]
for some constant $C$.
\label{lem-2-15}
\end{lem}
\begin{proof}
By arguing as in the proof of Lemma \ref{lem-2-11}, we get
\begin{equation}
\E\bigl(W^\ast-W\bigl|\pi\bigr) = \frac{2}{n(n^2-\sum_a n_a^2)} \sum_i
\sum_{i^\ast, j^\ast} \psi_\pi(i,i^\ast, j^\ast).
\label{eqn-2-9}
\end{equation}
In \eqref{eqn-2-9}, $i$ takes all values such that $\pi(i)\leq \pi(i+1)$, $(i^\ast,j^\ast)$
takes all values such that $\pi(i^\ast) > \pi(j^\ast)$, and
$\psi_\pi(i,i^\ast, j^\ast) = \mathop{\mathrm{des}}(\pi^\ast)-\mathop{\mathrm{des}}(\pi)$, where $\pi^\ast$ is
constructed by exchanging $\pi(i), \pi(i+1), \pi(i^\ast), \pi(j^\ast)$ as
described. Note that $\abs{\psi_\pi} \leq 7$.

We use \eqref{eqn-2-9}
to write $\mathop{\mathrm{Var}}\bigl(\E\bigl(W^\ast-W\bigl|\pi\bigr)\bigr)$ as the sum of
variance and covariance terms. There are $O(n^3)$ variance terms of the
$\mathop{\mathrm{Var}}(\psi_\pi)$. The number of terms of the form
\begin{equation}
\mathop{\mathrm{Covar}}\bigl(\psi_\pi(i_1,i^\ast_1,j^\ast_1),\psi_\pi(i_2,i^\ast_2,j^\ast_2)\bigr),
\label{eqn-2-10}
\end{equation}
where one of the numbers $\{i_1,i^\ast_1,j^\ast_1\}$ differs from one of the
numbers $\{i_2,i^\ast_2,j^\ast_2\}$ by $3$ or less in magnitude is
$O(n^5)$. The magnitude of such covariance terms and of the variance terms
is bounded by $49$.  The number of covariance terms of the form \eqref{eqn-2-10}
where none of the numbers $\{i_1,i^\ast_1,j^\ast_1\}$ differs from any one of the
numbers $\{i_2,i^\ast_2,j^\ast_2\}$ by $3$ or less in magnitude is
$O(n^6)$. By Lemma \ref{lem-2-10}, the magnitude of such covariance terms is
$O(1/n)$. The proof is now easily completed.
\end{proof}

It is worth noting again that
$\beta^4-4\beta^2+4\beta-1 = (1-\beta)^2(\beta^2+2\beta-1)>0$
for $\beta \in [1/2,1)$.

\begin{thm} Let $\pi$ be a uniformly distributed permutation of the multiset
$\{1^{n_1}, 2^{n_2},\ldots, h^{n_h}\}$, where $n_a\in Z^+$ for $1\leq a \leq h$.
Assume that $\alpha\in(0,1)$ is fixed and that $n_a\leq \alpha n$ for
$1\leq a \leq h$.
Let $\beta = \max(1/2,\alpha)$.
Let $h:R\rightarrow R$ be a bounded continuous function with
bounded piecewise continuous derivative $Dh$. Then for $n > n_0(\beta)$,
\begin{multline*}
\Abs{\E h\Bigl(\frac{\mathop{\mathrm{des}}(\pi)-\mu}{\sigma}\Bigr) - \Phi h} \leq
C\Biggl(\frac{\norm{h}}
{\beta(1-\beta)\sqrt{n}(\beta^4-4\beta^2+4\beta-1-C_1n^{-1})}\\
+\frac{\norm{Dh}}{((\beta^4-4\beta^2+4\beta-1)n^{1/3}-C_2n^{-2/3})^{3/2}}\Biggr)
\end{multline*}
where $C$, $C_1$, and $C_2$ are some positive constants, $\Phi h$ is the expectation of $h$ with respect
to the standard normal distribution, and $\mu$ and $\sigma^2$ are the mean
and variance of $\mathop{\mathrm{des}}(\pi)$, respectively.

If $C(\beta)$ is allowed to depend upon $\beta$, we may assert
\[\Bigl|\P\Biggl(\frac{\mathop{\mathrm{des}}(\pi)-\mu}{\sigma} \leq x\Biggr) - \Phi(x)\Bigr|
\leq C(\beta)/\sqrt{n}\]
for some positive constant $C(\beta)$.
\label{thm-2-16}
\end{thm}
\begin{proof}
Let $W=\mathop{\mathrm{des}}(\pi)$. By Lemmas \ref{lem-2-4}, \ref{lem-2-5} and
\ref{lem-2-13}
$\sigma^2 \geq ((\beta^4-4\beta^2+4\beta-1)/4)n+O(1)$ and
$\mu\leq n/2$. By Lemmas \ref{lem-2-4} and \ref{lem-2-15},
$\mathop{\mathrm{Var}}\bigl(\E\bigl(W^\ast-W\bigl|\pi\bigr)\bigr)\leq
C/\bigl(n\beta^2(1-\beta)^2\bigr)$ for some constant $C$.
By construction of the size biased variable $W^\ast$, $\Abs{W^\ast-W}
\leq 7$, and therefore $\E\bigl(W^\ast-W\bigr)^2\leq 49$. If we note
that $\mathop{\mathrm{Var}}\bigl(\E\bigl(W^\ast-W\bigl|W\bigr)\bigr)\leq \mathop{\mathrm{Var}}\bigl(\E\bigl(W^\ast-W\bigl|\pi\bigr)\bigr)$, Theorem \ref{thm-2-1}
can be applied to prove the first part of this theorem.

 The second part
is proved using Theorem \ref{thm-2-2}. By construction of $W^\ast$,
$\abs{W^\ast - W} \leq 8$. Therefore we can take $B=8$. The
inequality $B \leq \sigma^{3/2}/\sqrt{6\mu}$ must  hold
for large enough $n$  by bounds
for $\sigma $ and $\mu$ given above.

\end{proof}

\section{Descents and inversions of the human genome}

The human genome consists of 24 chromosomes, each of which is a sequence of bases
labeled A, C, G, or T. The $19$th chromosome has the following counts for
the four bases (see \cite{IHGC}):
\[n_A = 14383026\quad n_C=13473774\quad n_G=13506612\quad n_T=14422243.\]
The version of the human genome reported in \cite{IHGC} has $341$ gaps. The
$19$th chromosome has only three gaps in the middle. We ignored these gaps when counting the number of inversions and descents.

\begin{table}
\begin{center}
\begin{tabular}{|c||r|r|r|r|}\hline
{}& A & C & G & T \\ \hline\hline
A  & 4229414 & 2833985 & 4154304 & 3165323\\ \hline
C  & 4221129 & 4044958 & 1057112 & 4150574\\ \hline
G  & 3423863 & 3180474 & 4056078 & 2846197\\ \hline
T  & 2508620 & 3414357 & 4239118 & 4260148\\ \hline
\end{tabular}
\end{center}

\begin{center}
\begin{tabular}{|c||r|r|r|r|}\hline
{} & A & C & G & T \\\hline\hline
A & 103435711266825  & 94175991781325  & 94404662110136  & 103982892949612\\ \hline
C &  99617649978799  & 90771286164651  & 90984870248490  & 100143945584446\\ \hline
G &  99861289457776  & 91000167345198  & 91214277105966  & 100388853252680\\ \hline
T & 103452603097706  & 94178097170636  & 94406787118036  & 104000539364403\\ \hline
\end{tabular}
\end{center}
\caption[xyz]{The first table above reports the number of occurrences
of $\pi(i)=x$ and $\pi(i+1)=y$.
The second table reports the number of occurrences of $\pi(i)=x$
and $\pi(j)=y$, with $i<j$.
The permutation $\pi$ corresponds to chromosome $19$, and $x$ and $y$
can be A, C, G, or T.}
\label{tbl-3-1}
\end{table}

\begin{table}
\begin{center}
\begin{tabular}{||c|r|r||c|r|r||}\hline
Order & $(\mathop{\mathrm{des}}-\mu_d)/\sigma_d$& $(\mathop{\mathrm{inv}}-\mu_i)/\sigma_i$ &
Order & $(\mathop{\mathrm{des}}-\mu_d)/\sigma_d$& $(\mathop{\mathrm{inv}}-\mu_i)/\sigma_i$ \\\hline\hline
A,C,G,T  &   $36.13$  &      $-11.64$ &
C,A,G,T  & $-628.47$   &     $-92.58$ \\\hline
G,A,C,T  & $-631.23$   &     $-93.03$&
A,G,C,T  & $-981.20$  &      $-11.86$\\\hline
C,G,A,T  & $-278.50$ & $-173.74$ &
G,C,A,T  & $-1295.83$  &     $-173.96$\\ \hline
T,C,A,G  &  $-628.47$  &       $93.03$&
C,T,A,G  &  $-981.20$  &        $4.29$\\\hline
A,T,C,G  &  $-278.50$  &      $166.08$&
T,A,C,G  &  $  36.13$  &      $173.96$\\\hline
C,A,T,G  & $-1295.83$  &       $-3.60$&
A,C,T,G  & $-631.23$  &       $77.34$\\\hline
A,G,T,C  & $-628.47$  &       $76.87$&
G,A,T,C  &  $-278.50$  &       $-4.29$\\\hline
T,A,G,C  &  $-981.20$  &      $173.74$&
A,T,G,C  & $-1295.83$  &      $165.85$\\\hline
G,T,A,C  &    $36.13$  &        $3.60$&
T,G,A,C  &  $-631.23$  &       $92.58$\\ \hline
T,G,C,A  & $-1295.83$  &       $11.64$&
G,T,C,A  &  $-628.47$  &      $-77.34$\\\hline
C,T,G,A  & $-631.23$   &     $-76.87$&
T,C,G,A  &  $-278.50$  &       $11.86$\\\hline
G,C,T,A  &  $-981.20$  &     $-166.08$&
C,G,T,A  &    $36.13$  &     $-165.85$\\ \hline
\end{tabular}
\end{center}
\caption[xyz]{This table
reports the normalized
number of descents and inversions of the
$19$th chromosome, when the orders shown in the first and the fourth columns
are considered increasing.}
\label{tbl-3-2}
\end{table}

From Lemmas \ref{lem-2-6} and \ref{lem-2-13}, and their proofs, we find
the expected number of descents and inversions to be
$\mu_d = 2.0912146861\times 10^{7}$ and $\mu_i = 5.8329890505\times 10^{14}$,
respectively. The standard deviations are
$\sigma_d = 2.0871959423\times 10^3$ and $\sigma_i = 6.7231321079\times 10^{10}$.
Data about the $19$th chromosome reported in Table \ref{tbl-3-1}
can be used to
calculate the number of descents and inversions for any ordering of
A, C, G, and T. By Theorems \ref{thm-2-12} and \ref{thm-2-16}, the number of descents
and inversions must have a distribution that is close to the normal
distribution if $\pi$ is
a uniformly distributed permutation of the bases in the $19$th chromosome. The
number of descents and inversions in the $19$th chromosome itself is reported
in Table \ref{tbl-3-2}
for all possible orderings of  $A$, $C$, $G$, and $T$
and with suitable normalization. From each line of this table, we may infer that the null hypothesis
stating the $19$th chromosome to be a random permutation of its bases is very
unlikely to hold.

Estimations of the entropy of DNA sequences can be found in
\cite{GNC1} and \cite{Mantegna1}. Those estimates too imply that DNA
sequences are far from random. We note that Table \ref{tbl-3-2}
assumes the number of $A$s, $C$s, $G$s, and $T$s to be given and
computes a statistic to test if their arrangement in a sequence is
random.  This is a different notion of randomness from that of
entropy. For instance, it is possible for a sequence to have $A$ for
$90\%$ of its letters which would mean that the sequence can be
significantly compressed. Yet the arrangement of the letters could be
generated randomly.

In the bounds given by Theorems \ref{thm-2-12} and \ref{thm-2-16} the
constants $C(\beta)$ are not determined explicitly. In this example
$n$ is greater than $5 \times 10^7$. For the large departures from the
mean that are seen in Table \ref{tbl-3-2}, it is reasonable to assume
that the probabilities of finding such departures, if the sequence
were a uniformly distributed permutation, are less than $.001$.  Such
a bound is implied in most cases by Chebyshev's inequality.  Yet even
this is surely an overestimate.  For uniformly distributed $\pi$, the
probabilities that $\mathop{\mathrm{des}}(\pi)$ and $\mathop{\mathrm{inv}}(\pi)$ depart from their means
by a certain amount appear to fall off at least as fast as the bell
curve does away from zero. Therefore, for large deviations from the
mean, the bounds given by Theorems
\ref{thm-2-12} and \ref{thm-2-16} are not accurate and better bounds
would be desirable.

\section{Acknowledgments}

The authors thank D. Burns and J. Fulman for helpful discussions, and
the referees for their work.

Probability (math.PR); Combinatorics (math.CO)


Hensel's lemma for general continuous functions

Abstract: In the present paper, we generalize the well-known Hensel's lifting lemma to any continuous function $f : \mathbb{Z}_p\rightarrow \mathbb{Z}_p$. This answers a question posed by Axelsson and Khrennikov (2016) who showed the validity of Hensel's lemma for $1$- and for $p^\alpha$-Lipschitz functions. For the statement and the proof, we introduce a suitable generalization of the original van der Put series. We use the concept of approximability of continuous functions to give numerical examples.

\section{Introduction}
Denote by \(\mathbb{N}\) (resp. \(\mathbb{Z}^{+}\)) the set of nonnegative integers (resp. positive integers). Let \(p\) be a prime number and \(\mathbb{Z}_p\) the ring of \(p\)-adic integers.
We denote \(v_p(u)\) (resp. \(|u|_p\)) the \(p\)-adic order (resp. the \(p\)-adic absolute value) of
\(u\in\mathbb{Z}_p\) normalized with \(v_p(p)=1\) (resp. \(|p|_p=p^{-1}\)).
We first recall Hensel's lifting lemma. Let \(Q(X)\in\mathbb{Z}_p[X]\backslash\mathbb{Z}_p\)
and \(u\in\mathbb{Z}_p\). Assume that
\[v_p(Q(u))>2v_p(Q'(u)).\]
Then there exists a unique \(\xi\in\mathbb{Z}_p\) satisfying
\[v_p(\xi-u)>v_p(Q'(u))\]
and
\[Q(u)=0.\]
Axelsson and Khrennikov \cite{axe} generalized Hensel's lemma to \(1\)-Lipschitz functions, namely to functions
\(f:\mathbb{Z}_p\to\mathbb{Z}_p\) which satisfy
\[|f(x)-f(y)|_p\leq |x-y|_p\]
for any \(x,y\in\mathbb{Z}_p\) (from this, they derived also a generalization for \(p^\alpha\)-Lipschitz functions, $\alpha\geq 1$). For the statement and the proof of their generalization, they used van der Put series applied to this class of functions. Van der Put series date back to the work of M. van der Put \cite{vdP1, vdP2} and have shown to be very fruitful in $p$-adic analysis, dynamical systems and ergodic theory (see \cite{Sch}) as well as in various applications in cryptography, computer science and numerical analysis (see \cite{AKbook} for a detailed account on the various applications). For the application to dynamical systems it is natural to investigate the minimal conditions on the functions that allow such series expansions.\par

Axelsson and Khrennikov \cite[p.224, Remark 2.5]{axe} asked for a generalization of Hensel's lemma to any continuous function \(f:\mathbb{Z}_p\to\mathbb{Z}_p\) which would lead to an extension to their result. In this article, we provide such a generalization of Hensel's lemma to any continuous function, introducing the notion of generalized
van der Put series and approximability of continuous functions.
We consider the existence of the zeros of continuous functions and discuss uniqueness under certain conditions. \par
We first recall Theorem 2.4 of \cite{axe} (notation and statements are slightly modified for convenience to generalization; cf. \cite{ana}).
For a positive integer \(m\), we denote its base-\(p\) expansion
by
\begin{align}
m=m_0+m_1p+\cdots+m_{k}p^k,
\label{eqn:1-1}
\end{align}
where \(k=k(m)=\lfloor \log_p m\rfloor\) and \(\log_p m=\log m/\log p\).
In other words, \(k\) is a unique positive integer with
\begin{align}
p^k\leq m<p^{1+k},
\label{eqn:1-2}
\end{align}
and \(m_0,m_1,\ldots,m_k\in\{0,1,\ldots,p-1\}\), \(m_k\ne 0\). For convenience, if \(m=0\), put
\begin{align}
k=k(0)=\lfloor \log_p 0\rfloor:=0.
\label{eqn:1-3}
\end{align}
Set
\[
\chi(m,x)=
\begin{cases}
1 & \mbox{if }|x-m|_p\leq p^{-1-k},\\
0 & \mbox{ otherwise}
\end{cases}
\]
for any \(x\in\mathbb{Z}_p\).
Let \(f:\mathbb{Z}_p\to\mathbb{Z}_p\) be any continuous function.
Then there exists a unique sequence \(B(f;m)\) (\(m=0,1,\ldots\)) such that
\begin{align}
f(x)=\sum_{m=0}^{\infty} B(f;m) \chi(m;x)
\label{eqn:1-4}
\end{align}
for any \(x\in\mathbb{Z}_p\), where (\ref{eqn:1-4}) is called the van der Put series of \(f\).
Moreover, \(B(f;m)\) satisfies
\[
B(f;m)=\begin{cases}
f(m) & \mbox{if }m< p, \\
f(m)-f(m-m_k p^k) & \mbox{otherwise}.
\end{cases}
\]
Anashin, Khrennikov and Yurova \cite[Theorem 5]{ana} showed that \(f\) is \(1\)-Lipschitz if and only if
\begin{align}
v_p(B(f;m))\geq \lfloor \log_p m\rfloor
\label{eqn:1-5}
\end{align}
for any nonnegative integers \(m\).
Thus, we see if \(f\) is \(1\)-Lipschitz, then
\[b(f;m):= p^{-\lfloor \log_p m\rfloor} B(f;m)\in\mathbb{Z}_p.\]

We are now ready to state the main result of {\cite{axe}}. (The condition $m\geq R$, appearing in the second assumption in {\cite[Theorem 2.4]{axe}}, is a typo and has to be omitted.)
\begin{thm}[Theorem 2.4 in {\cite{axe}}]
Let \(f:\mathbb{Z}_p\to\mathbb{Z}_p\) be a \(1\)-Lipschitz function. Let \(R_0\) be a positive integer and
\(u\) an integer with \(0\leq u< p^{R_0}\) and
\[f(u)\equiv 0 \pmod {p^{R_0}}.\]
For any nonnegative integers \(m,R\) with \[m<p^R, \quad m\equiv u \pmod {p^{R_0}}, \quad R\geq R_0,\] assume that
\begin{align*}
&\{b(f;m+i\cdot p^{R})\hspace{-2.5mm}\mod p\mid i=1,2,\ldots,p-1\}\\
&\hspace{35mm}=\{j \hspace{-2.5mm}\mod p\mid j=1,2,\ldots,p-1\}.
\end{align*}
Then there exists a unique \(\xi\in\mathbb{Z}_p\) satisfying \(f(\xi)=0\) and \(\xi\equiv u\pmod {p^{R_0}}\).
\label{thm1}
\end{thm}

The fact that \(b(f;m)\in\mathbb{Z}_p\), which does not generally hold for continuous functions, is essential for the proof of Theorem \ref{thm1}. Thus, it is necessary to
generalize van der Put series.

The structure of the paper is as follows. In Section \ref{sec2} we define generalized van der Put series by introducing a strictly increasing integer-valued function $\Phi$. This function corresponds to the concept of the modulus of continuity in the case of real-valued continuous functions. We then use this generalization in Section \ref{sec3} to classify general continuous functions and to state and prove our main result (Theorem \ref{thm2}). In Section \ref{sec4} we generalize the notion of derivative and approximability to this context. Along our way, we illustrate our results by some concrete examples.

\section{Generalized van der Put series}\label{sec2}
This section is devoted to our generalization of van der Put series. Let \(\Phi:\mathbb{N}\to\mathbb{N}\) be a strictly increasing function. In the case of $\Phi=Id$, the identity function on \(\mathbb{N}\), we recover the original van der Put series.
To begin with, for any given \(p\)-adic integer
\begin{align}\label{aaa}
x=\sum_{i=0}^{\infty} x_i p^i
\end{align} with \(x_i\in \{0,1,\ldots,p-1\}\) we split its terms according to $\Phi$, namely,
\begin{align}\label{bbb}
x=\sum_{j=0}^{\infty} \sum_{i=\Phi(-1+j)+1}^{\Phi(j)} x_i p^i,
\end{align}
where we denote \(\Phi(-1):=-1\) for convenience. For any nonnegative integer \(m\) put
\[
\tau(m)=\tau(\Phi;m):=\min\left\{h\in\mathbb{N}\ \left| \ m<p^{1+\Phi(h)}\right.\right\}
\]
and, for any \(x\in\mathbb{Z}_p\),
\[
\chi(\Phi,m;x):=
\begin{cases}
1 & \mbox{if }|x-m|_p\leq p^{-1-\Phi(\tau(m))},\\
0 & \mbox{otherwise}.
\end{cases}
\]
Then we see
\(\tau(Id;m)=k\) by (\ref{eqn:1-2}), (\ref{eqn:1-3}), and so \(\chi(Id,m;x)=\chi(m;x)\) for any \(x\in\mathbb{Z}_p\)
by \(\Phi(\tau(m))=k\).
Let \(m\) be a nonnegative integer with \(\tau(m)\geq 1\), namely, \(m\geq p^{1+\Phi(0)}\).
Denote the base-\(p\) expansion of \(m\) by (\ref{eqn:1-1}).
Set
\[
M(m)=M(\Phi;m):=\sum_{i=\Phi(-1+\tau(m))+1}^{\Phi(\tau(m))}m_i p^i.
\]
Note that
\(M(Id;m)=m_k p^k\) by \(\Phi(\tau(m))=\Phi(-1+\tau(m))+1=k\).
\begin{prop}
For any continuous function \(f:\mathbb{Z}_p\to\mathbb{Z}_p\) there exists a unique sequence
\(B(m)=B(\Phi,f;m)\) (\(m=0,1,\ldots\)) such that
\begin{align}
f(x)=
\sum_{m=0}^{\infty}B(\Phi,f;m)\chi(\Phi,m;x)
\label{eqn:2-1}
\end{align}
for any \(x\in\mathbb{Z}_p\). Moreover, \(B(\Phi,f;m)\) satisfies
\begin{align}
B(\Phi,f;m)=
\begin{cases}
f(m) & \mbox{if }m<p^{1+\Phi(0)},\\
f(m)-f(m-M(m)) & \mbox{otherwise}.
\end{cases}
\label{eqn:2-2}
\end{align}
\label{prop1}
\end{prop}
We note that
\(B(Id,f;m)=B(f;m)\) for any nonnegative integer \(m\).
\begin{proof}[Proof of Proposition \ref{prop1}]
We first show that the sequence \(B(\Phi,f;m)\) (\(m=0,1,\ldots\)) defined inductively by (\ref{eqn:2-2})
satisfies (\ref{eqn:2-1}) (existence). For \(x\in\mathbb{Z}_p\) set
\begin{align}
F(x):=\sum_{m=0}^{\infty}B(\Phi,f;m)\chi(\Phi,m;x).
\label{eqn:2-3}
\end{align}
The convergence of the right-hand side of (\ref{eqn:2-3}) follows from
the uniform continuity of \(f\) and
\[\lim_{m\to\infty}|M(m)|_p=0\]
by the assumption that $\Phi$ is strictly increasing.
For any \(x\in\mathbb{Z}_p\) with (\ref{aaa}) and any nonnegative integer \(j\),
set
\begin{align}
x(j):=\sum_{i=0}^{\Phi(j)}x_i p^i.
\label{eqn:2-4}
\end{align}
Observe that
\[F(x)=\sum_{j=0}^{\infty} \sum_{m\in\mathbb{N}, \tau(m)=j}B(\Phi,f;m)\chi(\Phi,m;x).\]
Let again \(j\) be a nonnegative integer. Then, for any \(m\in\mathbb{N}\) with \(\tau(m)=j\), we have that
\begin{align}
\chi(\Phi,m;x)=1 \mbox{ if and only if } \tau(x(j))=j \mbox{ and }m=x(j).
\label{eqn:2-5}
\end{align}
It is easily seen that \(\tau(x(j))=j\) if and only if \(j=0\) or \(x(j)>x(j-1)\) because
\[x(j)=x(j-1)+\sum_{i=\Phi(j-1)+1}^{\Phi(j)} x_i p^i\]
for \(j>0\).
Letting
\[J(x):=\{0\}\cup\{j\in\mathbb{Z}^{+}\mid x(j)>x(j-1)\},\]
we get by (\ref{eqn:2-2}) that, for any \(j\in J(x)\backslash \{0\}\),
\[
B(\Phi,f;x(j))=f(x(j))-f(x(j-1))
\]
and that
\begin{align*}
F(x)&=\sum_{j\in J(x)} B(\Phi,f;x(j))\\
&=f(x(0))+\sum_{j\in J(x)\backslash\{0\}} \big(f(x(j))-f(x(j-1))\big).
\end{align*}
Moreover, if \(j\in\mathbb{N}\backslash J(x)\), then we have \(f(x(j))-f(x(j-1))=0\). Thus, we see
\[F(x)=f(x(0))+\sum_{j=1}^{\infty} \big(f(x(j))-f(x(j-1))\big)=f(x)\]
by \[\lim_{j\to\infty} x(j)=x.\]
Next, we prove that if  \(B(m)\) (\(m=0,1,\ldots\)) is a sequence satisfying
(\ref{eqn:2-1}) for any \(x\in\mathbb{Z}_p\), then (\ref{eqn:2-2}) holds by
induction on \(\tau(m)\) (uniqueness). We use the notation \(x(j) (j=0,1,\ldots)\) and \(J(x)\) in
the case where \(x=m\). \par
First, we consider the case of \(\tau(m)=0\), namely, \(m<p^{1+\Phi(0)}\).
Using (\ref{eqn:2-1}) and (\ref{eqn:2-5}), we get
\[f(m)=B(m(0))=B(m)\]
by \(\tau(m(j))=0\) for any \(j\in\mathbb{N}\),
which implies (\ref{eqn:2-2}). \par
We now assume that (\ref{eqn:2-2}) holds for any nonnegative integer \(m\) with \(\tau(m)\leq j\) for a fixed
integer \(j\geq 0\). Let \(m\) be a nonnegative integer with \(\tau(m)=j+1\). Then we see
\(J(m)\subset [0,j+1]\).  Using again (\ref{eqn:2-1}) and (\ref{eqn:2-5}), we get
\begin{align}
f(m)=\sum_{l\in J(m)}B(m(l)).
\label{eqn:2-6}
\end{align}
Put
\[J(m):=\{0=j_0<\cdots<j_{\kappa-1}<j_{\kappa}\},\]
where \(\kappa\geq 1\) and \(m(j_{\kappa})=m\) and \(m(j_{\kappa-1})=m-M(m)\).
Hence, we obtain by (\ref{eqn:2-6}) and the inductive hypothesis that
\begin{align*}
f(m)&=B(m(0))+\left(\sum_{l\in J(m) , 1\leq l\leq j_{\kappa-1}}B(m(l))\right)+B(m(j_{\kappa}))\\
&=f(m(0))+\left(\sum_{l\in J(m) , 1\leq l\leq j_{\kappa-1}}\big(f(m(l))-f(m(l-1))\big)\right)+B(m)\\
&=f(m(0))+\left(\sum_{1\leq l\leq j_{\kappa-1}}\big(f(m(l))-f(m(l-1))\big)\right)+B(m)\\
&=f(m(j_{\kappa-1}))+B(m)=f(m-M(m))+B(m),
\end{align*}
which implies (\ref{eqn:2-2}). Therefore, we proved the proposition.
\end{proof}

\section{Hensel's lemma for continuous functions}\label{sec3}
In what follows, we use notation (\ref{aaa}) and (\ref{bbb}) for a \(p\)-adic integer \(x\).
Let \(\Phi:\mathbb{N}\to\mathbb{N}\) be a strictly increasing function as used in the previous section. In order to state Hensel's lemma
for continuous functions, we define a certain class of continuous functions based on the use of \(\Phi\). \par
Let \(f:\mathbb{Z}_p\to\mathbb{Z}_p\) be a continuous function and \(n\) a positive integer.
Since \(f\) is uniformly continuous on \(\mathbb{Z}_p\), there exists a nonnegative integer \(l\) such that,
for any \(x,y\in\mathbb{Z}_p\), if \(|x-y|_p\leq p^{-l}\) then \(|f(x)-f(y)|_p\leq p^{-n}\). We denote the minimal value
of such an \(l\) by \(\psi(f;n)\). Note that \(\psi(f;n)\) (\(n=1,2,\ldots\)) is non-decreasing. \par
Let \(\mathcal{F}(\Phi)\) be the class of continuous functions \(f:\mathbb{Z}_p\to\mathbb{Z}_p\) satisfying
\[\psi(f;n)\leq 1+\Phi(n-1)\]
for any positive integer \(n\), namely, for any \(x,y\in\mathbb{Z}_p\),
\begin{align}\label{xxx}
\mbox{if }
|x-y|_p\leq p^{-1-\Phi(n-1)}\mbox{, then }|f(x)-f(y)|_p\leq p^{-n}.
\end{align}
Note that $|x-y|_p\leq p^{-1-\Phi(n-1)}$ is equivalent to
\[\sum_{i=0}^{\Phi(n-1)}x_i p^i=\sum_{i=0}^{\Phi(n-1)}y_i p^i.\
We see for any continuous \(f\) that
\(f\in \mathcal{F}(Id)\) if and only if \(f\) is \(1\)-Lipschitz. \par
For any continuous function \(f\), we see that
there exists a strictly increasing function \(\Phi\) such that \(f\in \mathcal{F}(\Phi)\),
defining \(\Phi\) as follows:
\begin{align*}
\Phi(0)&:=\max\{0,-1+\psi(f;1)\},\\
\Phi(n)&:=\max\{1+\Phi(n-1),-1+\psi(f;n+1)\}
\end{align*}
for any positive integer \(n\). \par
We now generalize (\ref{eqn:1-5}) as follows:
\begin{prop}
Let \(\Phi:\mathbb{N}\to\mathbb{N}\) be a strictly increasing function and
\(f:\mathbb{Z}_p\to\mathbb{Z}_p\) a continuous function. \\
Then \(f\in \mathcal{F}(\Phi)\) if and only if, for any nonnegative integer \(m\),
\begin{align}
v_p(B(\Phi,f;m))\geq \tau(\Phi;m).
\label{eqn:3-1}
\end{align}
\label{prop2}
\end{prop}
\begin{rem}
\begin{rm}
In what follows, we consider the case where \(\Phi\) and \(f\) are fixed.
For simplification, we also use the notation \(B(m)\), \(\tau(m)\), \(\chi(m;x)\), \(M(m)\) instead of
\(B(\Phi,f;m)\), \(\tau(\Phi;m)\), \(\chi(\Phi,m;x)\), \(M(\Phi;m)\).
\end{rm}
\end{rem}
\begin{proof}[Proof of Proposition \ref{prop2}]
First, assume that \(f\in\mathcal{F}(\Phi)\). Let \(m\) be a nonnegative integer.
For the proof of (\ref{eqn:3-1}), we may assume that \(\tau(m)\geq 1\). Observe by the
definition of \(M(m)\) that
\[v_p\big(m-(m-M(m))\big)=v_p(M(m))\geq 1+\Phi(-1+\tau(m)).\]
Applying (\ref{xxx}) with \(x=m, y=m-M(m)\) and \(n=\tau(m)\), we see
\[v_p(B(m))\geq \tau(m)\]
by (\ref{eqn:2-2}), which implies (\ref{eqn:3-1}). \par
Conversely, we assume (\ref{eqn:3-1}). Let \(n\) be a positive integer and let \(x,y\in\mathbb{Z}_p\) with
\(v_p(x-y)\geq 1+\Phi(n-1)\), namely,
\[\sum_{i=0}^{\Phi(n-1)}x_i p^i=\sum_{i=0}^{\Phi(n-1)}y_i p^i.\]
Observe for any integer \(m\) with \(0\leq m <p^{1+\Phi(n-1)}\) that
\[\chi(m;x)=\chi(m;y)\]
because \(\chi(m;x)\) (resp. \(\chi(m;y)\)) depends only on the first \(\Phi(n-1)\)-th digits of
\(x\) (resp. \(y\)) by \(\tau(m)\leq n-1\). Thus, Proposition \ref{prop1} implies that
\[f(x)-f(y)=
\sum_{m\geq p^{1+\Phi(n-1)}} B(m)\big(\chi(m;x)-\chi(m;y)\big).\]
For any integer \(m\) with \(m\geq p^{1+\Phi(n-1)}\), we get by (\ref{eqn:3-1}) that
\[v_p(B(m))\geq \tau(m)\geq n,\]
and that
\[v_p(f(x)-f(y))\geq n,\]
which implies that \(f\in \mathcal{F}(\Phi)\) because \(n\) is an arbitrary positive integer.
\end{proof}
In what follows, for any \(f\in\mathcal{F}(\Phi)\) and \(m\in\mathbb{N}\), put
\begin{align}
b(m)=b(\Phi,f;m):=p^{-\tau(\Phi;m)}B(\Phi,f;m)\in\mathbb{Z}_p
\label{eqn:3-2}
\end{align}
by Proposition \ref{prop2}. Moreover, for any \(p\)-adic integer \(x\)
and nonnegative integer \(j\), put
\[\rho(x;j):=p^{-1-\Phi(j-1)}\sum_{i=1+\Phi(j-1)}^{\Phi(j)}x_i p^i.\]
We now introduce a generalization of Theorem \ref{thm1} for continuous functions.
\begin{thm}
Let \(\Phi:\mathbb{N}\to\mathbb{N}\) be a strictly increasing function and let \(f\in \mathcal{F}(\Phi)\).
Let \(h,n_0\) and \(u\) be nonnegative integers with \(u<p^{1+\Phi(n_0)}\) and
\begin{align}
  f(u)\equiv 0 \pmod{p^{1+h+n_0}}.\label{umod}
\end{align}
Suppose that there exists a sequence \((S(n))_{n\geq n_0}\) of sets of nonnegative integers with
\[S(n)\subset \left(0,p^{\Phi(n+1)-\Phi(n)}\right), \quad \mbox{Card }S(n)=p-1,\]
where Card denotes the cardinality,
satisfying the following: For any nonnegative integers \(n,m\) with
\[n\geq n_0, \quad m<p^{1+\Phi(n)}, \quad m\equiv u \pmod {p^{1+\Phi(n_0)}},\]
we have
\begin{align}
&\left\{\left.b\left(\Phi,f;m+ip^{1+\Phi(n)}\right)\hspace{-2.5mm}\mod p^{h+1} \ \right| \
i\in S(n)\right\}\nonumber
\\
&\hspace{40mm}
=\left\{\left. i p^h \mod p^{h+1}\right| i=1,2,\ldots,p-1\right\}.
\label{eqn:3-3}
\end{align}
Then there exists \(\xi\in\mathbb{Z}_p\) such that
\begin{align}
&f(\xi)=0,\label{eqn:3-4}\\
&\xi\equiv u\pmod {p^{1+\Phi(n_0)}},\label{eqn:3-5}
\end{align}
and such that, for any \(n\geq n_0\),
\begin{align}
\rho(\xi;n+1)\in \{0\}\cup S(n).\label{eqn:3-6}
\end{align}
Assume further that, for any integer \(m\) with \(m\geq p^{1+\Phi(n_0)}\) and
\(m\equiv u \pmod {p^{1+\Phi(n_0)}}\), we have
\begin{align}\label{yyy}
b(\Phi,f;m)\equiv 0 {\pmod {p^h}}.
\end{align
Then \(\xi\in\mathbb{Z}_p\) satisfying (\ref{eqn:3-4}), (\ref{eqn:3-5}) and (\ref{eqn:3-6})
is unique.
\label{thm2}
\end{thm}
\begin{rem}
\begin{rm}
As we will see in Section \ref{sec4}, if $f$ is differentiable modulo $p^s$ at $u$, then $h$ corresponds to the $p$-adic order of the derivative of $f$. If $\Phi=Id$ and $h=0$ then $1+n_0=1+\Phi(n_0)$ which is the value of $R_0$ in Theorem \ref{thm1}. Thus, Theorem \ref{thm2} with \(\Phi=Id\) and \(h=0\) implies Theorem \ref{thm1}.
\end{rm}
\end{rem}
\begin{rem}
\begin{rm}
Note that (\ref{yyy}) always holds if \(h=0\).
\end{rm}
\end{rem}
\begin{rem}
\begin{rm}
A sequence \((S(n))_{n\geq n_0}\) satisfying the assumptions of Theorem \ref{thm2} is not generally unique.
In Example \ref{exa1}, we consider the case where (\ref{yyy}) holds. We give two solutions \(\xi\) satisfying
(\ref{eqn:3-4}) and (\ref{eqn:3-5}), by changing \((S(n))_{n\geq n_0}\). It would be an interesting question to try to prove the uniqueness of $\xi$ without assuming (3.9).
\end{rm}
\end{rem}
\begin{proof}[Proof of Theorem \ref{thm2}]
First, we prove the existence of such $\xi$ by using Newton's method. We show by induction on \(j\) that there exists a unique
sequence \((u_j)_{j\geq n_0}\) of integers with
\begin{align}
u_{n_0}=u\in [0,p^{1+\Phi(n_0)})\cap \mathbb{Z}\label{eqn:3-7}
\end{align}
satisfying the following:
\begin{enumerate}
\item[(1)] For all $j\geq n_0$,
\begin{align}
f(u_j)\equiv 0{\pmod {p^{1+h+j}}}.
\label{eqn:3-8}
\end{align}
\item[(2)] If \(j\geq 1+n_0\), then there exists \(i\in\{0\}\cup S(j-1)\) such that
\begin{align}
u_j=u_{j-1}+i p^{1+\Phi(j-1)}, \quad 0\leq u_j<p^{1+\Phi(j)}.
\label{eqn:3-9}
\end{align}
\end{enumerate}
The case of \(j=n_0\) follows from (\ref{umod}).
We assume that there exist unique integers \(u_{n_0},u_{1+n_0},\ldots,u_l\) for \(l\geq n_0\) satisfying
(\ref{eqn:3-7}), (\ref{eqn:3-8}) and (\ref{eqn:3-9}) for \(j=n_0,1+n_0,\ldots,l\). Let \(i\in S(l)\).
We see by \(p^{1+\Phi(l)}\leq i p^{1+\Phi(l)}\leq -p^{1+\Phi(l)}+p^{1+\Phi(l+1)}\) that
\[\tau\left(u_l+i p^{1+\Phi(l)}\right)=l+1\]
and that
\[M\left(u_l+i p^{1+\Phi(l)}\right)=i p^{1+\Phi(l)}.\]
Thus, using (\ref{eqn:3-2}) and (\ref{eqn:2-2}) with \(m=u_l+i p^{1+\Phi(l)}\), we get
\begin{align}
f\left(
u_l+i p^{1+\Phi(l)}
\right)
=f(u_l)+p^{l+1}b\left(
u_l+i p^{1+\Phi(l)}
\right).
\label{eqn:3-10}
\end{align}
Since \(u_l \equiv u_{n_0}=u {\pmod {p^{1+\Phi(n_0)}}}\) by (\ref{eqn:3-9}) with \(j=n_0,1+n_0,\ldots,l\),
we can apply (\ref{eqn:3-3}) with \(n=l,m=u_l\).
Since \(f(u_l)\equiv 0\mod p^{l+1+h}\), selecting suitable \(i\in \{0\}\cup S(l)\), we obtain that
\[u_{l+1}:=u_l+i p^{1+\Phi(l)}(<p^{1+\Phi(l+1)})\]
is a unique integer satisfying (\ref{eqn:3-8}) and (\ref{eqn:3-9}) with \(j=l+1\).
Putting \(\xi:=\lim_{j\to\infty}u_j\) we showed the existence of $\xi$.
In fact, if \(n\geq n_0\), then
\begin{align*}
\sum_{j=1+\Phi(n)}^{\Phi(1+n)}\xi_j p^j=u_{n+1}-u_n=i p^{1+\Phi(n)}.
\end{align*}
Thus, (\ref{eqn:3-6}) holds with \(\rho(\xi;n+1)=i\). \par
We now prove the uniqueness of $\xi$.
We see that the sequence \((\xi(j))_{j\geq n_0}\),
defined by (\ref{eqn:2-4}) for \(x=\xi\), satisfies (\ref{eqn:3-9}) by (\ref{eqn:3-6}) :
$$\xi(j)=\xi(j-1)+\rho(\xi; j) p^{1+\Phi(j-1)},\qquad j\geq 1+n_0,$$
where $\rho(\xi; j)\in\{0\}\cup S(j-1)$.
 Moreover, (\ref{eqn:3-7}) holds by
\(0\leq \xi(n_0)<p^{1+\Phi(n_0)}\) and (\ref{eqn:3-5}).
In the same way as the proof of Proposition \ref{prop2}, we can show for any \(j\geq n_0\) that
\begin{align*}
&f(\xi)-f(\xi(j))\\
&=\sum_{m\geq p^{1+\Phi(j)}} B(m)
\Big(\chi(m;\xi)-\chi(m;\xi(j))\Big)\\
&=\sum_{m\geq p^{1+\Phi(j)}} b(m)p^{\tau(m)}
\Big(\chi(m;\xi)-\chi(m;\xi(j))\Big).
\end{align*}
We fix an integer \(m\) with \(m\geq p^{1+\Phi(j)}(\geq p^{1+\Phi(n_0)})\). Then we have
\(\chi(m;\xi(j))=0\) by \(\tau(m)\geq j+1>j\geq \tau(\xi(j))\).
Moreover, \(\chi(m;\xi)=1\) if and only if \(m=\xi(j')\) for some \(j'\geq j+1\).
In particular, if \(\chi(m;\xi)=1\), then we have \(m\equiv u \mod p^{1+\Phi(n_0)}\). \par
For any integer \(m\) with \(m\geq p^{1+\Phi(j)}\) and \(m\equiv u \mod p^{1+\Phi(n_0)}\), we see by (\ref{yyy}) that
\[v_p(b(m)p^{\tau(m)})\geq h+\tau(m)\geq 1+h+j.\]
Thus, we get by (\ref{eqn:3-4}) that
\[f(\xi(j))\equiv f(\xi)=0 \pmod {p^{1+h+j}},\]
which implies (\ref{eqn:3-8}). By the uniqueness of \((u_j)_{j\geq n_0}\), we see
\(\xi(j)=u_j\) for all \(j\geq n_0\). This concludes the proof of the theorem.
\end{proof}
\begin{exa}\label{exa1}
\begin{rm}
Let \(a=\sum_{i=0}^{\infty} a_i p^i \in\mathbb{Z}_p\) be fixed and \(f:\mathbb{Z}_p\to\mathbb{Z}_p\) be defined by
\[f(x)=a+\sum_{j=0}^{\infty} x_{2j} p^j,\]
where $x=\sum_{i=0}^{\infty} x_i p^i$.
Let \(\Phi(n):=2n+1\) for any nonnegative integer \(n\). Then we have \(f\in\mathcal{F}(\Phi)\).
In fact, if \(x,y \in\mathbb{Z}_p\) satisfy
\(|x-y|_p\leq p^{-1-\Phi(n-1)}=p^{-2n}\) for some positive integer \(n\), then
\(|f(x)-f(y)|_p\leq p^{-n}\). \par
In what follows, we check that Theorem \ref{thm2} is applicable to \(f\). Putting \(h=0,n_0=0,\) and \(u=-a_0\), we
see
\[u<p^{1+\Phi(n_0)}=p^2, \qquad f(u)\equiv 0 {\pmod {p^{1+h+n_0}}}.\]
Moreover, let \(m,n, i\) be nonnegative integers with \(0\leq m<p^{1+\Phi(n)}=p^{2n+2}\) and
\(1\leq i\leq p-1\). Then we have
\[f\left(m+i\cdot p^{1+\Phi(n)}\right)-f(m)=i\cdot p^{n+1}.\]
Observe that \(\tau(m+i\cdot p^{1+\Phi(n)})=n+1\) by
\(p^{1+\Phi(n)}\leq m+i\cdot p^{1+\Phi(n)}<p^{1+\Phi(n+1)}\). Thus the number
\[b\left(m+i\cdot p^{1+\Phi(n)}\right)(\equiv i \pmod p)\]
satisfies (\ref{eqn:3-3}) with \(S(n)=\{1,2,\ldots,p-1\}\) for any \(n\geq n_0=0\). \par
Similarly, (\ref{eqn:3-3}) with \(S(n)=\{p+1,p+2,\ldots,2p-1\}\) holds for any \(n\geq n_0=0\).
In fact, we get for any \(1\leq i\leq p-1\) that
\[f\left(m+(i+p)\cdot p^{1+\Phi(n)}\right)-f(m)=i\cdot p^{n+1}\]
and that \(\tau(m+(i+p)\cdot p^{1+\Phi(n)})=n+1\).
\end{rm}
\end{exa}
\begin{exa}
\begin{rm}
Let \(p=5\) and \(a\in\mathbb{Z}_5\) be fixed, and let \(f:\mathbb{Z}_5\to\mathbb{Z}_5\) be defined by
\[f(x)=a+\sum_{j=0}^{\infty} x_{2j}^3 5^j.\]
In the same way as in Example \ref{exa1},
we have \(f\in\mathcal{F}(\Phi)\), where \(\Phi(n):=2n+1\) for any nonnegative integer \(n\). \par
Observe that if \(m,n,i\) are nonnegative integers with \(0\leq m<5^{2n+2}\) and \(1\leq i\leq 4\), then we have
\[f\left(m+i\cdot 5^{1+\Phi(n)}\right)-f(m)=i^3\cdot 5^{n+1}.\]
Moreover, the map \(\phi:\mathbb{Z}/5\mathbb{Z}\to \mathbb{Z}/5\mathbb{Z}\) with
\[\phi(x \hspace{-1.5mm} \mod 5\mathbb{Z})=x^3 \mod {5\mathbb{Z}}\]
is bijective.
Thus, in the same way as in Example \ref{exa1}, we can verify that Theorem \ref{thm2} is applicable to \(f\), where
\(h=0,n_0=0\), \(u\) is a unique integer with
\(0\leq u\leq 4\) and \(a+u^3 \equiv 0 \pmod 5\), and
\(S(n)=\{1,2,3,4\}\) for any \(n\geq n_0=0\).
\end{rm}
\end{exa}
We give an example of Theorem \ref{thm2} satisfying \(h\ne 0\) in Section 4.

\section{Approximability of continuous functions}\label{sec4}
In this section we use notation defined in Sections 2 and 3. Let \(f:\mathbb{Z}_p\to\mathbb{Z}_p\) be a function
and \(u\in\mathbb{Z}_p\). Recall for a positive integer \(s\) that \(f\) is differentiable modulo \(p^s\)
at \(u\) if there exists a \(p\)-adic number \(\partial_s f(u)\) satisfying the following:
If \(n\) is a sufficiently large integer, then for any \(u'\in\mathbb{Z}_p\), we have
\begin{align}
\label{modmod}
f(u+p^n u')\equiv f(u)+p^n u' \partial_s f(u) \pmod {p^{n+s}}.
\end{align}
Axelsson and Khrennikov showed for 1-Lipschitz functions \(f\) that if
\(|\partial_s f(u)|_p=1\), then the Hensel's lifting process can be used (Theorem 2.4 and Corollary 2.6 in \cite{axe}). \par
For the application of Theorem \ref{thm2}, we now modify the notion of differentiability modulo \(p^s\) to consider the case where \(f\) is a general continuous
function, using a strictly increasing function \(\Phi:\mathbb{N}\to\mathbb{N}\). Let \(u\in\mathbb{Z}_p\).
We call \(f\) approximable at \(u\) with respect to \(\Phi\) if there exist nonnegative integers \(h=h(u)\), \(l=l(u),\)
and a sequence \((\delta_n f) (u)\) (\(n\geq l\)) of \(p\)-adic numbers satisfying the following:
For any integer \(n\geq l\) and \(u'\in\mathbb{Z}_p\), we have
\begin{align}
f\left(u+p^{1+\Phi(n-1)}u'\right)\equiv f(u)+p^{h+n} u'\cdot (\delta_n f) (u) \pmod {p^{h+n+1}}.
\label{eqn:4-1}
\end{align}
The approximability of continuous functions generalizes the differentiability modulo \(p^s\).
Thus, Corollary \ref{cor} is also applicable to differentiable function modulo \(p^s\).
In fact, let $\Phi=Id$ and let \(f\) be a continuous function which is differentiable modulo \(p^s\) at \(u\).
Let \(h=s-1\).
Then (\ref{modmod}) implies that $$f(u+p^n u')=f\left(u+p^{1+\Phi(n-1)}u'\right)\equiv
f(u)+p^{h+n} u'\cdot (\delta_n f) (u) \pmod {p^{h+n+1}},$$
where
$(\delta_n f) (u)=\partial_{h+1} f (u)/p^h$. \par
In order to apply Theorem \ref{thm2} we will make use of the fact that $(\delta_n f) (u)$ is a unit in $\mathbb{Z}_p$.
Let \(\Lambda\) be a subset of \(\mathbb{Z}_p\).
We call \(f\) uniformly
approximable on \(\Lambda\) with respect to \(\Phi\) if
\(f\) is approximable at any \(u\in \Lambda\) with respect to \(\Phi\) and if
\(h(u),l(u)\) are constants on \(\Lambda\) which we call \(h(\Lambda)\) and \(l(\Lambda)\) in that case.
\begin{cor}
Let \(\Phi:\mathbb{N}\to\mathbb{N}\) be a strictly increasing function and \(f\in \mathcal{F}(\Phi)\).
Let \(n_0,u\in\mathbb{N}\) with \(u<p^{1+\Phi(n_0)}\). Assume that \(f\) is uniformly approximable on the set
\[\Lambda:=\left\{u'\in\mathbb{Z}_p\left| u'\equiv u\pmod {p^{1+\Phi(n_0)}}\right.\right\}\]
with respect to \(\Phi\). Moreover, assume that
\begin{align*}
&n_0+1\geq l(\Lambda),\\
&f(u')\equiv 0 \pmod {p^{h(\Lambda)+n_0+1}}
\end{align*}
and that
\[|(\delta_n f) (u')|_p=1\]
for any \(n\geq n_0\) and \(u'\in \Lambda\).
Then there exists a unique \(\xi\in\mathbb{Z}_p\) such that
\begin{align*}
&f(\xi)=0,\\
&\xi\equiv u\pmod {p^{1+\Phi(n_0)}},
\end{align*}
and such that, for any \(n\geq n_0\),
\begin{align*}
\rho(\xi;n+1)\in \{0,1,\ldots,p-1\}.
\end{align*}
\label{cor}
\end{cor}
\begin{proof}
We apply Theorem \ref{thm2} with \(h=h(\Lambda)\) and \(S(n):=\{1,\ldots,p-1\}\) for all
\(n\geq n_0\).
Since \(f(u)\equiv 0 \pmod {p^{h(\Lambda)+n_0+1}}\) by the assumption of Corollary \ref{cor},
it suffices to check (\ref{eqn:3-3}) and (\ref{yyy}). Assume that \(n,m,i\in\mathbb{N}\) satisfy \(n\geq n_0\),
\(m<p^{1+\Phi(n)}\), \(m\equiv u \pmod {p^{1+\Phi(n_0)}}\), and \(1\leq i\leq p-1\). Since
\(\tau(m+ip^{1+\Phi(n)})=n+1\), we see by (\ref{eqn:4-1}) and by $n+1\geq n_0+1\geq l(\Lambda)$ that
\begin{align*}
b(m+i p^{1+\Phi(n)})&=p^{-n-1}(f(m+i p^{1+\Phi(n)})-f(m))\\
&\equiv p^{h(\Lambda)} i\cdot  (\delta_{n+1} f) (m) \pmod {p^{h(\Lambda)+1}},
\end{align*}
which implies (\ref{eqn:3-3}) by \(|(\delta_n f) (m)|_p=1\). \par
Now, let \(m\) be an integer with \(m\geq p^{1+\Phi(n_0)}\), \(m\equiv u \pmod {p^{1+\Phi(n_0)}}\).
Put \(u':=m-M(m)\) and \(n:=\tau(m)-1\geq n_0\). Recall that
$M(m)=\sum_{i=\Phi(n)+1}^{\Phi(n+1)} m_i p^i$ and therefore
\(u'':=p^{-1-\Phi(n)}M(m)\) is an integer.
Thus, we see by \(u'\in\Lambda\), (\ref{eqn:4-1}) and $n+1\geq n_0+1\geq l(\Lambda)$ that
\[f(u'+p^{1+\Phi(n)} u'') \equiv f(u')+p^{h(\Lambda)+n+1} u''\cdot (\delta_{n+1} f) (u') \pmod {p^{h(\Lambda)+n+2}}.\]
Finally, since \(m=u'+p^{1+\Phi(n)} u''\) we obtain
\begin{align*}
b(m)&=p^{-n-1}(f(u'+p^{1+\Phi(n)} u'')-f(u'))\\
&\equiv p^{h(\Lambda)} u''\cdot  (\delta_{n+1} f) (u') \equiv 0 \pmod {p^{h(\Lambda)}},
\end{align*}
which implies (\ref{yyy}).
\end{proof}
\begin{exa}
\begin{rm}
Let \(a\in\mathbb{Z}_p\) be fixed. If \(p\ne 2\), then assume that \(a\equiv 1 \pmod p\). If \(p=2\), then suppose that
\(a\equiv 1\pmod 8\). For any \(x\in \mathbb{Z}_p\), put
\[f(x):=-a+\left(\sum_{j=0}^{\infty} x_{2j} p^j\right)^2.\]
Then we have \(f\in\mathcal{F}(\Phi)\), where \(\Phi(n)=2n+1\) for any nonnegative integer \(n\).
Put
\begin{align*}
n_0=h=\begin{cases}
0 & \mbox{if }p\ne 2, \\
1 & \mbox{if }p=2.
\end{cases}
\end{align*}
and
\begin{align*}
l=\begin{cases}
1 & \mbox{if }p\ne 2, \\
2 & \mbox{if }p=2.
\end{cases}
\end{align*}
Note that in the case of $p=2$ the value of $h$ is different from 0. \par
First, there exists \(u\in\mathbb{Z}_p\) with
\[f(u)\equiv 0 \pmod {p^{h+n_0+1}}.\]
Let \(\Lambda:=\{u'\in\mathbb{Z}_p\mid u'\equiv u\pmod {p^{1+\Phi(n_0)}}\}\). We show that \(f\)
is uniformly approximable on \(\Lambda\) with respect to \(\Phi\) with
\(h(\Lambda)=h\), \(l(\Lambda)=l\) and
\begin{align}
(\delta_n f)(x)=\begin{cases}
2 & \mbox{if }p\ne 2, \\
1 & \mbox{if }p=2
\end{cases}
\label{eqn:4-4}
\end{align}
for any \(x\in \Lambda\). Thus, Corollary \ref{cor} is applicable to \(f\). \par
Let \(x\in \Lambda\). Let \(n\) be an integer with \(n\geq l\) and \(y\in\mathbb{Z}_p\). Since
\[
x+p^{1+\Phi(n)}y=\sum_{j=0}^{2n+1} x_j p^j
+
\sum_{j=2n+2}^{\infty} (x_j+y_{j-2n-2}) p^j,
\]
we get after a direct calculation
\begin{align}
&f\left(x+p^{1+\Phi(n)}y\right)-f(x)\nonumber\\
&=\left(
\sum_{j=0}^{n} x_{2j} p^j
+
\sum_{j=n+1}^{\infty} (x_{2j}+y_{2j-2n-2}) p^j
\right)^2
-
\left(
\sum_{j=0}^{\infty} x_{2j} p^j
\right)^2\nonumber\\
& \equiv
2\sum_{j=0}^{n} x_{2j} p^j\cdot
\sum_{j=n+1}^{\infty} y_{2j-2n-2} p^j
\pmod {p^{2n+2}}.
\label{eqn:4-5}
\end{align}
Note that \(x_0\equiv 1\pmod p\) by \(x\in \Lambda\). If \(p\) is odd, then (\ref{eqn:4-5}) implies that
\begin{align}
f\left(x+p^{1+\Phi(n)}y\right)-f(x)
\equiv 2x_0 y_0 p^{n+1}\equiv 2y p^{n+1}\pmod {p^{n+2}}.
\label{eqn:4-6}
\end{align}
In the case of \(p=2\), we get by \(n\geq 1\) that
\begin{align}
f\left(x+2^{1+\Phi(n)}y\right)-f(x)
\equiv 2x_0 y_0 \cdot 2^{n+1}\equiv y 2^{n+2}\pmod {2^{n+3}}.
\label{eqn:4-7}
\end{align}
Thus, (\ref{eqn:4-6}) and (\ref{eqn:4-7}) imply the approximability and (\ref{eqn:4-4}).
\end{rm}
\end{exa}

\section*{Acknowledgements}

The first author is supported by JSPS KAKENHI Grant Number 15K17505. The second author acknowledges the support of the bilateral project ANR-FWF (France-Austria) called MUDERA (Multiplicativity, Determinism, and Randomness), ANR-14-CE34-0009.

Commutative Algebra (math.AC); Number Theory (math.NT); Rings and Algebras (math.RA)


On the antiderivative of inverse functions

Abstract: One of the basics of calculus is the following proposition: If $F$ and $G$ are antiderivatives of two real functions $f$ and $g$ resp., then an antiderivative of $\lambda f+g$ is $\lambda F + G$. It may be surprising that such systematic an integration formula exists for the inverse of a function $f$, a fact that seems to have been discovered for the first time by Laisant in 1905, and seems not to be well known. More precisely, if $f$ is an invertible real function, and if $F$ is an antiderivative of $f$, then the antiderivative of $f^{-1}$ is $xf^{-1}(x)-F\circ f^{-1}(x)+C$. Laisant, and other authors after him, assumes that $f^{-1}$ is differentiable, in which case the proof of this formula is immediate. Recently, it has been shown by Key that this additional assumption is unnecessary. In this paper, we give two different proofs of this result. The first proof, of geometrical spirit, relies to Fubini's theorem, while the second proof, purely analytic, is based on the Stieltjes integral.